Return results when query is empty for program

This commit is contained in:
Jack251970 2025-07-04 10:50:50 +08:00
parent b440aaab37
commit 80b7775412
3 changed files with 3 additions and 4 deletions

View file

@ -104,7 +104,7 @@ namespace Flow.Launcher.Plugin.Program
.Where(p => HideDuplicatedWindowsAppFilter(p, uwpsDirectories))
.Where(p => p.Enabled)
.Select(p => p.Result(query.Search, Context.API))
.Where(r => r?.Score > 0)
.Where(r => string.IsNullOrEmpty(query.Search) || r?.Score > 0)
.ToList();
}
catch (OperationCanceledException)

View file

@ -424,7 +424,7 @@ namespace Flow.Launcher.Plugin.Program.Programs
}
}
if (!matchResult.IsSearchPrecisionScoreMet())
if (!matchResult.IsSearchPrecisionScoreMet() && !string.IsNullOrEmpty(query))
return null;
var result = new Result
@ -468,7 +468,6 @@ namespace Flow.Launcher.Plugin.Program.Programs
}
};
return result;
}

View file

@ -136,7 +136,7 @@ namespace Flow.Launcher.Plugin.Program.Programs
List<string> candidates = new List<string>();
if (!matchResult.IsSearchPrecisionScoreMet())
if (!matchResult.IsSearchPrecisionScoreMet() && !string.IsNullOrEmpty(query))
{
if (ExecutableName != null) // only lnk program will need this one
{