private void CloseSender(object sender, CancelEventArgs e) { if (ColorizationThread != null && ColorizationThread.IsAlive) { ColorizationThread.Abort(); } }
private void StopColorization(object sender, EventArgs e) { ColorizationThread.Abort(); StartStopToolStripMenuItem.Click -= StopColorization; StartStopToolStripMenuItem.Click += StartColorization; StartStopToolStripMenuItem.Text = "Старт"; OpenImageToolStripMenuItem.Enabled = true; MainProgressBar.Value = 0; Text = "PABCSoft - FastNeuralColor: Прервано"; }