private void BtnCreate_Click(object sender, EventArgs e) { DialogResult result = MessageBox.Show("Edited row list will be lost and\nnew row list will be created.\nDo you want to continue?", "Confirmation", MessageBoxButtons.YesNo, MessageBoxIcon.Question); if (result == DialogResult.Yes) { DrawingWafer = null; EdtZoom.Value = 1; NewWafer(); PaintWafer(); } }
private void NewWafer() { DrawingWafer = new DrawWafer(DrawDieMode.WaferEditor, (float)EdtWaferDiam.Value, (FlatPosition)Enum.Parse(typeof(FlatPosition), CbFlatPos.Text), (float)EdtDieX.Value, (float)EdtDieY.Value); DrawingWafer.CanvasSize = new Size(PnlCanvas.Width, PnlCanvas.Height); DefaultScrollBars(); }