Skip to content

Commit e9915be

Browse files
committed
Improve Watcher page UI
- Fixed crash when adding an unsupported folder to the Watcher page
1 parent 9257602 commit e9915be

File tree

5 files changed

+204
-91
lines changed

5 files changed

+204
-91
lines changed

CompactGUI/ViewModels/WatcherViewModel.vb

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,10 @@ Public Class WatcherViewModel : Inherits ObservableObject
4545
Dim validFolder = Core.verifyFolder(path)
4646
If Not validFolder.isValid Then
4747
Dim msgError As New ContentDialog With {.Title = "Invalid Folder", .Content = $"{validFolder.msg}", .CloseButtonText = "OK"}
48-
Await msgError.ShowAsync()
48+
Application.Current.Dispatcher.Invoke(Sub()
49+
msgError.ShowAsync()
50+
End Sub)
51+
4952
Return
5053
End If
5154

0 commit comments

Comments
 (0)