This commit is contained in:
John Jenko 2010-06-24 15:19:46 +00:00
parent af197dbd05
commit f2ab81f97d
2 changed files with 81 additions and 56 deletions

View File

@ -277,10 +277,18 @@ namespace VEPROMS.CSLA.Library
s = _Xp.ParentValue("Section", "Pagination"); // get the parent value s = _Xp.ParentValue("Section", "Pagination"); // get the parent value
//If there is no parent value, then use the volian default //If there is no parent value, then use the volian default
if (s == string.Empty) if (s == string.Empty)
{
if (MyFormat != null)
{ {
bool rval = MyFormat.PlantFormat.FormatData.SectData.StepSectionData.StepSectionLayoutData.BreakOnSections; bool rval = MyFormat.PlantFormat.FormatData.SectData.StepSectionData.StepSectionLayoutData.BreakOnSections;
return (rval) ? SectionPagination.Separate : SectionPagination.Continuous;// default to volian default return (rval) ? SectionPagination.Separate : SectionPagination.Continuous;// default to volian default
} }
else
{
bool rval = MyDefaultFormat.PlantFormat.FormatData.SectData.StepSectionData.StepSectionLayoutData.BreakOnSections;
return (rval) ? SectionPagination.Separate : SectionPagination.Continuous;// default to volian default
}
}
return (SectionPagination)int.Parse(s); return (SectionPagination)int.Parse(s);
} }
@ -423,10 +431,18 @@ namespace VEPROMS.CSLA.Library
s = _Xp.ParentValue("Section", "ColumnMode"); // get the parent value s = _Xp.ParentValue("Section", "ColumnMode"); // get the parent value
// If there is no parent value, then use the volian default // If there is no parent value, then use the volian default
if (s == string.Empty) if (s == string.Empty)
{
if (MyFormat != null)
{ {
int rval = (int)MyFormat.PlantFormat.FormatData.SectData.StepSectionData.StepSectionLayoutData.PMode; int rval = (int)MyFormat.PlantFormat.FormatData.SectData.StepSectionData.StepSectionLayoutData.PMode;
return (SectionColumnMode)rval;//SectionColumnMode.Two; //SectionColumnMode.Default;// default to volian default return (SectionColumnMode)rval;//SectionColumnMode.Two; //SectionColumnMode.Default;// default to volian default
} }
else
{
int rval = (int)MyDefaultFormat.PlantFormat.FormatData.SectData.StepSectionData.StepSectionLayoutData.PMode;
return (SectionColumnMode)rval;
}
}
else else
return (SectionColumnMode)int.Parse(s); return (SectionColumnMode)int.Parse(s);

View File

@ -474,7 +474,7 @@ namespace Volian.Controls.Library
{ {
_MouseDown = true; _MouseDown = true;
//Console.WriteLine("vvvvvvvvvv StepRTB Mouse Down id= {0}",MyItemInfo.ItemID); //Console.WriteLine("vvvvvvvvvv StepRTB Mouse Down id= {0}",MyItemInfo.ItemID);
if (!_ContextMenuStripChanged) if (!_ContextMenuStripChanged && this.MyStepItem != null)
this.MyStepItem.MyStepPanel.MyStepTabPanel.MyStepTabRibbon.SetContextMenu(); this.MyStepItem.MyStepPanel.MyStepTabPanel.MyStepTabRibbon.SetContextMenu();
_ContextMenuStripChanged = false; _ContextMenuStripChanged = false;
} }
@ -1356,6 +1356,8 @@ namespace Volian.Controls.Library
void StepRTB_KeyUp(object sender, KeyEventArgs e) void StepRTB_KeyUp(object sender, KeyEventArgs e)
{ {
if (e.Control) if (e.Control)
{
if (this.MyStepItem != null)
{ {
if (e.Alt) if (e.Alt)
{ {
@ -1404,6 +1406,7 @@ namespace Volian.Controls.Library
} }
} }
} }
}
if (!e.Shift) return; if (!e.Shift) return;
switch (e.KeyCode) switch (e.KeyCode)
{ {
@ -1503,8 +1506,11 @@ namespace Volian.Controls.Library
e.Handled = true; e.Handled = true;
break; break;
case Keys.Enter: case Keys.Enter:
if (this.MyStepItem != null)
{
this.MyStepItem.MyStepPanel.MyStepTabPanel.MyStepTabRibbon.btnInsPgBrk_Click(sender, e); this.MyStepItem.MyStepPanel.MyStepTabPanel.MyStepTabRibbon.btnInsPgBrk_Click(sender, e);
e.Handled = true; e.Handled = true;
}
break; break;
} }
} }
@ -1668,6 +1674,8 @@ namespace Volian.Controls.Library
e.Handled = true; e.Handled = true;
break; break;
case Keys.F5: case Keys.F5:
if (this.MyStepItem != null)
{
if (e.Shift) if (e.Shift)
{ {
e.Handled = true; e.Handled = true;
@ -1678,6 +1686,7 @@ namespace Volian.Controls.Library
e.Handled = true; e.Handled = true;
this.MyStepItem.MyStepPanel.MyStepTabPanel.MyStepTabRibbon.DoCopyStep(); this.MyStepItem.MyStepPanel.MyStepTabPanel.MyStepTabRibbon.DoCopyStep();
} }
}
break; break;
case Keys.F6: case Keys.F6:
e.Handled = true; e.Handled = true;
@ -1690,7 +1699,7 @@ namespace Volian.Controls.Library
case Keys.Enter: case Keys.Enter:
if (!e.Control && !e.Shift && !e.Alt) if (!e.Control && !e.Shift && !e.Alt)
{ {
if (!MyStepItem.MyItemInfo.IsTablePart) if (MyStepItem != null && !MyStepItem.MyItemInfo.IsTablePart)
{ {
e.Handled = true; e.Handled = true;
MyStepItem.MyStepPanel.MyStepTabPanel.MyStepTabRibbon.ProcessEnterKey(); MyStepItem.MyStepPanel.MyStepTabPanel.MyStepTabRibbon.ProcessEnterKey();