Shutoff AutoExpand for PMS-810

This commit is contained in:
Rich 2013-02-15 17:01:51 +00:00
parent 93cab87a23
commit 34ef8944f0
3 changed files with 16 additions and 2 deletions

View File

@ -1731,7 +1731,10 @@ namespace Volian.Controls.Library
if (CanExpand && Expanded == false)// TODO: May need to do some additional checking for subsections if (CanExpand && Expanded == false)// TODO: May need to do some additional checking for subsections
{ {
//vlnStackTrace.ShowStack(">AutoExpand ID {0} - Can {1} Expanded {2}", _MyItem.ItemID, CanExpand, Expanded); //vlnStackTrace.ShowStack(">AutoExpand ID {0} - Can {1} Expanded {2}", _MyItem.ItemID, CanExpand, Expanded);
if(MyStepPanel.AutoExpand)
Expand((_ContentType >= 20000) || MyItemInfo.ActiveFormat.MyStepSectionLayoutData.Dev_Format); Expand((_ContentType >= 20000) || MyItemInfo.ActiveFormat.MyStepSectionLayoutData.Dev_Format);
else
Expand(false);
//Console.WriteLine("<AutoExpand ID {0} - Can {1} Expanded {2}",_MyItem.ItemID, CanExpand, Expanded); //Console.WriteLine("<AutoExpand ID {0} - Can {1} Expanded {2}",_MyItem.ItemID, CanExpand, Expanded);
} }
} }

View File

@ -855,7 +855,10 @@ namespace Volian.Controls.Library
//OLD: _MyvlnExpander.Attachment = (itemInfo.MyContent.ContentPartCount == 0); //OLD: _MyvlnExpander.Attachment = (itemInfo.MyContent.ContentPartCount == 0);
break; break;
case 2: // High level steps with children can expand case 2: // High level steps with children can expand
if(MyStepPanel.AutoExpand)
CanExpand = itemInfo.IsHigh && !MyItemInfo.ActiveFormat.MyStepSectionLayoutData.Dev_Format && itemInfo.HasChildren; // TemporaryFormat.IsHigh(item); ; CanExpand = itemInfo.IsHigh && !MyItemInfo.ActiveFormat.MyStepSectionLayoutData.Dev_Format && itemInfo.HasChildren; // TemporaryFormat.IsHigh(item); ;
else
CanExpand = true;
break; break;
default://Procedures cannot expand, because they automatically expand default://Procedures cannot expand, because they automatically expand
CanExpand = false; CanExpand = false;

View File

@ -354,6 +354,14 @@ namespace Volian.Controls.Library
//// TIMING: DisplayItem.TimeIt("pMyItem End"); //// TIMING: DisplayItem.TimeIt("pMyItem End");
} }
} }
public bool AutoExpand
{
get
{
// This is temporary to get the code working for this particular procedure
return MyProcedureItemInfo.DisplayNumber != "PMS-810";
}
}
public void Reset() public void Reset()
{ {
ItemInfo parent = SelectedItemInfo.ActiveParent as ItemInfo; ItemInfo parent = SelectedItemInfo.ActiveParent as ItemInfo;