diff --git a/QuickLook.Plugin/QuickLook.Plugin.ArchiveViewer/ArchiveFile/Converters.cs b/QuickLook.Plugin/QuickLook.Plugin.ArchiveViewer/ArchiveFile/Converters.cs index b407c85..858272f 100644 --- a/QuickLook.Plugin/QuickLook.Plugin.ArchiveViewer/ArchiveFile/Converters.cs +++ b/QuickLook.Plugin/QuickLook.Plugin.ArchiveViewer/ArchiveFile/Converters.cs @@ -20,6 +20,7 @@ using System; using System.Globalization; using System.Windows; using System.Windows.Data; +using System.Windows.Media; namespace QuickLook.Plugin.ArchiveViewer.ArchiveFile; @@ -142,10 +143,13 @@ public sealed class FileExtToIconConverter : DependencyObject, IMultiValueConver var name = (string)values[0]; var isFolder = (bool)values[1]; + object result; if (isFolder) - return IconManager.FindIconForDir(false); + result = IconManager.FindIconForDir(false); + else + result = IconManager.FindIconForFilename(name, false); - return IconManager.FindIconForFilename(name, false); + return result is ImageSource img ? img : DependencyProperty.UnsetValue; } public object[] ConvertBack(object value, Type[] targetTypes, object parameter, CultureInfo culture) diff --git a/QuickLook.Plugin/QuickLook.Plugin.ArchiveViewer/ChromiumResourcePackage/PakInfoPanel.xaml b/QuickLook.Plugin/QuickLook.Plugin.ArchiveViewer/ChromiumResourcePackage/PakInfoPanel.xaml index 64546c3..39eaf65 100644 --- a/QuickLook.Plugin/QuickLook.Plugin.ArchiveViewer/ChromiumResourcePackage/PakInfoPanel.xaml +++ b/QuickLook.Plugin/QuickLook.Plugin.ArchiveViewer/ChromiumResourcePackage/PakInfoPanel.xaml @@ -16,10 +16,14 @@ + + + + - +