mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-06 03:07:04 +02:00
Fix UI flickering under .net 4.5
1. This is part of .net 4.5 fix, check #393 to see more 2. This bug is introduced since commit df4ca3fecc9784a3b55f93806d8b2a662523056f
This commit is contained in:
@@ -30,9 +30,9 @@ namespace Wox.Plugin.Program
|
||||
{
|
||||
|
||||
var fuzzyMather = FuzzyMatcher.Create(query.Search);
|
||||
var results = programs.Where(o => MatchProgram(o, fuzzyMather)).
|
||||
var results = programs.Where(p => MatchProgram(p, fuzzyMather)).
|
||||
Select(ScoreFilter).
|
||||
OrderByDescending(o => o.Score)
|
||||
OrderByDescending(p => p.Score)
|
||||
.Select(c => new Result()
|
||||
{
|
||||
Title = c.Title,
|
||||
@@ -62,8 +62,7 @@ namespace Wox.Plugin.Program
|
||||
{
|
||||
var scores = new List<string> { program.Title, program.PinyinTitle, program.AbbrTitle, program.ExecuteName };
|
||||
program.Score = scores.Select(s => matcher.Evaluate(s ?? string.Empty).Score).Max();
|
||||
if (program.Score > 0) return true;
|
||||
else return false;
|
||||
return program.Score > 0;
|
||||
}
|
||||
|
||||
public void Init(PluginInitContext context)
|
||||
|
||||
Reference in New Issue
Block a user