This commit is contained in:
Kathy Ruffing 2012-03-06 17:19:30 +00:00
parent 67747c0984
commit 51352a687c

View File

@ -216,7 +216,7 @@ namespace Volian.Controls.Library
// see if change in subsections to be displayed, i.e. if the user made a change to editable data // see if change in subsections to be displayed, i.e. if the user made a change to editable data
// on the section properties form, we may have to display steps or remove steps. By design, // on the section properties form, we may have to display steps or remove steps. By design,
// steps are the first children from a section. // steps are the first children from a section.
if (MyItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.UseMetaSections) if (MyItemInfo.IsSection && MyItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.UseMetaSections)
{ {
// find out what the editable flag is to determine if change. // find out what the editable flag is to determine if change.
bool showSteps = MyItemInfo.MyConfig is SectionConfig && (MyItemInfo.MyConfig as SectionConfig).SubSection_Edit == "Y"; bool showSteps = MyItemInfo.MyConfig is SectionConfig && (MyItemInfo.MyConfig as SectionConfig).SubSection_Edit == "Y";
@ -615,10 +615,7 @@ namespace Volian.Controls.Library
public void RemoveItemWithoutDelete() public void RemoveItemWithoutDelete()
{ {
BeingRemoved = true; BeingRemoved = true;
//MyStepPanel.SelectedEditItem = null; // Unselect the item to be deleted
int TopMostYBefore = TopMostEditItem.Top; int TopMostYBefore = TopMostEditItem.Top;
MyStepPanel._LookupEditItems.Remove(MyID); MyStepPanel._LookupEditItems.Remove(MyID);
EditItem newFocus = null; EditItem newFocus = null;
int? TopMostParentY = (MyParentEditItem == null ? null : (int?)(MyParentEditItem.TopMostEditItem.Top)); int? TopMostParentY = (MyParentEditItem == null ? null : (int?)(MyParentEditItem.TopMostEditItem.Top));
@ -648,34 +645,19 @@ namespace Volian.Controls.Library
MyPreviousEditItem.MyNextEditItem = null; MyPreviousEditItem.MyNextEditItem = null;
newFocus = MyPreviousEditItem.BottomMostEditItem; newFocus = MyPreviousEditItem.BottomMostEditItem;
MyPreviousEditItem = null; MyPreviousEditItem = null;
//Console.Write(",\"Previous\",");
} }
else else
{ {
newFocus = MyParentEditItem; newFocus = MyParentEditItem;
MyParentEditItem = null; MyParentEditItem = null;
//Console.Write(",\"Parent\",");
} }
//_MyTimer.ShowElapsedTimes("DeleteItem"); Dispose();
//KBR??return newFocus; if (newFocus != null)
{
newFocus.SetFocus();
//EditItem newFocus = DeleteItem(); newFocus.SetAllTabs();
//if (newFocus == null) return; newFocus.AdjustLocation();
////_MyTimer.ActiveProcess = "SetFocus"; }
//newFocus.SetFocus();
////_MyTimer.ActiveProcess = "Dispose";
//Dispose();
////_MyTimer.ActiveProcess = "SetAllTabs";
//newFocus.SetAllTabs();
////_MyTimer.ActiveProcess = "TopMostYAfter";
//int TopMostYAfter = newFocus.TopMostEditItem.Top;
//if (TopMostYAfter > TopMostYBefore)
// newFocus.TopMostEditItem.Top = TopMostYBefore;
////_MyTimer.ActiveProcess = "AdjustLocation";
//newFocus.AdjustLocation();
////newFocus.ShowTops("");
////_MyTimer.ShowElapsedTimes("RemoveItem");
} }
public void RemoveItem() public void RemoveItem()
{ {