mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-10 21:41:51 +02:00
add AutoAjustScore option for results
This commit is contained in:
@@ -5,12 +5,12 @@ using System.Text;
|
||||
|
||||
namespace WinAlfred.Plugin.System
|
||||
{
|
||||
public class ThirdpartyPluginIndicator : ISystemPlugin
|
||||
public class ThirdpartyPluginIndicator : BaseSystemPlugin
|
||||
{
|
||||
private List<PluginPair> allPlugins = new List<PluginPair>();
|
||||
private Action<string> changeQuery;
|
||||
|
||||
public List<Result> Query(Query query)
|
||||
protected override List<Result> QueryInternal(Query query)
|
||||
{
|
||||
List<Result> results = new List<Result>();
|
||||
if (string.IsNullOrEmpty(query.RawQuery)) return results;
|
||||
@@ -27,7 +27,7 @@ namespace WinAlfred.Plugin.System
|
||||
Score = 50,
|
||||
IcoPath = "Images/work.png",
|
||||
Action = () => changeQuery(metadataCopy.ActionKeyword + " "),
|
||||
DontHideWinAlfredAfterAction = true
|
||||
DontHideWinAlfredAfterSelect = true
|
||||
};
|
||||
results.Add(result);
|
||||
}
|
||||
@@ -35,27 +35,12 @@ namespace WinAlfred.Plugin.System
|
||||
return results;
|
||||
}
|
||||
|
||||
public void Init(PluginInitContext context)
|
||||
protected override void InitInternal(PluginInitContext context)
|
||||
{
|
||||
allPlugins = context.Plugins;
|
||||
changeQuery = context.ChangeQuery;
|
||||
}
|
||||
|
||||
public string Name {
|
||||
get
|
||||
{
|
||||
return "ThirdpartyPluginIndicator";
|
||||
}
|
||||
}
|
||||
|
||||
public string Description
|
||||
{
|
||||
get
|
||||
{
|
||||
return "ThirdpartyPluginIndicator";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user