Add thread-safe close

This commit is contained in:
Carlos Fonseca 2019-10-05 04:00:00 +00:00
parent acabb26378
commit 0f826f6324
1 changed files with 1 additions and 1 deletions

View File

@ -83,7 +83,7 @@ namespace DeepSpeechWPF
catch (Exception ex) catch (Exception ex)
{ {
MessageBox.Show(ex.Message); MessageBox.Show(ex.Message);
Close(); Dispatcher.Invoke(() => { Close(); });
} }
}); });
} }