'Break' button added to the main window, replaces 'Try heads' button.

This commit is contained in:
Milan Hanajik
2015-05-22 16:43:17 +02:00
parent cbda254731
commit 04196fde2f
8 changed files with 914 additions and 850 deletions
@@ -235,7 +235,12 @@ namespace TBF.BenchControl.Sequences
///
if (selection == Selection.PurgeBegin) goto fill_the_bench;
if (selection == Selection.PurgeEnd) goto purge_end;
if (selection == Selection.SaveResults) goto save_results;
if (selection == Selection.Break)
{
Bridge.Bench2UI(ButtonsEtc.ShowBenchEmpty);
goto select_procedure;
}
if (selection == Selection.SaveResults) goto save_results;
cycle_or_test_selected:
@@ -559,6 +564,7 @@ namespace TBF.BenchControl.Sequences
Stop,
PurgeBegin,
PurgeEnd,
Break,
SaveResults,
}
@@ -619,7 +625,7 @@ namespace TBF.BenchControl.Sequences
((context == MKSelContext.InsideProcedure) ? ButtonsEtc.PurgeEndBtnEn : 0) |
ButtonsEtc.SensitivityTestBtnEn |
((Cameras.Count > 0) ? ButtonsEtc.CalibrationBtnEn : 0) |
ButtonsEtc.TryOpticalHeadsBtnEn)) |
ButtonsEtc.Break)) |
(((StateMachine.Balance1 != null) && (StateMachine.EmptyTankValve1 != null) && !emptying1) ? ButtonsEtc.EmptyTankBtn1En : 0) |
(((StateMachine.Balance2 != null) && (StateMachine.EmptyTankValve2 != null) && !emptying2) ? ButtonsEtc.EmptyTankBtn2En : 0) |
(((StateMachine.Balance3 != null) && (StateMachine.EmptyTankValve3 != null) && !emptying3) ? ButtonsEtc.EmptyTankBtn3En : 0));
@@ -646,6 +652,7 @@ namespace TBF.BenchControl.Sequences
else if (emptying3 && StateMachine.Balance3.IsEmpty(mass3.Val)) selection = Selection.CloseTank3;
else if (e.Contains(Event.UiCmdPurgeBegin)) return Selection.PurgeBegin; /// Value used to branch the code later on
else if (e.Contains(Event.UiCmdPurgeEnd)) return Selection.PurgeEnd;
else if (e.Contains(Event.UiCmdBreak) && context == MKSelContext.InsideProcedure) return Selection.Break;
else if (e.Contains(Event.UiCmdStartTest)) return Selection.Test;
else if (e.Contains(Event.UiCmdStartQ1)) return Selection.Q1;
else if (e.Contains(Event.UiCmdStartQ2)) return Selection.Q2;