diff --git a/Flow.Launcher/Flow.Launcher.csproj b/Flow.Launcher/Flow.Launcher.csproj index 53c1bafc7..c280c3c7e 100644 --- a/Flow.Launcher/Flow.Launcher.csproj +++ b/Flow.Launcher/Flow.Launcher.csproj @@ -111,6 +111,10 @@ + + + + diff --git a/Flow.Launcher/Resources/CustomControlTemplate.xaml b/Flow.Launcher/Resources/CustomControlTemplate.xaml index 2ce53bfdb..e52143fa5 100644 --- a/Flow.Launcher/Resources/CustomControlTemplate.xaml +++ b/Flow.Launcher/Resources/CustomControlTemplate.xaml @@ -3695,4 +3695,1653 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - + + + + - - - - + + + + + + + + @@ -609,1579 +212,2195 @@ Grid.Row="0" Width="50" Height="50" + RenderOptions.BitmapScalingMode="HighQuality" Source="images/app.png" /> + TextAlignment="Center" /> - - - - - - - - - - - -  - - - - - - - - - - - - - - - - -  - - - - - - - - - - - -  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  - - - - - - - - - - - - - - -  - - - - - - - - - - - - -  - - - - - - - - - - - -  - - - - - - - - - - - - -  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + +  + + + + + + + + + + - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +  + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +  + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + + + - - - - - - - -  - - - - - - - + - - + + + + + + + + + + + + + +  + + + + + + + + + + + + + + + +  + + + + + - - - - - - - - -  - - - - - + + + + + + + + + + +  + + + + + + + + + + + + + + + + + + + + + + + + +  + + + + + + + + + + + + + + + + +  + + + + + + + + + + + + + + + + + + + +  + + + + + + + + + + + + + +  + + + + + + + + + + - - - -  - - - - - - - - - - - - - - - -  - - - - - - - - - - - - - - - - - - - - - - -  - - - - - - - - - - - - - - - - - - - - - - -  - - - - - - - - - - - - - - - - -  - - - - - - - - - - - - - -  - - - - - - + Click="OnTestProxyClick" + Content="{DynamicResource testProxy}" + IsEnabled="{Binding Settings.Proxy.Enabled}" /> + + + + - - - - - + + + + + + + + + +  + + + + + + + + + + + + + + + + + + + + + +  + + + + + + + + + + + + + + + +  + + + + + + + + + + + + + + + + + + + + + + +  + + + + + + + + + + + + + + + + + + + + + + +  + + + + + + + + + + + + + + + + +  + + + + + + + + + + + + + +  + + + + + + + + + + + + + diff --git a/Flow.Launcher/SettingWindow.xaml.cs b/Flow.Launcher/SettingWindow.xaml.cs index 8144c8ff8..0bba24997 100644 --- a/Flow.Launcher/SettingWindow.xaml.cs +++ b/Flow.Launcher/SettingWindow.xaml.cs @@ -24,6 +24,7 @@ using KeyEventArgs = System.Windows.Input.KeyEventArgs; using MessageBox = System.Windows.MessageBox; using TextBox = System.Windows.Controls.TextBox; using ThemeManager = ModernWpf.ThemeManager; +using Flow.Launcher.SettingPages.Views; namespace Flow.Launcher { @@ -503,5 +504,28 @@ namespace Flow.Launcher { Keyboard.Focus(pluginFilterTxb); } + + /** For Navigation View **/ + private void NavigationView_SelectionChanged(ModernWpf.Controls.NavigationView sender, ModernWpf.Controls.NavigationViewSelectionChangedEventArgs args) + { + if (args.IsSettingsSelected) + { + contentFrame.Navigate(typeof(General)); + } + else + { + var selectedItem = (ModernWpf.Controls.NavigationViewItem)args.SelectedItem; + if (selectedItem == null) + { + return; + } + string selectedItemTag = (string)selectedItem.Tag; + + sender.Header = (string)selectedItem.Content; + string pageName = $"Flow.Launcher.SettingPages.Views.{selectedItemTag}"; + Type pageType = typeof(About).Assembly.GetType(pageName); + contentFrame.Navigate(pageType, settings); + } + } } } diff --git a/Flow.Launcher/ViewModel/SettingWindowViewModel.cs b/Flow.Launcher/ViewModel/SettingWindowViewModel.cs index fe1ea4e7b..efd37b0e1 100644 --- a/Flow.Launcher/ViewModel/SettingWindowViewModel.cs +++ b/Flow.Launcher/ViewModel/SettingWindowViewModel.cs @@ -24,6 +24,7 @@ using CommunityToolkit.Mvvm.Input; using System.Globalization; using System.Runtime.CompilerServices; using Flow.Launcher.Infrastructure.Hotkey; +using ModernWpf.Media.Animation; namespace Flow.Launcher.ViewModel { @@ -33,6 +34,12 @@ namespace Flow.Launcher.ViewModel private readonly IPortable _portable; private readonly FlowLauncherJsonStorage _storage; + /* For Navigation View */ + private NavigationTransitionInfo _transitionInfo = new SlideNavigationTransitionInfo() + { + Effect = SlideNavigationTransitionEffect.FromBottom + }; + public SettingWindowViewModel(Updater updater, IPortable portable) { _updater = updater;