From 5bc7fecdcf0e606ba097b2c5ef3488cfa7b35b07 Mon Sep 17 00:00:00 2001 From: ema Date: Wed, 4 Jun 2025 17:37:22 +0800 Subject: [PATCH] Improve App/PE titlebar UI/UX --- .../InfoPanels/WgtInfoPanel.xaml | 2 +- .../QuickLook.Plugin.AppViewer/Plugin.cs | 7 ++++++- .../Resources/{uni-app.png => uni.png} | Bin .../QuickLook.Plugin.PEViewer/Plugin.cs | 5 +++++ 4 files changed, 12 insertions(+), 2 deletions(-) rename QuickLook.Plugin/QuickLook.Plugin.AppViewer/Resources/{uni-app.png => uni.png} (100%) diff --git a/QuickLook.Plugin/QuickLook.Plugin.AppViewer/InfoPanels/WgtInfoPanel.xaml b/QuickLook.Plugin/QuickLook.Plugin.AppViewer/InfoPanels/WgtInfoPanel.xaml index d8d72a5..042db5a 100644 --- a/QuickLook.Plugin/QuickLook.Plugin.AppViewer/InfoPanels/WgtInfoPanel.xaml +++ b/QuickLook.Plugin/QuickLook.Plugin.AppViewer/InfoPanels/WgtInfoPanel.xaml @@ -30,7 +30,7 @@ Height="120" Margin="8" VerticalAlignment="Top" - Source="/QuickLook.Plugin.AppViewer;component/Resources/uni-app.png" + Source="/QuickLook.Plugin.AppViewer;component/Resources/uni.png" Stretch="Fill" /> diff --git a/QuickLook.Plugin/QuickLook.Plugin.AppViewer/Plugin.cs b/QuickLook.Plugin/QuickLook.Plugin.AppViewer/Plugin.cs index 33b9820..a3ffd6a 100644 --- a/QuickLook.Plugin/QuickLook.Plugin.AppViewer/Plugin.cs +++ b/QuickLook.Plugin/QuickLook.Plugin.AppViewer/Plugin.cs @@ -76,12 +76,17 @@ public class Plugin : IViewer ".apk" => new Size { Width = 560, Height = 505 }, ".ipa" => new Size { Width = 560, Height = 510 }, ".hap" => new Size { Width = 560, Height = 500 }, - ".msi" => new Size { Width = 520, Height = 230 }, + ".msi" => new Size { Width = 560, Height = 230 }, ".msix" or ".msixbundle" or ".appx" or ".appxbundle" => new Size { Width = 560, Height = 328 }, ".deb" => new Size { Width = 600, Height = 345 }, ".wgt" or ".wgtu" => new Size { Width = 600, Height = 345 }, _ => throw new NotSupportedException("Extension is not supported."), }; + context.Title = string.Empty; + context.TitlebarOverlap = false; + context.TitlebarBlurVisibility = false; + context.TitlebarColourVisibility = false; + context.FullWindowDragging = true; } public void View(string path, ContextObject context) diff --git a/QuickLook.Plugin/QuickLook.Plugin.AppViewer/Resources/uni-app.png b/QuickLook.Plugin/QuickLook.Plugin.AppViewer/Resources/uni.png similarity index 100% rename from QuickLook.Plugin/QuickLook.Plugin.AppViewer/Resources/uni-app.png rename to QuickLook.Plugin/QuickLook.Plugin.AppViewer/Resources/uni.png diff --git a/QuickLook.Plugin/QuickLook.Plugin.PEViewer/Plugin.cs b/QuickLook.Plugin/QuickLook.Plugin.PEViewer/Plugin.cs index 1677534..372015c 100644 --- a/QuickLook.Plugin/QuickLook.Plugin.PEViewer/Plugin.cs +++ b/QuickLook.Plugin/QuickLook.Plugin.PEViewer/Plugin.cs @@ -51,6 +51,11 @@ public class Plugin : IViewer public void Prepare(string path, ContextObject context) { context.PreferredSize = new Size { Width = 520, Height = 192 }; + context.Title = string.Empty; + context.TitlebarOverlap = false; + context.TitlebarBlurVisibility = false; + context.TitlebarColourVisibility = false; + context.FullWindowDragging = true; } public void View(string path, ContextObject context)