mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-07 03:36:44 +02:00
Added cold start fix (#2385)
This commit is contained in:
committed by
GitHub
parent
a6e8cbc50d
commit
6290630787
@@ -613,6 +613,32 @@ namespace Wox.ViewModel
|
||||
}
|
||||
}
|
||||
|
||||
public void ColdStartFix()
|
||||
{
|
||||
// Fix Cold start for List view xaml island
|
||||
List<Result> list = new List<Result>();
|
||||
Result r = new Result
|
||||
{
|
||||
Title = "hello"
|
||||
};
|
||||
list.Add(r);
|
||||
Results.AddResults(list, "0");
|
||||
Results.Clear();
|
||||
MainWindowVisibility = System.Windows.Visibility.Collapsed;
|
||||
|
||||
// Fix Cold start for plugins
|
||||
string s = "m";
|
||||
var query = QueryBuilder.Build(s.Trim(), PluginManager.NonGlobalPlugins);
|
||||
var plugins = PluginManager.ValidPluginsForQuery(query);
|
||||
foreach (PluginPair plugin in plugins)
|
||||
{
|
||||
if (!plugin.Metadata.Disabled && plugin.Metadata.Name != "Window Walker")
|
||||
{
|
||||
var _ = PluginManager.QueryForPlugin(plugin, query);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user