| | |
| | | plImage.Controls.Add(cvImage); |
| | | |
| | | tscEditLocation.Visible = tsmiShowEditor.Checked = false; |
| | | |
| | | this.Load += (s, e) => |
| | | { |
| | | cvImage.SetScreenSize(); |
| | | }; |
| | | } |
| | | |
| | | public override void OnProcessUpdated() |
| | |
| | | try |
| | | { |
| | | Bitmap image = (Bitmap)Image.FromFile(Config.BackgroundImagePath); |
| | | cvImage.LoadImage(image); |
| | | cvImage.LoadImage(image); |
| | | cvImage.SetScreenSize(); |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | |
| | | lvMeasures.Items.Add(item); |
| | | }); |
| | | |
| | | txtBarcode.ReadOnly = Config.IsBarcodeManulInputBlocked; |
| | | if (txtBarcode.IsHandleCreated) |
| | | txtBarcode.BeginInvoke(new Action(() => txtBarcode.ReadOnly = Config.IsBarcodeManulInputBlocked)); |
| | | |
| | | Process_M071.OnClearBarcode -= M071_MainForm_OnClearBarcode; |
| | | Process_M071.OnClearBarcode += M071_MainForm_OnClearBarcode; |
| | |
| | | |
| | | MessageBox.Show("标签修改完成"); |
| | | } |
| | | |
| | | private void lvMeasures_DoubleClick(object sender, EventArgs e) |
| | | { |
| | | if (lvMeasures.SelectedItems.Count <= 0) |
| | | return; |
| | | |
| | | var ele = cvImage.Elements.FirstOrDefault(u => u.ID == lvMeasures.SelectedItems[0].Tag.ToString()); |
| | | if (ele != null) |
| | | { |
| | | ele.State = ElementState.Selected; |
| | | cvImage.Invalidate(); |
| | | } |
| | | } |
| | | #endregion |
| | | |
| | | #region 上方状态区 |
| | |
| | | txtBarcode.Text = _barcode; |
| | | _barcode = ""; |
| | | } |
| | | |
| | | if (e.KeyValue == 27) |
| | | { |
| | | cvImage.Elements.ToList().ForEach(ele => ele.State = ElementState.Normal); |
| | | } |
| | | } |
| | | |
| | | private void txtBarcode_TextChanged(object sender, EventArgs e) |