Commit b52de064 LN

增机暂停按钮

1 个父辈 0ca7cebf
......@@ -202,8 +202,13 @@ namespace OnlineStore.DeviceLibrary
private bool InProcess = false;
private Stopwatch stopwatch = new Stopwatch();
public bool MoveStop = false;
protected void timersTimer_Elapsed(object sender, System.Timers.ElapsedEventArgs e)
{
if (MoveStop)
{
return;
}
if (InProcess && stopwatch.Elapsed.TotalSeconds < 5)
{
return;
......
......@@ -67,6 +67,7 @@
this.btnDis = new System.Windows.Forms.Button();
this.btnInit = new System.Windows.Forms.Button();
this.button1 = new System.Windows.Forms.Button();
this.chbMoveStop = new System.Windows.Forms.CheckBox();
this.groupBox3.SuspendLayout();
this.panel1.SuspendLayout();
this.contextMenuStrip1.SuspendLayout();
......@@ -134,6 +135,7 @@
//
this.panel1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.panel1.Controls.Add(this.chbMoveStop);
this.panel1.Controls.Add(this.lblInfo);
this.panel1.Controls.Add(this.btnVmiExit);
this.panel1.Controls.Add(this.btnVmiStart);
......@@ -578,6 +580,19 @@
this.button1.Text = "NeedEntry";
this.button1.UseVisualStyleBackColor = true;
//
// chbMoveStop
//
this.chbMoveStop.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.chbMoveStop.AutoSize = true;
this.chbMoveStop.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.chbMoveStop.Location = new System.Drawing.Point(665, 10);
this.chbMoveStop.Name = "chbMoveStop";
this.chbMoveStop.Size = new System.Drawing.Size(84, 24);
this.chbMoveStop.TabIndex = 274;
this.chbMoveStop.Text = "暂停运动";
this.chbMoveStop.UseVisualStyleBackColor = true;
this.chbMoveStop.CheckedChanged += new System.EventHandler(this.chbMoveStop_CheckedChanged);
//
// FrmVMIClient
//
this.AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F);
......@@ -657,6 +672,7 @@
private System.Windows.Forms.TextBox txtname;
private System.Windows.Forms.TextBox txtShelfId;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.CheckBox chbMoveStop;
}
}
......@@ -406,5 +406,11 @@ namespace OnlineStore.VMILineClient
}
vmiLine.StopIOMove(iotype, value);
}
private void chbMoveStop_CheckedChanged(object sender, EventArgs e)
{
vmiLine.MoveStop = chbMoveStop.Checked;
LogUtil.info(vmiLine.Name + "用户切换是否暂停: " + vmiLine.MoveStop);
}
}
}
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!