B2017-175 The steps were being displayed with High-level steps and sections overlapping an expanded high-level step. The fix assures that high level steps and sections will be located vertically so that they don't overlap other steps.
This commit is contained in:
parent
086adde4c6
commit
88383ec87f
@ -2412,9 +2412,17 @@ namespace Volian.Controls.Library
|
||||
// _NextDownEditItemPath);
|
||||
if (nextEditItem != null)
|
||||
{
|
||||
if (MyStepPanel.ExpandingHLS != null && nextEditItem.MyItemInfo.IsSection) return; // without this, if next item is section, it crashes on null reference
|
||||
if (MyStepPanel.ExpandingHLS != null && nextEditItem.MyItemInfo.IsSection)
|
||||
{
|
||||
AddAdjustItem(this);// B2017-175 Adjust Location after Expanding
|
||||
return; // without this, if next item is section, it crashes on null reference
|
||||
}
|
||||
if (MyStepPanel.ExpandingHLS != null && nextEditItem.MyItemInfo.MyHLS.ItemID != MyStepPanel.ExpandingHLS.ItemID)
|
||||
{
|
||||
AddAdjustItem(this);// B2017-175 Adjust Location after Expanding
|
||||
return;
|
||||
}
|
||||
if (AdjustItems.Contains(this)) AdjustItems.Remove(this);//B2017-175 If processed remove from list to do later
|
||||
int bottom = nextEditItem.FindTop(Bottom);
|
||||
if (MyItemInfo.ActiveFormat.MyStepSectionLayoutData.Dev_Format)
|
||||
{
|
||||
@ -2472,6 +2480,21 @@ namespace Volian.Controls.Library
|
||||
}
|
||||
}
|
||||
}
|
||||
private static List<EditItem> _AdjustItems=new List<EditItem>();// B2017-175 Keep a list of EditItems to adjust after expanding
|
||||
public static List<EditItem> AdjustItems
|
||||
{
|
||||
get { return _AdjustItems; }
|
||||
set { _AdjustItems = value; }
|
||||
}
|
||||
private static void AddAdjustItem(EditItem ei)// B2017-175 Add edit item to adjust after expanding
|
||||
{
|
||||
if(!AdjustItems.Contains(ei)) AdjustItems.Add(ei);
|
||||
}
|
||||
private static void ProcessAdjustItems() // B2017-175 adjust after expanding
|
||||
{
|
||||
while (AdjustItems.Count > 0)
|
||||
AdjustItems[0].AdjustLocation();
|
||||
}
|
||||
private int _DevDocHeight = 0; // Deviation Document Step Height B2016-123, B2017-020, B2017-021
|
||||
public int DevDocHeight
|
||||
{
|
||||
@ -2569,6 +2592,8 @@ namespace Volian.Controls.Library
|
||||
}
|
||||
MyExpandingStatus = ExpandingStatus.Done;
|
||||
BottomMostEditItem.AdjustLocation();
|
||||
if (MyItemInfo.IsHigh)
|
||||
ProcessAdjustItems(); // B2017-175 Adjust after expanding
|
||||
MyExpandingStatus = ExpandingStatus.No;
|
||||
//// TIMING: DisplayItem.TimeIt("Expand End");
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user