private HotkeysEditorForm_FormClosing ( object sender, FormClosingEventArgs e ) : void | ||
sender | object | |
e | FormClosingEventArgs | |
return | void |
private void HotkeysEditorForm_FormClosing(object sender, FormClosingEventArgs e)
{
if (DialogResult == DialogResult.OK)
{
var actions = GetUnAssignedActions();
if (!string.IsNullOrEmpty(actions))
{
if (
MessageBox.Show(
"Some actions are not assigned!\r\nActions: " + actions +
"\r\nPress Yes to save and exit, press No to continue editing",
"Some actions is not assigned", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) ==
DialogResult.No)
e.Cancel = true;
}
}
}