mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
Adjust themes
This commit is contained in:
parent
f00f98cc5c
commit
2cd51747a1
5 changed files with 20 additions and 10 deletions
|
|
@ -153,7 +153,6 @@ namespace Flow.Launcher.Core.Resource
|
|||
|
||||
//Methods.SetWindowAttribute(new WindowInteropHelper(mainWindow).Handle, DWMWINDOWATTRIBUTE.DWMWA_BORDER_COLOR, 0x00FF0000);
|
||||
//Methods.SetWindowAttribute(new WindowInteropHelper(mainWindow).Handle, DWMWINDOWATTRIBUTE.DWMWA_SYSTEMBACKDROP_TYPE, 3);
|
||||
ThemeModeColor(BlurMode());
|
||||
SetBlurForWindow();
|
||||
SetCornerForWindow();
|
||||
}
|
||||
|
|
@ -197,12 +196,11 @@ namespace Flow.Launcher.Core.Resource
|
|||
var windowBorderStyle = dict["WindowBorderStyle"] as Style;
|
||||
if (windowBorderStyle == null)
|
||||
return;
|
||||
Methods.SetWindowAttribute(new WindowInteropHelper(mainWindow).Handle, DWMWINDOWATTRIBUTE.DWMWA_SYSTEMBACKDROP_TYPE, 3);
|
||||
//Methods.SetWindowAttribute(new WindowInteropHelper(mainWindow).Handle, DWMWINDOWATTRIBUTE.DWMWA_SYSTEMBACKDROP_TYPE, 3);
|
||||
if (BlurEnabled)
|
||||
{
|
||||
//mainWindow.WindowStyle = WindowStyle.SingleBorderWindow;
|
||||
//BlurColor(BlurMode());
|
||||
ThemeModeColor(BlurMode());
|
||||
Debug.WriteLine("~~~~~~~~~~~~~~~~~~~~");
|
||||
Debug.WriteLine(BlurMode());
|
||||
windowBorderStyle.Setters.Remove(windowBorderStyle.Setters.OfType<Setter>().FirstOrDefault(x => x.Property.Name == "Background"));
|
||||
|
|
@ -219,6 +217,7 @@ namespace Flow.Launcher.Core.Resource
|
|||
Methods.SetWindowAttribute(new WindowInteropHelper(mainWindow).Handle, DWMWINDOWATTRIBUTE.DWMWA_SYSTEMBACKDROP_TYPE, 1);
|
||||
|
||||
}
|
||||
ThemeModeColor(BlurMode());
|
||||
UpdateResourceDictionary(dict);
|
||||
}
|
||||
|
||||
|
|
@ -343,6 +342,10 @@ namespace Flow.Launcher.Core.Resource
|
|||
Methods.SetWindowAttribute(new WindowInteropHelper(mainWindow).Handle, DWMWINDOWATTRIBUTE.DWMWA_USE_IMMERSIVE_DARK_MODE, 0);
|
||||
return;
|
||||
}
|
||||
else
|
||||
{
|
||||
mainWindow.Background = new SolidColorBrush(Colors.Transparent);
|
||||
}
|
||||
}
|
||||
public void BlurColor(string Color)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -190,7 +190,6 @@ namespace Flow.Launcher
|
|||
{
|
||||
ThemeManager.Instance.RefreshFrame();
|
||||
}), DispatcherPriority.Background);
|
||||
|
||||
// MouseEventHandler
|
||||
PreviewMouseMove += MainPreviewMouseMove;
|
||||
CheckFirstLaunch();
|
||||
|
|
|
|||
|
|
@ -93,7 +93,7 @@
|
|||
<Setter Property="BorderThickness" Value="0" />
|
||||
<Setter Property="Background" Value="#2F2F2F" />
|
||||
<Setter Property="Padding" Value="0 0 0 0" />
|
||||
<Setter Property="CornerRadius" Value="0" />
|
||||
<Setter Property="CornerRadius" Value="5" />
|
||||
<Setter Property="UseLayoutRounding" Value="True" />
|
||||
<Setter Property="SnapsToDevicePixels" Value="True" />
|
||||
</Style>
|
||||
|
|
|
|||
|
|
@ -1,7 +1,15 @@
|
|||
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
||||
<ResourceDictionary
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:system="clr-namespace:System;assembly=mscorlib">
|
||||
<ResourceDictionary.MergedDictionaries>
|
||||
<ResourceDictionary Source="pack://application:,,,/Themes/Base.xaml" />
|
||||
</ResourceDictionary.MergedDictionaries>
|
||||
<system:Boolean x:Key="ThemeBlurEnabled">True</system:Boolean>
|
||||
<system:String x:Key="BlurMode">Light</system:String>
|
||||
<system:String x:Key="CornerType">RoundSmall</system:String>
|
||||
<Color x:Key="lightBG">#DDFEC7D7</Color>
|
||||
<Color x:Key="darkBG">#DDFEC7D7</Color>
|
||||
<Thickness x:Key="ResultMargin">0 0 0 0</Thickness>
|
||||
<Style
|
||||
x:Key="ItemGlyph"
|
||||
|
|
@ -32,15 +40,15 @@
|
|||
TargetType="{x:Type Border}">
|
||||
<Setter Property="CornerRadius" Value="8" />
|
||||
<Setter Property="Background" Value="#fec7d7" />
|
||||
<Setter Property="BorderThickness" Value="3" />
|
||||
<Setter Property="BorderThickness" Value="0" />
|
||||
<Setter Property="BorderBrush" Value="#0e172c" />
|
||||
</Style>
|
||||
<Style
|
||||
x:Key="SeparatorStyle"
|
||||
BasedOn="{StaticResource BaseSeparatorStyle}"
|
||||
TargetType="{x:Type Rectangle}">
|
||||
<Setter Property="Fill" Value="#0e172c" />
|
||||
<Setter Property="Height" Value="3" />
|
||||
<Setter Property="Fill" Value="#DFDE89A2" />
|
||||
<Setter Property="Height" Value="1" />
|
||||
<Setter Property="Margin" Value="0 0 0 0" />
|
||||
</Style>
|
||||
<Style
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@
|
|||
</ResourceDictionary.MergedDictionaries>
|
||||
<system:Boolean x:Key="ThemeBlurEnabled">True</system:Boolean>
|
||||
<system:String x:Key="BlurMode">Auto</system:String>
|
||||
<system:String x:Key="CornerType">ROUND</system:String>
|
||||
<system:String x:Key="CornerType">Round</system:String>
|
||||
<Color x:Key="lightBG">#BFFAFAFA</Color>
|
||||
<Color x:Key="darkBG">#DD202020</Color>
|
||||
<Style
|
||||
|
|
|
|||
Loading…
Reference in a new issue