mirror of
https://github.com/microsoft/PowerToys.git
synced 2025-01-18 22:43:31 +08:00
Fix #791
This commit is contained in:
parent
759d0a825b
commit
47f396cfce
@ -266,6 +266,10 @@ namespace Wox.Core.Plugin
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// used to add action keyword for multiple action keyword plugin
|
||||
/// e.g. web search
|
||||
/// </summary>
|
||||
public static void AddActionKeyword(string id, string newActionKeyword)
|
||||
{
|
||||
var plugin = GetPluginForId(id);
|
||||
@ -277,11 +281,13 @@ namespace Wox.Core.Plugin
|
||||
{
|
||||
NonGlobalPlugins[newActionKeyword] = plugin;
|
||||
}
|
||||
AllPlugins.Add(plugin);
|
||||
|
||||
plugin.Metadata.ActionKeywords.Add(newActionKeyword);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// used to add action keyword for multiple action keyword plugin
|
||||
/// e.g. web search
|
||||
/// </summary>
|
||||
public static void RemoveActionKeyword(string id, string oldActionkeyword)
|
||||
{
|
||||
var plugin = GetPluginForId(id);
|
||||
@ -293,8 +299,6 @@ namespace Wox.Core.Plugin
|
||||
{
|
||||
NonGlobalPlugins.Remove(oldActionkeyword);
|
||||
}
|
||||
AllPlugins.Remove(plugin);
|
||||
|
||||
plugin.Metadata.ActionKeywords.Remove(oldActionkeyword);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user