Add FilePath for Explorer results preview

This commit is contained in:
Vic 2023-04-21 22:16:44 +08:00
parent 71376b8beb
commit 96f52314ef

View file

@ -235,7 +235,12 @@ namespace Flow.Launcher.Plugin.Explorer.Search
internal static Result CreateFileResult(string filePath, Query query, int score = 0, bool windowsIndexed = false)
{
Result.PreviewInfo preview = IsMedia(Path.GetExtension(filePath))
? new Result.PreviewInfo { IsMedia = true, PreviewImagePath = filePath, }
? new Result.PreviewInfo
{
IsMedia = true,
PreviewImagePath = filePath,
FilePath = filePath,
}
: Result.PreviewInfo.Default;
var title = Path.GetFileName(filePath);