From aabe96790ea4cf01e92afa7436faf35f5d0a5389 Mon Sep 17 00:00:00 2001 From: DB p Date: Thu, 13 Mar 2025 10:45:09 +0900 Subject: [PATCH] Adjust Dropshadow control disable --- .../ViewModels/SettingsPaneThemeViewModel.cs | 7 ++++++- .../SettingPages/Views/SettingsPaneTheme.xaml | 19 ++++++++++--------- 2 files changed, 16 insertions(+), 10 deletions(-) diff --git a/Flow.Launcher/SettingPages/ViewModels/SettingsPaneThemeViewModel.cs b/Flow.Launcher/SettingPages/ViewModels/SettingsPaneThemeViewModel.cs index 83a6c5769..5c668d5ab 100644 --- a/Flow.Launcher/SettingPages/ViewModels/SettingsPaneThemeViewModel.cs +++ b/Flow.Launcher/SettingPages/ViewModels/SettingsPaneThemeViewModel.cs @@ -39,11 +39,13 @@ public partial class SettingsPaneThemeViewModel : BaseModel if (ThemeManager.Instance.BlurEnabled && Settings.UseDropShadowEffect == false) DropShadowEffect = true; + OnPropertyChanged(nameof(IsDropShadowEnabled)); ThemeManager.Instance.RefreshFrame(); //uThemeManager.Instance.SetBlurForWindow(); } } public bool IsBackdropEnabled => SelectedTheme?.HasBlur ?? false; + public bool IsDropShadowEnabled => !ThemeManager.Instance.BlurEnabled; public bool DropShadowEffect { @@ -52,7 +54,6 @@ public partial class SettingsPaneThemeViewModel : BaseModel { if (ThemeManager.Instance.BlurEnabled && value == false) { - App.API.ShowMsgBox(InternationalizationManager.Instance.GetTranslation("shadowEffectNotAllowedBlur")); Settings.UseDropShadowEffect = true; return; } @@ -223,11 +224,15 @@ public partial class SettingsPaneThemeViewModel : BaseModel // ✅ BackdropTypeData 리스트에서 해당하는 값 찾기 var backdropData = BackdropTypesList.FirstOrDefault(b => b.Value == value); backdropData?.ApplyBackdrop(); + + // ✅ DropShadow 활성화 여부 갱신 + OnPropertyChanged(nameof(IsDropShadowEnabled)); } } + public bool UseSound { get => Settings.UseSound; diff --git a/Flow.Launcher/SettingPages/Views/SettingsPaneTheme.xaml b/Flow.Launcher/SettingPages/Views/SettingsPaneTheme.xaml index b429888bf..a7e904cd0 100644 --- a/Flow.Launcher/SettingPages/Views/SettingsPaneTheme.xaml +++ b/Flow.Launcher/SettingPages/Views/SettingsPaneTheme.xaml @@ -467,15 +467,15 @@ Sub="{DynamicResource shadowEffectRestart}"> - + MinWidth="160" + VerticalAlignment="Center" + DisplayMemberPath="Display" + FontSize="14" + IsEnabled="{Binding IsBackdropEnabled}" + ItemsSource="{Binding BackdropTypesList}" + SelectedValue="{Binding BackdropType, Mode=TwoWay}" + SelectedValuePath="Value" /> + @@ -486,6 +486,7 @@ Icon="" Sub="{DynamicResource shadowEffectRestart}">