Fix the halting issue on window close.
This commit is contained in:
parent
23fa82655b
commit
fef20ff36a
|
@ -38,9 +38,9 @@ namespace Filtration.Views
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void MainWindow_OnClosing(object sender, CancelEventArgs e)
|
private async void MainWindow_OnClosing(object sender, CancelEventArgs e)
|
||||||
{
|
{
|
||||||
var allDocumentsClosed = _mainWindowViewModel.CloseAllDocumentsAsync().Result;
|
var allDocumentsClosed = await _mainWindowViewModel.CloseAllDocumentsAsync();
|
||||||
if (!allDocumentsClosed)
|
if (!allDocumentsClosed)
|
||||||
{
|
{
|
||||||
e.Cancel = true;
|
e.Cancel = true;
|
||||||
|
|
Loading…
Reference in New Issue