Bugfix: Adjustment method modeless dialog was not started in UI thread, freezes
This commit is contained in:
parent
cca60e56ff
commit
94accbf58b
@ -9,9 +9,19 @@ using TBF.UiBridge;
|
||||
|
||||
namespace TBF.BenchControl.TestMethods.Adjustment
|
||||
{
|
||||
public class FlyingStartSeq : Sequences.SequenceBase
|
||||
public class AdjustmentSeq : Sequences.SequenceBase
|
||||
{
|
||||
private static readonly ILog log = LogManager.GetLogger(typeof(FlyingStartSeq));
|
||||
private static readonly ILog log = LogManager.GetLogger(typeof(AdjustmentSeq));
|
||||
|
||||
System.Windows.Forms.Form modelessDlg;
|
||||
///
|
||||
delegate void ErrorsFormDlgt(AdjustmentSeq myRef);
|
||||
///
|
||||
void OpenWMErrorsForm(AdjustmentSeq myRef)
|
||||
{
|
||||
myRef.modelessDlg = new WMErrorsForm(Program.WMsCount);
|
||||
modelessDlg.Show();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Flying start mass collection method sequence
|
||||
@ -25,7 +35,6 @@ namespace TBF.BenchControl.TestMethods.Adjustment
|
||||
/// </returns>
|
||||
public IList<Event> Execute(Entities.Test test)
|
||||
{
|
||||
System.Windows.Forms.Form modelessDlg = null;
|
||||
|
||||
Elde.ControlBoardDev cBrd = StateMachine.ControlBoard;
|
||||
|
||||
@ -109,8 +118,7 @@ namespace TBF.BenchControl.TestMethods.Adjustment
|
||||
///
|
||||
/// Show the modeless dialog with error indication
|
||||
///
|
||||
modelessDlg = new WMErrorsForm(Program.WMsCount);
|
||||
modelessDlg.Show();
|
||||
Program.MainWnd.Invoke(new ErrorsFormDlgt(OpenWMErrorsForm), this);
|
||||
|
||||
flow_set:
|
||||
loop:
|
||||
|
||||
@ -18,7 +18,7 @@ namespace TBF.BenchControl.TestMethods.Adjustment
|
||||
|
||||
public IList<Event> Execute(Entities.Test test)
|
||||
{
|
||||
return (new FlyingStartSeq()).Execute(test);
|
||||
return (new AdjustmentSeq()).Execute(test);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user