This commit is contained in:
parent
655ec1ab94
commit
fefc5f3ec2
@ -195,9 +195,10 @@ namespace Volian.Controls.Library
|
|||||||
int fromtype = Convert.ToInt32(insdata[0]);
|
int fromtype = Convert.ToInt32(insdata[0]);
|
||||||
int contenttype = Convert.ToInt32(insdata[1]) + 20000;
|
int contenttype = Convert.ToInt32(insdata[1]) + 20000;
|
||||||
|
|
||||||
// if from type == 0, we've inserted a hls, do a after from current HLS
|
// if from type == 0, we've inserted a hls.
|
||||||
// if not at HLS, go up parents until find it.
|
// if inserting from section, insert first child
|
||||||
if (fromtype == 0)
|
// else do a after from current HLS - if not at HLS, go up parents until find it.
|
||||||
|
if (fromtype == 0 && !_MyStepItem.MyItemInfo.IsStepSection)
|
||||||
{
|
{
|
||||||
StepItem hlsStepItem = _MyStepItem;
|
StepItem hlsStepItem = _MyStepItem;
|
||||||
while (!hlsStepItem.MyItemInfo.IsHigh)
|
while (!hlsStepItem.MyItemInfo.IsHigh)
|
||||||
@ -339,12 +340,15 @@ namespace Volian.Controls.Library
|
|||||||
if (MyItemInfo.IsProcedure || MyItemInfo.IsSection)
|
if (MyItemInfo.IsProcedure || MyItemInfo.IsSection)
|
||||||
{
|
{
|
||||||
btnChgTyp.Enabled = false;
|
btnChgTyp.Enabled = false;
|
||||||
btnInsHLS.Enabled = btnInsCaut.Enabled = btnInsNote.Enabled = btnInsRNO.Enabled = btnInsFig.Enabled =
|
|
||||||
|
btnInsCaut.Enabled = btnInsNote.Enabled = btnInsRNO.Enabled = btnInsFig.Enabled =
|
||||||
btnInsTable.Enabled = btnInsSubstep.Enabled = btnInsBefore.Enabled = btnInsAfter.Enabled = false;
|
btnInsTable.Enabled = btnInsSubstep.Enabled = btnInsBefore.Enabled = btnInsAfter.Enabled = false;
|
||||||
// if on a procedure or section title, don't allow for insert of ROs or Transitions:
|
// if on a procedure or section title, don't allow for insert of ROs or Transitions:
|
||||||
// disable buttons. Info panels for ROs and Transitions are made invisible in frmVEPROMS.cs
|
// disable buttons. Info panels for ROs and Transitions are made invisible in frmVEPROMS.cs
|
||||||
btnInsTrans.Enabled = btnCMTransition.Enabled = btnInsRO.Enabled = btnCMRO.Enabled = false;
|
btnInsTrans.Enabled = btnCMTransition.Enabled = btnInsRO.Enabled = btnCMRO.Enabled = false;
|
||||||
btnInsAftH.Enabled = btnInsBefH.Enabled = false;
|
btnInsAftH.Enabled = btnInsBefH.Enabled = false;
|
||||||
|
btnInsHLS.Enabled = (!MyItemInfo.IsStepSection) ? false : true; // allow hls from step section
|
||||||
|
if (btnInsHLS.Enabled) GalleryForSubTypes(MyItemInfo.ActiveFormat.PlantFormat.FormatData.StepDataList.HLS, MyItemInfo.ActiveFormat.PlantFormat.FormatData.StepDataList.HLS, btnInsHLS, (int)E_FromType.Step);
|
||||||
this.Refresh();
|
this.Refresh();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user