From 0c963045ba98ff57f4636c214b625e85a5c8f6e9 Mon Sep 17 00:00:00 2001 From: Vic <10308169+VictoriousRaptor@users.noreply.github.com> Date: Fri, 14 Oct 2022 01:36:52 +0800 Subject: [PATCH] Show plugin names in download success notification --- .../Flow.Launcher.Plugin.PluginsManager/Languages/en.xaml | 4 ++-- .../Flow.Launcher.Plugin.PluginsManager/PluginsManager.cs | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Plugins/Flow.Launcher.Plugin.PluginsManager/Languages/en.xaml b/Plugins/Flow.Launcher.Plugin.PluginsManager/Languages/en.xaml index 361ce989b..1f74a49a2 100644 --- a/Plugins/Flow.Launcher.Plugin.PluginsManager/Languages/en.xaml +++ b/Plugins/Flow.Launcher.Plugin.PluginsManager/Languages/en.xaml @@ -5,7 +5,7 @@ Downloading plugin - Successfully downloaded + Successfully downloaded {0} Error: Unable to download the plugin {0} by {1} {2}{3}Would you like to uninstall this plugin? After the uninstallation Flow will automatically restart. {0} by {1} {2}{3}Would you like to install this plugin? After the installation Flow will automatically restart. @@ -13,7 +13,7 @@ Installing Plugin Download and install {0} Plugin Uninstall - Plugin successfully installed. Restarting Flow, please wait... + Plugin {0} successfully installed. Restarting Flow, please wait... Unable to find the plugin.json metadata file from the extracted zip file. Error: A plugin which has the same or greater version with {0} already exists. Error installing plugin diff --git a/Plugins/Flow.Launcher.Plugin.PluginsManager/PluginsManager.cs b/Plugins/Flow.Launcher.Plugin.PluginsManager/PluginsManager.cs index 4d29f7651..d74ec70b5 100644 --- a/Plugins/Flow.Launcher.Plugin.PluginsManager/PluginsManager.cs +++ b/Plugins/Flow.Launcher.Plugin.PluginsManager/PluginsManager.cs @@ -157,7 +157,7 @@ namespace Flow.Launcher.Plugin.PluginsManager await Http.DownloadAsync(plugin.UrlDownload, filePath).ConfigureAwait(false); Context.API.ShowMsg(Context.API.GetTranslation("plugin_pluginsmanager_downloading_plugin"), - Context.API.GetTranslation("plugin_pluginsmanager_download_success")); + string.Format(Context.API.GetTranslation("plugin_pluginsmanager_download_success"), plugin.Name)); Install(plugin, filePath); } @@ -177,7 +177,7 @@ namespace Flow.Launcher.Plugin.PluginsManager } Context.API.ShowMsg(Context.API.GetTranslation("plugin_pluginsmanager_installing_plugin"), - Context.API.GetTranslation("plugin_pluginsmanager_install_success_restart")); + string.Format(Context.API.GetTranslation("plugin_pluginsmanager_install_success_restart"), plugin.Name)); Context.API.RestartApp(); } @@ -245,7 +245,7 @@ namespace Flow.Launcher.Plugin.PluginsManager Context.API.ShowMsg( Context.API.GetTranslation("plugin_pluginsmanager_downloading_plugin"), - Context.API.GetTranslation("plugin_pluginsmanager_download_success")); + string.Format(Context.API.GetTranslation("plugin_pluginsmanager_download_success"), x.Name)); Install(x.PluginNewUserPlugin, downloadToFilePath);