From 8d042d2134a50b6e786a433fbd846ccdb4825d52 Mon Sep 17 00:00:00 2001 From: VictoriousRaptor <10308169+VictoriousRaptor@users.noreply.github.com> Date: Tue, 10 Mar 2026 22:50:40 +0800 Subject: [PATCH] Fix settings window is minimized when re-opened. (#4341) * Fix settings window is minimized when re-opened * Don't save minimized state --- Flow.Launcher/SettingWindow.xaml.cs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Flow.Launcher/SettingWindow.xaml.cs b/Flow.Launcher/SettingWindow.xaml.cs index a318592a6..054c60c8a 100644 --- a/Flow.Launcher/SettingWindow.xaml.cs +++ b/Flow.Launcher/SettingWindow.xaml.cs @@ -96,7 +96,7 @@ public partial class SettingWindow private void Window_StateChanged(object sender, EventArgs e) { RefreshMaximizeRestoreButton(); - if (IsLoaded) + if (IsLoaded && WindowState != WindowState.Minimized) { _settings.SettingWindowState = WindowState; } @@ -169,7 +169,9 @@ public partial class SettingWindow SetWindowPosition(top, left); } - WindowState = _settings.SettingWindowState; + WindowState = _settings.SettingWindowState == WindowState.Minimized + ? WindowState.Normal + : _settings.SettingWindowState; } private void SetWindowPosition(double top, double left)