From 1c04144573cd2e57df137cbf42f9b33d6626bc24 Mon Sep 17 00:00:00 2001 From: 2dust <31833384+2dust@users.noreply.github.com> Date: Sat, 26 Apr 2025 09:53:19 +0800 Subject: [PATCH] Code clean --- .../Views/StatusBarView.axaml.cs | 1 - v2rayN/v2rayN/App.xaml | 2 +- v2rayN/v2rayN/Views/MainWindow.xaml | 47 ++++++++++-------- v2rayN/v2rayN/Views/ProfilesView.xaml | 16 +++--- .../Views/RoutingRuleDetailsWindow.xaml | 6 +-- .../Views/RoutingRuleSettingWindow.xaml | 6 +-- v2rayN/v2rayN/Views/StatusBarView.xaml | 49 ++++++++++++------- v2rayN/v2rayN/Views/SubEditWindow.xaml | 6 +-- v2rayN/v2rayN/Views/SubSettingWindow.xaml | 6 +-- v2rayN/v2rayN/Views/ThemeSettingView.xaml | 4 +- 10 files changed, 80 insertions(+), 63 deletions(-) diff --git a/v2rayN/v2rayN.Desktop/Views/StatusBarView.axaml.cs b/v2rayN/v2rayN.Desktop/Views/StatusBarView.axaml.cs index 3c44e2d4..b646b5d6 100644 --- a/v2rayN/v2rayN.Desktop/Views/StatusBarView.axaml.cs +++ b/v2rayN/v2rayN.Desktop/Views/StatusBarView.axaml.cs @@ -8,7 +8,6 @@ using DialogHostAvalonia; using ReactiveUI; using Splat; using v2rayN.Desktop.Common; -using static QRCoder.PayloadGenerator; namespace v2rayN.Desktop.Views; diff --git a/v2rayN/v2rayN/App.xaml b/v2rayN/v2rayN/App.xaml index 2be80ccb..49a31268 100644 --- a/v2rayN/v2rayN/App.xaml +++ b/v2rayN/v2rayN/App.xaml @@ -1,9 +1,9 @@ diff --git a/v2rayN/v2rayN/Views/MainWindow.xaml b/v2rayN/v2rayN/Views/MainWindow.xaml index 6c233ef4..ea2cbe2d 100644 --- a/v2rayN/v2rayN/Views/MainWindow.xaml +++ b/v2rayN/v2rayN/Views/MainWindow.xaml @@ -1,14 +1,14 @@ - + - + - + - + - + - + - + - + + ToolTip="{x:Static resx:ResUI.menuSubEdit}"> @@ -61,9 +61,9 @@ Width="30" Height="30" Margin="{StaticResource MarginLeftRight8}" + AutomationProperties.Name="{x:Static resx:ResUI.menuProfileAutofitColumnWidth}" Style="{StaticResource MaterialDesignFloatingActionMiniLightButton}" - ToolTip="{x:Static resx:ResUI.menuProfileAutofitColumnWidth}" - AutomationProperties.Name="{x:Static resx:ResUI.menuProfileAutofitColumnWidth}"> + ToolTip="{x:Static resx:ResUI.menuProfileAutofitColumnWidth}"> + AutomationProperties.Name="{x:Static resx:ResUI.MsgServerTitle}" + Style="{StaticResource DefTextBox}" /> + VerticalAlignment="Center" + AutomationProperties.Name="{x:Static resx:ResUI.TbEnableTunAs}" /> + Style="{StaticResource MaterialDesignFloatingHintComboBox}"> @@ -88,10 +89,10 @@ Width="160" Margin="{StaticResource MarginLeftRight8}" materialDesign:HintAssist.Hint="{x:Static resx:ResUI.menuRouting}" + AutomationProperties.Name="{x:Static resx:ResUI.menuRouting}" DisplayMemberPath="Remarks" FontSize="{DynamicResource StdFontSize}" - Style="{StaticResource MaterialDesignFloatingHintComboBox}" - AutomationProperties.Name="{x:Static resx:ResUI.menuRouting}"/> + Style="{StaticResource MaterialDesignFloatingHintComboBox}" /> @@ -109,8 +110,10 @@ ToolTipText="v2rayN"> - + - + - + - + - + + Style="{StaticResource MaterialDesignFilledComboBox}" /> @@ -184,10 +195,10 @@ x:Name="cmbServers" MaxWidth="300" materialDesign:HintAssist.Hint="{x:Static resx:ResUI.menuServers}" + AutomationProperties.Name="{x:Static resx:ResUI.menuServers}" DisplayMemberPath="Text" FontSize="{DynamicResource StdFontSize}" - Style="{StaticResource MaterialDesignFilledComboBox}" - AutomationProperties.Name="{x:Static resx:ResUI.menuServers}"/> + Style="{StaticResource MaterialDesignFilledComboBox}" /> diff --git a/v2rayN/v2rayN/Views/SubEditWindow.xaml b/v2rayN/v2rayN/Views/SubEditWindow.xaml index c7cd0ea1..4d33cb11 100644 --- a/v2rayN/v2rayN/Views/SubEditWindow.xaml +++ b/v2rayN/v2rayN/Views/SubEditWindow.xaml @@ -1,11 +1,11 @@