We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c33e9de commit ebb74daCopy full SHA for ebb74da
1 file changed
Flow.Launcher/MessageBoxEx.xaml.cs
@@ -159,12 +159,19 @@ private async Task SetImageAsync(string imageName)
159
160
private void KeyEsc_OnPress(object sender, ExecutedRoutedEventArgs e)
161
{
162
- if (_button == MessageBoxButton.YesNo)
163
- return;
164
- else if (_button == MessageBoxButton.OK)
165
- _result = MessageBoxResult.OK;
166
- else
167
- _result = MessageBoxResult.Cancel;
+ switch (_button)
+ {
+ case MessageBoxButton.OK:
+ _result = MessageBoxResult.None;
+ break;
+ case MessageBoxButton.OKCancel:
168
+ case MessageBoxButton.YesNoCancel:
169
+ _result = MessageBoxResult.Cancel;
170
171
+ case MessageBoxButton.YesNo:
172
+ _result = MessageBoxResult.No;
173
174
+ }
175
DialogResult = false;
176
Close();
177
}
0 commit comments