catch plugin init fails - stop Wox from not starting up and crushing and disable and explain the user what is the probalmatic plugin

This commit is contained in:
clueless
2020-02-21 23:12:58 +02:00
parent 56c2964e96
commit cb9e045c7f
5 changed files with 78 additions and 15 deletions

View File

@@ -91,12 +91,12 @@ namespace Wox
_mainVM.MainWindowVisibility = Visibility.Visible;
}
public void ShowMsg(string title, string subTitle = "", string iconPath = "")
public void ShowMsg(string title, string subTitle = "", string iconPath = "", bool useMainWindowAsOwner = true)
{
Application.Current.Dispatcher.Invoke(() =>
{
var m = new Msg { Owner = Application.Current.MainWindow };
m.Show(title, subTitle, iconPath);
var msg = useMainWindowAsOwner ? new Msg {Owner = Application.Current.MainWindow} : new Msg();
msg.Show(title, subTitle, iconPath);
});
}