Compare commits

...
4 Commits
2 changed files with 32 additions and 6 deletions

No files matched your search

+17 -5
View File
@@ -2426,6 +2426,7 @@ namespace VEPROMS
// when Word procedure tabs are restored. // when Word procedure tabs are restored.
// C2026-053 leaving this flag in her for now should we decide to trouble-shoot reopening of Word tabs later on. // C2026-053 leaving this flag in her for now should we decide to trouble-shoot reopening of Word tabs later on.
tc.LoadingSavedProcTabs = true; // we check for this flag in DSOTabPanel.cs when opening Word sections tc.LoadingSavedProcTabs = true; // we check for this flag in DSOTabPanel.cs when opening Word sections
EditItem LastEditItem = null; //to hold last edit item. Needed in case last tab is a Word Section
foreach (DataRow TabState in DisPlayTabState.Rows) foreach (DataRow TabState in DisPlayTabState.Rows)
{ {
int _ItemID = (int)TabState["ItemID"]; int _ItemID = (int)TabState["ItemID"];
@@ -2439,17 +2440,28 @@ namespace VEPROMS
// SelectedStepTabPanel needs to be set so the print buttons on the ribbon will work. // SelectedStepTabPanel needs to be set so the print buttons on the ribbon will work.
SelectedStepTabPanel = tc.MyEditItem.MyStepPanel.MyStepTabPanel; SelectedStepTabPanel = tc.MyEditItem.MyStepPanel.MyStepTabPanel;
LastEditItem = tc.MyEditItem; //set last tab index
if ((DisPlayTabState.Rows.IndexOf(TabState) == DisPlayTabState.Rows.Count - 1))
{
SelectedStepTabPanel.Select();
}
}
//CSM B2024-090 - if last displaytab item, //CSM B2024-090 - if last displaytab item,
//select the steptab panel for it //select the steptab panel for it
//and set the EditItem for Find/Replace //and set the EditItem for Find/Replace
//otherwise will cause PROMS to crash if Find clicked before a Tab is given Focus //otherwise will cause PROMS to crash if Find clicked before a Tab is given Focus
if ((DisPlayTabState.Rows.IndexOf(TabState) == DisPlayTabState.Rows.Count - 1)) if (LastEditItem != null)
{ {
SelectedStepTabPanel.Select(); dlgFindReplace.MyEditItem = LastEditItem;
dlgFindReplace.MyEditItem = tc.MyEditItem; SpellChecker.MyEditItem = LastEditItem; //B2025-043 Remember Tabs is not setting the EditItem for the active window causing a PROMS crash when Spell Check
SpellChecker.MyEditItem = tc.MyEditItem; //B2025-043 Remember Tabs is not setting the EditItem for the active window causing a PROMS crash when Spell Check
} //B2026-090 Populate Step Properties Panel when PROMS restores saved display tabs
LastEditItem.MyStepPanel.BringToFront();
LastEditItem.MyStepPanel.Select();
Application.DoEvents();
tc_ItemSelectedChanged(this, new ItemSelectedChangedEventArgs(tc.MyEditItem));
} }
tc.LoadingSavedProcTabs = false; tc.LoadingSavedProcTabs = false;
} }
} }
+15 -1
View File
@@ -3512,9 +3512,23 @@ namespace Volian.Controls.Library
} }
break; break;
case "InsRNO": case "InsRNO":
displayMenu = ((actable & E_AccStep.AddingRNO) > 0) && btnCMInsRNO.Enabled; //B2026-086 Have Shortcut Keys for adding a RNO auto-work instead of having to press a button after shortcut key
displayMenu = false;
LetUserKnowIfTheyCannotAdd(actable, E_AccStep.AddingRNO,"RNO"); // B2018-014 Inform user that they cannot add the specified step type LetUserKnowIfTheyCannotAdd(actable, E_AccStep.AddingRNO,"RNO"); // B2018-014 Inform user that they cannot add the specified step type
if (((actable & E_AccStep.AddingRNO) > 0) && btnCMInsRNO.Enabled)
{
try
{
btnCMInsRNO.SubItems["cmbtnRNOType"].RaiseClick();
}
catch
{
_ContextMenuBar.SetContextMenuEx(_MyStepRTB, btnCMInsRNO); _ContextMenuBar.SetContextMenuEx(_MyStepRTB, btnCMInsRNO);
displayMenu = true;
}
}
break; break;
case "InsSubStps": case "InsSubStps":
displayMenu = ((actable & E_AccStep.AddingSub) > 0) && btnCMInsSubStps.Enabled; displayMenu = ((actable & E_AccStep.AddingSub) > 0) && btnCMInsSubStps.Enabled;