B2024-016 - For Robinson, all local transitions will now have the option of including a page number. Generic, transitions defined to never include a step number will not display a list of steps in the Transitions Step Properties panel #276

Merged
plarsen merged 1 commits from GeneralDebugging into Development 2024-03-22 10:10:21 -04:00
4 changed files with 20 additions and 6 deletions

Binary file not shown.

Binary file not shown.

View File

@ -44,8 +44,9 @@ using System.Runtime.InteropServices;
// Revision DHH (day - no leading zero, two digit hour - military time // Revision DHH (day - no leading zero, two digit hour - military time
// //
// ********* REMEMBER TO CHECK THE AssemblyConfiguration SETTING (ABOVE) ******** // ********* REMEMBER TO CHECK THE AssemblyConfiguration SETTING (ABOVE) ********
[assembly: AssemblyVersion("2.1.2403.413")] [assembly: AssemblyVersion("2.1.2403.2209")]
[assembly: AssemblyFileVersion("2.1.2403.413")] [assembly: AssemblyFileVersion("2.1.2403.2209")]

View File

@ -687,6 +687,8 @@ namespace Volian.Controls.Library
cbPageNum.Checked = _ModExistingPageNum = tc != null && tc.Transition_Formatted.ToUpper() == "TRUE"; cbPageNum.Checked = _ModExistingPageNum = tc != null && tc.Transition_Formatted.ToUpper() == "TRUE";
} }
} }
// B2024-016 if transition format does not have {First Step} then don't show step list
HideStepTreeIfNeeded();
} }
#endregion #endregion
#region Events #region Events
@ -916,11 +918,10 @@ namespace Volian.Controls.Library
} }
else else
{ {
_InitializingTrans = true; // just initializing now, don't set any ranges, etc. _InitializingTrans = true; // just initializing now, don't set any ranges, etc.
tvTranFillIn((secitm.Steps == null || secitm.Steps.Count == 0) ? null : secitm.Steps[0]); tvTranFillIn((secitm.Steps == null || secitm.Steps.Count == 0) ? null : secitm.Steps[0]);
tvTran.Enabled = true; // B2024-016 only show the list of steps if used by the select transition
cbIncStepNum.Enabled = true; HideStepTreeIfNeeded();
cbIncStepNum.Checked = true;
// if doing a 'new' range, no node is selected in tree. Without this, the first node in the // if doing a 'new' range, no node is selected in tree. Without this, the first node in the
// tree was the selected node which was throwing off the logic for defining the _RangeNode1 // tree was the selected node which was throwing off the logic for defining the _RangeNode1
// and _RangeNode2 // and _RangeNode2
@ -935,6 +936,18 @@ namespace Volian.Controls.Library
SaveCancelEnabling(); SaveCancelEnabling();
} }
} }
// B2024-016 Hide the step tree when the transition definition does not include a step number {First Step}
private void HideStepTreeIfNeeded()
{
string trnFmt = _CurItemFrom.ActiveFormat.PlantFormat.FormatData.TransData.TransTypeList[_TranFmtIndx].TransFormat;
bool showStepList = trnFmt.Contains("{First Step}");
if (!showStepList)
tvTran.Nodes.Clear(); // clear the tree view of steps if not needed for selected transition
tvTran.Enabled = showStepList; // show the tree view of steps?
cbIncStepNum.Enabled = showStepList; // display the Include Step checkbox?
cbIncStepNum.Checked = showStepList; // uncheck the Include Step?
}
// B2018-002 - Invalid Transitions - Declare Default Section variables // B2018-002 - Invalid Transitions - Declare Default Section variables
private bool NeedsDefault; private bool NeedsDefault;
private bool HasDefault; private bool HasDefault;