diff --git a/Flow.Launcher.Core/Plugin/PluginManager.cs b/Flow.Launcher.Core/Plugin/PluginManager.cs index 7c352bd78..231a477f0 100644 --- a/Flow.Launcher.Core/Plugin/PluginManager.cs +++ b/Flow.Launcher.Core/Plugin/PluginManager.cs @@ -481,14 +481,16 @@ namespace Flow.Launcher.Core.Plugin return _homePlugins.Where(p => !PluginModified(p.Metadata.ID)).Any(p => p.Metadata.ID == id); } - public static Dictionary> GetPluginHotkeyInfo() + public static IDictionary> GetPluginHotkeyInfo() { - return _pluginHotkeyInfo; + return _pluginHotkeyInfo.Where(p => !PluginModified(p.Key.Metadata.ID)) + .ToDictionary(p => p.Key, p => p.Value); } - public static Dictionary> GetWindowPluginHotkeys() + public static IDictionary> GetWindowPluginHotkeys() { - return _windowPluginHotkeys; + // Here we do not need to check PluginModified since we will check it in hotkey events + return _windowPluginHotkeys.ToDictionary(p => p.Key, p => p.Value); } public static void UpdatePluginHotkeyInfoTranslations() diff --git a/Flow.Launcher.Infrastructure/UserSettings/PluginSettings.cs b/Flow.Launcher.Infrastructure/UserSettings/PluginSettings.cs index f9fc1e509..0e881005a 100644 --- a/Flow.Launcher.Infrastructure/UserSettings/PluginSettings.cs +++ b/Flow.Launcher.Infrastructure/UserSettings/PluginSettings.cs @@ -93,7 +93,7 @@ namespace Flow.Launcher.Infrastructure.UserSettings /// Update plugin hotkey information in metadata and plugin setting. /// /// - public void UpdatePluginHotkeyInfo(Dictionary> hotkeyPluginInfo) + public void UpdatePluginHotkeyInfo(IDictionary> hotkeyPluginInfo) { foreach (var info in hotkeyPluginInfo) {