mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
replace action keyword when updating
This commit is contained in:
parent
7e799b5625
commit
e5fbfa24b4
3 changed files with 3 additions and 6 deletions
|
|
@ -274,7 +274,7 @@ namespace Flow.Launcher.Core.Plugin
|
|||
}
|
||||
|
||||
/// <summary>
|
||||
/// used to add action keyword for multiple action keyword plugin
|
||||
/// used to remove action keyword for multiple action keyword plugin
|
||||
/// e.g. web search
|
||||
/// </summary>
|
||||
public static void RemoveActionKeyword(string id, string oldActionkeyword)
|
||||
|
|
|
|||
|
|
@ -43,10 +43,7 @@ namespace Flow.Launcher.Plugin.Explorer.ViewModels
|
|||
|
||||
internal void UpdateActionKeyword(ActionKeywordProperty modifiedActionKeyword, string newActionKeyword, string oldActionKeyword)
|
||||
{
|
||||
if (Settings.SearchActionKeyword == Settings.PathSearchActionKeyword)
|
||||
PluginManager.AddActionKeyword(Context.CurrentPluginMetadata.ID, newActionKeyword);
|
||||
else
|
||||
PluginManager.ReplaceActionKeyword(Context.CurrentPluginMetadata.ID, oldActionKeyword, newActionKeyword);
|
||||
PluginManager.ReplaceActionKeyword(Context.CurrentPluginMetadata.ID, oldActionKeyword, newActionKeyword);
|
||||
|
||||
switch (modifiedActionKeyword)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ namespace Flow.Launcher.Plugin.Explorer.Views
|
|||
|
||||
this.actionKeywordListView = actionKeywordListView;
|
||||
|
||||
// Search and File Content action keyword are not allowed to be disabled, they are the default search keyword.
|
||||
// Search and File Content action keyword are not allowed to be disabled, they are the default search keywords.
|
||||
if (currentActionKeyword.KeywordProperty == ActionKeywordProperty.SearchActionKeyword
|
||||
|| currentActionKeyword.KeywordProperty == ActionKeywordProperty.FileContentSearchActionKeyword)
|
||||
chkActionKeywordEnabled.Visibility = Visibility.Collapsed;
|
||||
|
|
|
|||
Loading…
Reference in a new issue