mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
Merge pull request #3251 from Jack251970/hide_window
Use api function to hide window
This commit is contained in:
commit
6c22aea9d4
2 changed files with 6 additions and 6 deletions
|
|
@ -534,7 +534,7 @@ namespace Flow.Launcher.Plugin.PluginsManager
|
|||
return false;
|
||||
}
|
||||
|
||||
Application.Current.MainWindow.Hide();
|
||||
Context.API.HideMainWindow();
|
||||
_ = InstallOrUpdateAsync(plugin);
|
||||
|
||||
return ShouldHideWindow;
|
||||
|
|
@ -572,7 +572,7 @@ namespace Flow.Launcher.Plugin.PluginsManager
|
|||
return false;
|
||||
}
|
||||
|
||||
Application.Current.MainWindow.Hide();
|
||||
Context.API.HideMainWindow();
|
||||
_ = InstallOrUpdateAsync(plugin);
|
||||
|
||||
return ShouldHideWindow;
|
||||
|
|
@ -626,7 +626,7 @@ namespace Flow.Launcher.Plugin.PluginsManager
|
|||
return ShouldHideWindow;
|
||||
}
|
||||
|
||||
Application.Current.MainWindow.Hide();
|
||||
Context.API.HideMainWindow();
|
||||
_ = InstallOrUpdateAsync(x); // No need to wait
|
||||
return ShouldHideWindow;
|
||||
},
|
||||
|
|
@ -703,7 +703,7 @@ namespace Flow.Launcher.Plugin.PluginsManager
|
|||
Context.API.GetTranslation("plugin_pluginsmanager_uninstall_title"),
|
||||
MessageBoxButton.YesNo) == MessageBoxResult.Yes)
|
||||
{
|
||||
Application.Current.MainWindow.Hide();
|
||||
Context.API.HideMainWindow();
|
||||
Uninstall(x.Metadata);
|
||||
if (Settings.AutoRestartAfterChanging)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -333,7 +333,7 @@ namespace Flow.Launcher.Plugin.Sys
|
|||
Action = c =>
|
||||
{
|
||||
// Hide the window first then show msg after done because sometimes the reload could take a while, so not to make user think it's frozen.
|
||||
Application.Current.MainWindow.Hide();
|
||||
context.API.HideMainWindow();
|
||||
|
||||
_ = context.API.ReloadAllPluginData().ContinueWith(_ =>
|
||||
context.API.ShowMsg(
|
||||
|
|
@ -352,7 +352,7 @@ namespace Flow.Launcher.Plugin.Sys
|
|||
IcoPath = "Images\\checkupdate.png",
|
||||
Action = c =>
|
||||
{
|
||||
Application.Current.MainWindow.Hide();
|
||||
context.API.HideMainWindow();
|
||||
context.API.CheckForNewUpdate();
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue