/// <summary> /// Cancel button was clicked. /// </summary> private void OnCancelClick(object sender, EventArgs e) { Launcher.CancelLaunch(); closing = true; Cancel.Fire(this); Close(); }
/// <summary> /// Fire the cancel event. /// </summary> protected virtual void OnCancel() { try { if (worker.IsBusy) { worker.CancelAsync(); } } catch { // Ignore } try { Cancel.Fire(this); } catch (Exception ex) { ErrorLog.DumpError(ex); } }
private void cmdCancel_Click(object sender, EventArgs e) { Cancel.Fire(this); }
/// <summary> /// Cancel this control /// </summary> private void OnCancelClick(object sender, EventArgs e) { cancelTokenSource.Cancel(); Cancel.Fire(this); }