diff --git a/Flow.Launcher.Infrastructure/Constant.cs b/Flow.Launcher.Infrastructure/Constant.cs
index 564e03638..081dd9909 100644
--- a/Flow.Launcher.Infrastructure/Constant.cs
+++ b/Flow.Launcher.Infrastructure/Constant.cs
@@ -36,7 +36,11 @@ namespace Flow.Launcher.Infrastructure
public const string DefaultTheme = "Win11Light";
public const string Themes = "Themes";
+ public const string Settings = "Settings";
+ public const string Logs = "Logs";
public const string Website = "https://flow-launcher.github.io";
+ public const string GitHub = "https://github.com/Flow-Launcher/Flow.Launcher";
+ public const string Docs = "https://flow-launcher.github.io/docs";
}
}
diff --git a/Flow.Launcher.Infrastructure/UserSettings/Settings.cs b/Flow.Launcher.Infrastructure/UserSettings/Settings.cs
index 0816d7626..b08f8568d 100644
--- a/Flow.Launcher.Infrastructure/UserSettings/Settings.cs
+++ b/Flow.Launcher.Infrastructure/UserSettings/Settings.cs
@@ -15,6 +15,7 @@ namespace Flow.Launcher.Infrastructure.UserSettings
private string language = "en";
public string Hotkey { get; set; } = $"{KeyConstant.Alt} + {KeyConstant.Space}";
public string OpenResultModifiers { get; set; } = KeyConstant.Alt;
+ public string DarkMode { get; set; } = "System";
public bool ShowOpenResultHotkey { get; set; } = true;
public double WindowSize { get; set; } = 580;
@@ -165,4 +166,11 @@ namespace Flow.Launcher.Infrastructure.UserSettings
Empty,
Preserved
}
+
+ public enum DarkMode
+ {
+ System,
+ Light,
+ Dark
+ }
}
\ No newline at end of file
diff --git a/Flow.Launcher/ActionKeywords.xaml b/Flow.Launcher/ActionKeywords.xaml
index 32892768d..3d0e00459 100644
--- a/Flow.Launcher/ActionKeywords.xaml
+++ b/Flow.Launcher/ActionKeywords.xaml
@@ -1,85 +1,136 @@
-
+
+
+
+
-
+
-
-
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
-
-
-
+
+
+
-
-
-
-
+
+
-
+
+
+
+
+
+
+
-
-
-
-
-
\ No newline at end of file
diff --git a/Flow.Launcher/App.xaml b/Flow.Launcher/App.xaml
index c5214d7ab..b8e2a1cfe 100644
--- a/Flow.Launcher/App.xaml
+++ b/Flow.Launcher/App.xaml
@@ -1,16 +1,30 @@
-
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
diff --git a/Flow.Launcher/CustomQueryHotkeySetting.xaml b/Flow.Launcher/CustomQueryHotkeySetting.xaml
index e9d486fe1..4ba55b110 100644
--- a/Flow.Launcher/CustomQueryHotkeySetting.xaml
+++ b/Flow.Launcher/CustomQueryHotkeySetting.xaml
@@ -5,13 +5,16 @@
xmlns:flowlauncher="clr-namespace:Flow.Launcher"
Title="{DynamicResource customeQueryHotkeyTitle}"
Width="500"
- Height="345"
- Background="#F3F3F3"
- BorderBrush="#cecece"
+ Background="{DynamicResource PopuBGColor}"
+ Foreground="{DynamicResource PopupTextColor}"
Icon="Images\app.png"
MouseDown="window_MouseDown"
ResizeMode="NoResize"
+ SizeToContent="Height"
WindowStartupLocation="CenterScreen">
+
+
+
@@ -23,106 +26,135 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
+ Data="M 18,11 27,20 M 18,20 27,11"
+ Stroke="{Binding Path=Foreground, RelativeSource={RelativeSource AncestorType={x:Type Button}}}"
+ StrokeThickness="1">
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Flow.Launcher/HotkeyControl.xaml b/Flow.Launcher/HotkeyControl.xaml
index 285a282ef..94cdc6703 100644
--- a/Flow.Launcher/HotkeyControl.xaml
+++ b/Flow.Launcher/HotkeyControl.xaml
@@ -1,26 +1,55 @@
-
+
-
+
-
-
-
- press key
+
+
+
+ Press key
-
-
-
+
+
\ No newline at end of file
diff --git a/Flow.Launcher/Languages/en.xaml b/Flow.Launcher/Languages/en.xaml
index 8020cc53e..9b2827d5e 100644
--- a/Flow.Launcher/Languages/en.xaml
+++ b/Flow.Launcher/Languages/en.xaml
@@ -84,6 +84,11 @@
Fail to load theme {0}, fallback to default theme
Theme Folder
Open Theme Folder
+ Dark Mode
+ System settings will take effect from the next run
+ System Default
+ Light
+ Dark
Sound Effect
Play a small sound when the search window opens
Animation
@@ -129,6 +134,8 @@
About
Website
+ Github
+ Docs
Version
You have activated Flow Launcher {0} times
Check for Updates
@@ -139,7 +146,10 @@
or go to https://github.com/Flow-Launcher/Flow.Launcher/releases to download updates manually.
Release Notes
- Usage Tips:
+ Usage Tips
+ DevTools
+ Setting Folder
+ Log Folder
Select File Manager
diff --git a/Flow.Launcher/MainWindow.xaml b/Flow.Launcher/MainWindow.xaml
index 2b2e4b85e..dd8979650 100644
--- a/Flow.Launcher/MainWindow.xaml
+++ b/Flow.Launcher/MainWindow.xaml
@@ -46,6 +46,10 @@
Key="Tab"
Command="{Binding SelectPrevItemCommand}"
Modifiers="Shift" />
+
-
+
diff --git a/Flow.Launcher/MainWindow.xaml.cs b/Flow.Launcher/MainWindow.xaml.cs
index 5b0a620ae..718606ff7 100644
--- a/Flow.Launcher/MainWindow.xaml.cs
+++ b/Flow.Launcher/MainWindow.xaml.cs
@@ -67,6 +67,7 @@ namespace Flow.Launcher
HideStartup();
// show notify icon when flowlauncher is hidden
InitializeNotifyIcon();
+ InitializeDarkMode();
WindowsInteropHelper.DisableControlBox(this);
InitProgressbarAnimation();
// since the default main window visibility is visible
@@ -476,5 +477,19 @@ namespace Flow.Launcher
{
QueryTextBox.CaretIndex = QueryTextBox.Text.Length;
}
+
+ public void InitializeDarkMode()
+ {
+ if (_settings.DarkMode == "Light")
+ {
+ ModernWpf.ThemeManager.Current.ApplicationTheme = ModernWpf.ApplicationTheme.Light;
+ }
+ else if (_settings.DarkMode == "Dark")
+ {
+ ModernWpf.ThemeManager.Current.ApplicationTheme = ModernWpf.ApplicationTheme.Dark;
+ }
+ else
+ { }
+ }
}
}
\ No newline at end of file
diff --git a/Flow.Launcher/PriorityChangeWindow.xaml b/Flow.Launcher/PriorityChangeWindow.xaml
index bbe601010..d8fda81e3 100644
--- a/Flow.Launcher/PriorityChangeWindow.xaml
+++ b/Flow.Launcher/PriorityChangeWindow.xaml
@@ -7,84 +7,117 @@
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:ui="http://schemas.modernwpf.com/2019"
Title="{DynamicResource changePriorityWindow}"
- Background="#F3F3F3"
- BorderBrush="#cecece"
+ Width="350"
+ Background="{DynamicResource PopuBGColor}"
+ Foreground="{DynamicResource PopupTextColor}"
Loaded="PriorityChangeWindow_Loaded"
MouseDown="window_MouseDown"
ResizeMode="NoResize"
- SizeToContent="WidthAndHeight"
+ SizeToContent="Height"
WindowStartupLocation="CenterScreen"
mc:Ignorable="d">
-
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Flow.Launcher/Resources/CustomControlTemplate.xaml b/Flow.Launcher/Resources/CustomControlTemplate.xaml
index 877a97645..dd9dba391 100644
--- a/Flow.Launcher/Resources/CustomControlTemplate.xaml
+++ b/Flow.Launcher/Resources/CustomControlTemplate.xaml
@@ -4,532 +4,130 @@
xmlns:system="clr-namespace:System;assembly=mscorlib"
xmlns:ui="http://schemas.modernwpf.com/2019">
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
- 0,0,8,0
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+ x:Name="border"
+ Background="{DynamicResource Color01B}"
+ BorderThickness="0"
+ SnapsToDevicePixels="true">
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+ Focusable="False"
+ RecognizesAccessKey="True" />
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+ 0,0,8,0
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Flow.Launcher/Resources/Dark.xaml b/Flow.Launcher/Resources/Dark.xaml
new file mode 100644
index 000000000..445e07c63
--- /dev/null
+++ b/Flow.Launcher/Resources/Dark.xaml
@@ -0,0 +1,1628 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #198F8F8F
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #202020
+ #2b2b2b
+ #1d1d1d
+ #cfcfcf
+ #ffffff
+ #2d2d2d
+ #363636
+ #878787
+ #292929
+ #c42b1c
+ #c81c31
+ #373737
+ #3f3f3f
+ #3f3f3f
+ #5d5d5d
+ #434343
+ #cccccc
+ #999999
+ #2a2a2a
+ #303030
+ #464646
+ #3c3c3c
+ #272727
+ #9a9a9a
+ #323232
+ #f2f2f2
+ #f5f5f5
+ #464646
+ #ffffff
+ #272727
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 0,0,0,0
+ 1,1,1,1
+ 0,0,0,0
+ 1,1,1,1
+ 0,0,0,0
+ 1,1,1,1
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 1,1,1,1
+ 0,0,0,0
+ 1,1,1,1
+ 1,1,1,1
+
+
+
+
+
+
+
+ 1,1,1,1
+ 0,0,0,1
+
+
+ 4,4,4,4
+ 4,4,4,4
+
+
+
+
+
+
+
+
+ #FF000000
+ #33000000
+ #99000000
+ #CC000000
+ #66000000
+ #FFFFFFFF
+ #33FFFFFF
+ #99FFFFFF
+ #CCFFFFFF
+ #66FFFFFF
+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+
+
+
+
+
+
+ 80
+ 1
+ 1
+ 0,0,0,4
+ 0,0,20,0
+ 20,0,0,0
+ Normal
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 1
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 0
+ 1
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 12
+ 1
+ 8,5,8,7
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 1
+
+ 64
+ 1
+ 2
+ 0,9.5,0,9.5
+ 0,0,-2,0
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ True
+ False
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Flow.Launcher/Resources/Light.xaml b/Flow.Launcher/Resources/Light.xaml
new file mode 100644
index 000000000..cee8b63cd
--- /dev/null
+++ b/Flow.Launcher/Resources/Light.xaml
@@ -0,0 +1,1622 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #198F8F8F
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #f3f3f3
+ #ffffff
+ #e5e5e5
+ #5f5f5f
+ #000000
+ #eaeaea
+ #f6f6f6
+ #878787
+ #ededed
+ #c42b1c
+ #c81c31
+ #fefefe
+ #e5e5e5
+ #d3d3d3
+ #5d5d5d
+ #f6f6f6
+ #868686
+ #b7b7b7
+ #dcdcdc
+ #5a5a5a
+ #cccccc
+ #f0f0f0
+ #f2f2f2
+ #f5f5f5
+ #878787
+ #1b1b1b
+ #f6f6f6
+
+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63 @@
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:ui="http://schemas.modernwpf.com/2019"
Title="{DynamicResource fileManagerWindow}"
- Background="#f3f3f3"
+ Width="600"
+ Background="{DynamicResource PopuBGColor}"
DataContext="{Binding RelativeSource={RelativeSource Self}}"
+ Foreground="{DynamicResource PopupTextColor}"
ResizeMode="NoResize"
- SizeToContent="WidthAndHeight"
+ SizeToContent="Height"
WindowStartupLocation="CenterScreen"
mc:Ignorable="d">
-
+
+
+
+
+
-
-
+
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
@@ -86,7 +120,7 @@
+ Fill="{StaticResource Color03B}" />
-
+
+
+
+
+
+
+
+
-
-
-
-
diff --git a/Flow.Launcher/SettingWindow.xaml b/Flow.Launcher/SettingWindow.xaml
index 81d94a6a4..9278b5680 100644
--- a/Flow.Launcher/SettingWindow.xaml
+++ b/Flow.Launcher/SettingWindow.xaml
@@ -23,8 +23,12 @@
Loaded="OnLoaded"
MouseDown="window_MouseDown"
ResizeMode="CanResizeWithGrip"
+ StateChanged="Window_StateChanged"
WindowStartupLocation="CenterScreen"
mc:Ignorable="d">
+
+
+
@@ -64,8 +68,8 @@
+
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
-
+ Grid.Row="1"
+ Margin="0,12,0,0"
+ Style="{StaticResource TabMenu}"
+ Text="Flow Launcher"
+ TextAlignment="center" />
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
+ Grid.Column="1"
+ Style="{StaticResource TabMenu}"
+ Text="{DynamicResource general}" />
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-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
-
-
+ FocusVisualMargin="5"
+ IsOn="{Binding AutoUpdates}"
+ Style="{DynamicResource SideToggleSwitch}" />
+
+
-
+
+
-
+
+
-
-
-
-
-
-
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+ Margin="10,0,18,0"
+ HorizontalContentAlignment="Center"
+ ItemsSource="{Binding MaxResultsRange}"
+ SelectedItem="{Binding Settings.MaxResultsToShow}" />
+
@@ -1791,10 +793,1245 @@
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -1805,534 +2042,473 @@
Style="{DynamicResource SettingGroupBox}">
-
-
+
+
-
-
-
-
+ Width="120"
+ Margin="0,0,18,0"
+ FontSize="14"
+ ItemsSource="{Binding OpenResultModifiersList}"
+ SelectedItem="{Binding Settings.OpenResultModifiers}" />
+
+ BorderThickness="1"
+ Style="{StaticResource SettingSeparatorStyle}" />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Margin="0,0,16,0"
+ IsEnabled="{Binding Settings.Proxy.Enabled}"
+ Text="{Binding Settings.Proxy.Port, TargetNullValue={x:Static sys:String.Empty}}" />
+
+
+
+
+
-
-
+ Style="{DynamicResource SettingTitleLabel}"
+ Text="{DynamicResource userName}" />
+
+
+
+
+
+
+
+
-
-
+
-
-
-
+
-
-
+ Width="150"
+ Margin="0,0,16,0"
+ HorizontalAlignment="Right"
+ Click="OnTestProxyClick"
+ Content="{DynamicResource testProxy}"
+ IsEnabled="{Binding Settings.Proxy.Enabled}" />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
-
+ Margin="0,0,30,0"
+ VerticalAlignment="Center"
+ Orientation="Horizontal">
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
-
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+ Style="{StaticResource SideTextAbout}">
+
+
+
+
+
+
+
-
-
+
+
-
-
+
+
+
+ Margin="0,0,30,0"
+ VerticalAlignment="Center"
+ Orientation="Horizontal">
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
+
+
+
-
+ Margin="0,0,-20,0"
+ HorizontalAlignment="Right"
+ Orientation="Horizontal">
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+ Margin="14,14,0,0"
+ HorizontalAlignment="Center"
+ VerticalAlignment="Bottom"
+ DockPanel.Dock="Bottom"
+ FontSize="12"
+ Foreground="{DynamicResource Color15B}"
+ Text="{Binding ActivatedTimes, Mode=OneWay}"
+ TextWrapping="WrapWithOverflow" />
+
+
+
+
+
+
+
+
diff --git a/Flow.Launcher/SettingWindow.xaml.cs b/Flow.Launcher/SettingWindow.xaml.cs
index 6d280ea3e..d8bc4da6a 100644
--- a/Flow.Launcher/SettingWindow.xaml.cs
+++ b/Flow.Launcher/SettingWindow.xaml.cs
@@ -1,20 +1,26 @@
-using System;
-using System.IO;
-using System.Windows;
-using System.Windows.Input;
-using System.Windows.Interop;
-using System.Windows.Navigation;
-using Microsoft.Win32;
+using Flow.Launcher.Core.ExternalPlugins;
using Flow.Launcher.Core.Plugin;
using Flow.Launcher.Core.Resource;
+using Flow.Launcher.Helper;
using Flow.Launcher.Infrastructure;
using Flow.Launcher.Infrastructure.UserSettings;
using Flow.Launcher.Plugin;
using Flow.Launcher.Plugin.SharedCommands;
using Flow.Launcher.ViewModel;
-using Flow.Launcher.Helper;
-using System.Windows.Controls;
-using Flow.Launcher.Core.ExternalPlugins;
+using Microsoft.Win32;
+using ModernWpf;
+using System;
+using System.IO;
+using System.Windows;
+using System.Windows.Forms;
+using System.Windows.Input;
+using System.Windows.Interop;
+using System.Windows.Navigation;
+using Button = System.Windows.Controls.Button;
+using Control = System.Windows.Controls.Control;
+using MessageBox = System.Windows.MessageBox;
+using TextBox = System.Windows.Controls.TextBox;
+using ThemeManager = ModernWpf.ThemeManager;
namespace Flow.Launcher
{
@@ -39,6 +45,7 @@ namespace Flow.Launcher
#region General
private void OnLoaded(object sender, RoutedEventArgs e)
{
+ RefreshMaximizeRestoreButton();
// Fix (workaround) for the window freezes after lock screen (Win+L)
// https://stackoverflow.com/questions/4951058/software-rendering-mode-wpf
HwndSource hwndSource = PresentationSource.FromVisual(this) as HwndSource;
@@ -58,39 +65,30 @@ namespace Flow.Launcher
public static void SetStartup()
{
- using (var key = Registry.CurrentUser.OpenSubKey(StartupPath, true))
- {
- key?.SetValue(Infrastructure.Constant.FlowLauncher, Infrastructure.Constant.ExecutablePath);
- }
+ using var key = Registry.CurrentUser.OpenSubKey(StartupPath, true);
+ key?.SetValue(Constant.FlowLauncher, Constant.ExecutablePath);
}
private void RemoveStartup()
{
- using (var key = Registry.CurrentUser.OpenSubKey(StartupPath, true))
- {
- key?.DeleteValue(Infrastructure.Constant.FlowLauncher, false);
- }
+ using var key = Registry.CurrentUser.OpenSubKey(StartupPath, true);
+ key?.DeleteValue(Constant.FlowLauncher, false);
}
public static bool StartupSet()
{
- using (var key = Registry.CurrentUser.OpenSubKey(StartupPath, true))
+ using var key = Registry.CurrentUser.OpenSubKey(StartupPath, true);
+ var path = key?.GetValue(Constant.FlowLauncher) as string;
+ if (path != null)
{
- var path = key?.GetValue(Infrastructure.Constant.FlowLauncher) as string;
- if (path != null)
- {
- return path == Infrastructure.Constant.ExecutablePath;
- }
- else
- {
- return false;
- }
+ return path == Constant.ExecutablePath;
}
+ return false;
}
private void OnSelectPythonDirectoryClick(object sender, RoutedEventArgs e)
{
- var dlg = new System.Windows.Forms.FolderBrowserDialog
+ var dlg = new FolderBrowserDialog
{
SelectedPath = Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles)
};
@@ -219,7 +217,7 @@ namespace Flow.Launcher
var uri = new Uri(website);
if (Uri.CheckSchemeName(uri.Scheme))
{
- SearchWeb.NewTabInBrowser(website);
+ website.NewTabInBrowser();
}
}
}
@@ -253,7 +251,7 @@ namespace Flow.Launcher
private void OnRequestNavigate(object sender, RequestNavigateEventArgs e)
{
- SearchWeb.NewTabInBrowser(e.Uri.AbsoluteUri);
+ e.Uri.AbsoluteUri.NewTabInBrowser();
e.Handled = true;
}
@@ -272,6 +270,16 @@ namespace Flow.Launcher
PluginManager.API.OpenDirectory(Path.Combine(DataLocation.DataDirectory(), Constant.Themes));
}
+ private void OpenSettingFolder(object sender, RoutedEventArgs e)
+ {
+ PluginManager.API.OpenDirectory(Path.Combine(DataLocation.DataDirectory(), Constant.Settings));
+ }
+
+ private void OpenLogFolder(object sender, RoutedEventArgs e)
+ {
+ PluginManager.API.OpenDirectory(Path.Combine(DataLocation.DataDirectory(), Constant.Logs));
+ }
+
private void OnPluginStoreRefreshClick(object sender, RoutedEventArgs e)
{
_ = viewModel.RefreshExternalPluginsAsync();
@@ -282,20 +290,64 @@ namespace Flow.Launcher
if(sender is Button { DataContext: UserPlugin plugin })
{
var pluginsManagerPlugin = PluginManager.GetPluginForId("9f8f9b14-2518-4907-b211-35ab6290dee7");
- var actionKeywrod = pluginsManagerPlugin.Metadata.ActionKeywords.Count == 0 ? "" : pluginsManagerPlugin.Metadata.ActionKeywords[0];
- API.ChangeQuery($"{actionKeywrod} install {plugin.Name}");
+ var actionKeyword = pluginsManagerPlugin.Metadata.ActionKeywords.Count == 0 ? "" : pluginsManagerPlugin.Metadata.ActionKeywords[0];
+ API.ChangeQuery($"{actionKeyword} install {plugin.Name}");
API.ShowMainWindow();
}
}
private void window_MouseDown(object sender, MouseButtonEventArgs e) /* for close hotkey popup */
{
- TextBox textBox = Keyboard.FocusedElement as TextBox;
- if (textBox != null)
+ if (Keyboard.FocusedElement is not TextBox textBox)
{
- TraversalRequest tRequest = new TraversalRequest(FocusNavigationDirection.Next);
- textBox.MoveFocus(tRequest);
+ return;
+ }
+ var tRequest = new TraversalRequest(FocusNavigationDirection.Next);
+ textBox.MoveFocus(tRequest);
+ }
+
+ private void DarkModeSelectedIndexChanged(object sender, EventArgs e) => ThemeManager.Current.ApplicationTheme = settings.DarkMode switch
+ {
+ "Light" => ApplicationTheme.Light,
+ "Dark" => ApplicationTheme.Dark,
+ "System" => null,
+ _ => ThemeManager.Current.ApplicationTheme
+ };
+
+ /* Custom TitleBar */
+
+ private void OnMinimizeButtonClick(object sender, RoutedEventArgs e)
+ {
+ WindowState = WindowState.Minimized;
+ }
+
+ private void OnMaximizeRestoreButtonClick(object sender, RoutedEventArgs e)
+ {
+ WindowState = WindowState == WindowState.Maximized ? WindowState.Normal : WindowState.Maximized;
+ }
+
+ private void OnCloseButtonClick(object sender, RoutedEventArgs e)
+ {
+ Close();
+ }
+
+ private void RefreshMaximizeRestoreButton()
+ {
+ if (WindowState == WindowState.Maximized)
+ {
+ maximizeButton.Visibility = Visibility.Collapsed;
+ restoreButton.Visibility = Visibility.Visible;
+ }
+ else
+ {
+ maximizeButton.Visibility = Visibility.Visible;
+ restoreButton.Visibility = Visibility.Collapsed;
}
}
+ private void Window_StateChanged(object sender, EventArgs e)
+ {
+ RefreshMaximizeRestoreButton();
+ }
+
}
}
\ No newline at end of file
diff --git a/Flow.Launcher/Themes/Atom.xaml b/Flow.Launcher/Themes/Atom.xaml
new file mode 100644
index 000000000..10daf817f
--- /dev/null
+++ b/Flow.Launcher/Themes/Atom.xaml
@@ -0,0 +1,103 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #2c313c
+
+
+
+
+
+
+
+
+
+
diff --git a/Flow.Launcher/Themes/Darker Glass.xaml b/Flow.Launcher/Themes/Darker Glass.xaml
new file mode 100644
index 000000000..de37dd192
--- /dev/null
+++ b/Flow.Launcher/Themes/Darker Glass.xaml
@@ -0,0 +1,95 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #545454
+
+
+
+
+
+
+
+
+
+
diff --git a/Flow.Launcher/Themes/Dracula.xaml b/Flow.Launcher/Themes/Dracula.xaml
new file mode 100644
index 000000000..c661d33e3
--- /dev/null
+++ b/Flow.Launcher/Themes/Dracula.xaml
@@ -0,0 +1,103 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ #44475a
+
+
+
+
+
+
+
+
+
+
diff --git a/Flow.Launcher/Themes/Win11Dark.xaml b/Flow.Launcher/Themes/Win11Dark.xaml
index 797241da0..31f6fb956 100644
--- a/Flow.Launcher/Themes/Win11Dark.xaml
+++ b/Flow.Launcher/Themes/Win11Dark.xaml
@@ -1,72 +1,109 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
- #2d2d2d
-
-
-
-
-
-
- #eaeaea
+ #198F8F8F
diff --git a/Flow.Launcher/Themes/Win11System.xaml b/Flow.Launcher/Themes/Win11System.xaml
new file mode 100644
index 000000000..bcc83be9f
--- /dev/null
+++ b/Flow.Launcher/Themes/Win11System.xaml
@@ -0,0 +1,159 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Flow.Launcher/ViewModel/MainViewModel.cs b/Flow.Launcher/ViewModel/MainViewModel.cs
index 8f7ed7692..1d666426f 100644
--- a/Flow.Launcher/ViewModel/MainViewModel.cs
+++ b/Flow.Launcher/ViewModel/MainViewModel.cs
@@ -154,25 +154,6 @@ namespace Flow.Launcher.ViewModel
}
}
- private void UpdateLastQUeryMode()
- {
- switch (_settings.LastQueryMode)
- {
- case LastQueryMode.Empty:
- ChangeQueryText(string.Empty);
- break;
- case LastQueryMode.Preserved:
- LastQuerySelected = true;
- break;
- case LastQueryMode.Selected:
- LastQuerySelected = false;
- break;
- default:
- throw new ArgumentException($"wrong LastQueryMode: <{_settings.LastQueryMode}>");
-
- }
- }
-
private void InitializeKeyCommands()
{
EscCommand = new RelayCommand(_ =>
@@ -212,7 +193,7 @@ namespace Flow.Launcher.ViewModel
{
SearchWeb.NewTabInBrowser("https://github.com/Flow-Launcher/Flow.Launcher/wiki/Flow-Launcher/");
});
-
+ OpenSettingCommand = new RelayCommand(_ => { App.API.OpenSettingDialog(); });
OpenResultCommand = new RelayCommand(index =>
{
var results = SelectedResults;
@@ -399,6 +380,7 @@ namespace Flow.Launcher.ViewModel
public ICommand LoadContextMenuCommand { get; set; }
public ICommand LoadHistoryCommand { get; set; }
public ICommand OpenResultCommand { get; set; }
+ public ICommand OpenSettingCommand { get; set; }
public ICommand ReloadPluginDataCommand { get; set; }
public ICommand ClearQueryCommand { get; private set; }
diff --git a/Flow.Launcher/ViewModel/SettingWindowViewModel.cs b/Flow.Launcher/ViewModel/SettingWindowViewModel.cs
index 773c4733c..5a0d816b9 100644
--- a/Flow.Launcher/ViewModel/SettingWindowViewModel.cs
+++ b/Flow.Launcher/ViewModel/SettingWindowViewModel.cs
@@ -20,6 +20,7 @@ using Flow.Launcher.Infrastructure.Storage;
using Flow.Launcher.Infrastructure.UserSettings;
using Flow.Launcher.Plugin;
using Flow.Launcher.Plugin.SharedModels;
+using ApplicationTheme = ModernWpf.ApplicationTheme;
namespace Flow.Launcher.ViewModel
{
@@ -316,6 +317,28 @@ namespace Flow.Launcher.ViewModel
}
}
+ public class DarkMode
+ {
+ public string Display { get; set; }
+ public Infrastructure.UserSettings.DarkMode Value { get; set; }
+ }
+ public List DarkModes
+ {
+ get
+ {
+ List modes = new List();
+ var enums = (Infrastructure.UserSettings.DarkMode[])Enum.GetValues(typeof(Infrastructure.UserSettings.DarkMode));
+ foreach (var e in enums)
+ {
+ var key = $"DarkMode{e}";
+ var display = _translater.GetTranslation(key);
+ var m = new DarkMode { Display = display, Value = e, };
+ modes.Add(m);
+ }
+ return modes;
+ }
+ }
+
public double WindowWidthSize
{
get => Settings.WindowSize;
@@ -364,6 +387,7 @@ namespace Flow.Launcher.ViewModel
}
}
+
public ResultsViewModel PreviewResults
{
get
@@ -506,6 +530,8 @@ namespace Flow.Launcher.ViewModel
public string Website => Constant.Website;
public string ReleaseNotes => _updater.GitHubRepository + @"/releases/latest";
public string Documentation => Constant.Documentation;
+ public string Docs => Constant.Docs;
+ public string Github => Constant.GitHub;
public static string Version => Constant.Version;
public string ActivatedTimes => string.Format(_translater.GetTranslation("about_activate_times"), Settings.ActivateTimes);
#endregion
diff --git a/Plugins/Flow.Launcher.Plugin.BrowserBookmark/Views/SettingsControl.xaml b/Plugins/Flow.Launcher.Plugin.BrowserBookmark/Views/SettingsControl.xaml
index abe1f0ad5..1ee02fa43 100644
--- a/Plugins/Flow.Launcher.Plugin.BrowserBookmark/Views/SettingsControl.xaml
+++ b/Plugins/Flow.Launcher.Plugin.BrowserBookmark/Views/SettingsControl.xaml
@@ -1,72 +1,106 @@
-
+
-
-
+
+
-
+
-
-
+
+
-
-
-
+
+
+
-
-
-
-
+
+
+
+
-
-
-
+
+
+
-
-
+
+
-
-
+
+
diff --git a/Plugins/Flow.Launcher.Plugin.WebSearch/SettingsControl.xaml b/Plugins/Flow.Launcher.Plugin.WebSearch/SettingsControl.xaml
index 68f5adc3b..2d4da962b 100644
--- a/Plugins/Flow.Launcher.Plugin.WebSearch/SettingsControl.xaml
+++ b/Plugins/Flow.Launcher.Plugin.WebSearch/SettingsControl.xaml
@@ -1,128 +1,203 @@
-
+
-
-
-
+
+
-
-
+
+
-
+
-
+
-
-
-
-
+
+
+
+
-
-
-
-
+
+
+
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
-
-
-
+
+
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
-
-
+
+
\ No newline at end of file