- remove test customcontrol in program plugin

- change small icon in result to folder thumbnail
This commit is contained in:
DB p 2022-09-16 20:33:54 +09:00
parent b502f2af1b
commit bb0c57d3d2
3 changed files with 5 additions and 13 deletions

View file

@ -181,7 +181,8 @@ namespace Flow.Launcher.ViewModel
}
// We need to modify the property not field here to trigger the OnPropertyChanged event
Image = await Task.Run(() => ImageLoader.Load(imagePath)).ConfigureAwait(false);
//Image = await Task.Run(() => ImageLoader.Load(imagePath)).ConfigureAwait(false);
Image = ShellFolder.FromParsingName(imagePath).Thumbnail.MediumBitmapSource;
}
@ -190,7 +191,7 @@ namespace Flow.Launcher.ViewModel
var imagePath = Result.PreviewImage ?? Result.IcoPath;
// We need to modify the property not field here to trigger the OnPropertyChanged event
//PreviewImage = await Task.Run(() => ImageLoader.Load(imagePath, true)).ConfigureAwait(false);
PreviewImage = ShellFile.FromFilePath(imagePath).Thumbnail.ExtraLargeBitmapSource;
PreviewImage = ShellFolder.FromParsingName(imagePath).Thumbnail.LargeBitmapSource;
}
public Result Result { get; }

View file

@ -105,15 +105,6 @@ namespace Flow.Launcher.Plugin.Program.Programs
Score = matchResult.Score,
TitleHighlightData = matchResult.MatchData,
ContextData = this,
PreviewPanel = new Lazy<System.Windows.Controls.UserControl>(() =>
{
var control = new UserControl();
control.Content = new TextBlock()
{
Text = "test"
};
return control;
}),
Action = c =>
{
var runAsAdmin = (

View file

@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
@ -192,4 +192,4 @@ namespace Flow.Launcher.Plugin.WebSearch
public event ResultUpdatedEventHandler ResultsUpdated;
}
}
}