Removed unnecessary "Close" button

This commit is contained in:
babakfp 2023-09-26 14:17:16 -07:00
parent 3c2da0a225
commit 5e17769128
10 changed files with 0 additions and 71 deletions

View file

@ -672,15 +672,6 @@ namespace v2rayN.Resx {
} }
} }
/// <summary>
/// 查找类似 Close 的本地化字符串。
/// </summary>
public static string menuClose {
get {
return ResourceManager.GetString("menuClose", resourceCulture);
}
}
/// <summary> /// <summary>
/// 查找类似 Clone selected server 的本地化字符串。 /// 查找类似 Clone selected server 的本地化字符串。
/// </summary> /// </summary>

View file

@ -436,9 +436,6 @@
<data name="menuCheckUpdate" xml:space="preserve"> <data name="menuCheckUpdate" xml:space="preserve">
<value>بررسی بروزرسانی</value> <value>بررسی بروزرسانی</value>
</data> </data>
<data name="menuClose" xml:space="preserve">
<value>بستن</value>
</data>
<data name="menuExit" xml:space="preserve"> <data name="menuExit" xml:space="preserve">
<value>خروج</value> <value>خروج</value>
</data> </data>

View file

@ -436,9 +436,6 @@
<data name="menuCheckUpdate" xml:space="preserve"> <data name="menuCheckUpdate" xml:space="preserve">
<value>Check Update</value> <value>Check Update</value>
</data> </data>
<data name="menuClose" xml:space="preserve">
<value>Close</value>
</data>
<data name="menuExit" xml:space="preserve"> <data name="menuExit" xml:space="preserve">
<value>Exit</value> <value>Exit</value>
</data> </data>

View file

@ -436,9 +436,6 @@
<data name="menuCheckUpdate" xml:space="preserve"> <data name="menuCheckUpdate" xml:space="preserve">
<value>Проверить обновления</value> <value>Проверить обновления</value>
</data> </data>
<data name="menuClose" xml:space="preserve">
<value>Закрыть</value>
</data>
<data name="menuExit" xml:space="preserve"> <data name="menuExit" xml:space="preserve">
<value>Выход</value> <value>Выход</value>
</data> </data>

View file

@ -436,9 +436,6 @@
<data name="menuCheckUpdate" xml:space="preserve"> <data name="menuCheckUpdate" xml:space="preserve">
<value>检查更新</value> <value>检查更新</value>
</data> </data>
<data name="menuClose" xml:space="preserve">
<value>关闭</value>
</data>
<data name="menuExit" xml:space="preserve"> <data name="menuExit" xml:space="preserve">
<value>退出</value> <value>退出</value>
</data> </data>

View file

@ -435,9 +435,6 @@
<data name="menuCheckUpdate" xml:space="preserve"> <data name="menuCheckUpdate" xml:space="preserve">
<value>檢查更新</value> <value>檢查更新</value>
</data> </data>
<data name="menuClose" xml:space="preserve">
<value>關閉</value>
</data>
<data name="menuExit" xml:space="preserve"> <data name="menuExit" xml:space="preserve">
<value>退出</value> <value>退出</value>
</data> </data>

View file

@ -272,23 +272,6 @@
</MenuItem.Header> </MenuItem.Header>
</MenuItem> </MenuItem>
</Menu> </Menu>
<Separator />
<Menu Margin="0,1" Style="{StaticResource ToolbarMenu}">
<MenuItem
x:Name="menuClose"
Padding="8,0"
Click="menuClose_Click">
<MenuItem.Header>
<StackPanel Orientation="Horizontal">
<materialDesign:PackIcon
Margin="0,0,8,0"
VerticalAlignment="Center"
Kind="Minimize" />
<TextBlock Text="{x:Static resx:ResUI.menuClose}" />
</StackPanel>
</MenuItem.Header>
</MenuItem>
</Menu>
<materialDesign:PopupBox <materialDesign:PopupBox
Padding="8,0" Padding="8,0"

View file

@ -410,12 +410,6 @@ namespace v2rayN.Views
} }
} }
private void menuClose_Click(object sender, RoutedEventArgs e)
{
StorageUI();
ViewModel?.ShowHideWindow(false);
}
private void menuPromotion_Click(object sender, RoutedEventArgs e) private void menuPromotion_Click(object sender, RoutedEventArgs e)
{ {
Utils.ProcessStart($"{Utils.Base64Decode(Global.PromotionUrl)}?t={DateTime.Now.Ticks}"); Utils.ProcessStart($"{Utils.Base64Decode(Global.PromotionUrl)}?t={DateTime.Now.Ticks}");

View file

@ -70,18 +70,6 @@
<TextBlock Style="{StaticResource ToolbarTextBlock}" Text="{x:Static resx:ResUI.menuSubShare}" /> <TextBlock Style="{StaticResource ToolbarTextBlock}" Text="{x:Static resx:ResUI.menuSubShare}" />
</StackPanel> </StackPanel>
</Button> </Button>
<Button
x:Name="menuClose"
Click="menuClose_Click"
IsCancel="True">
<StackPanel Orientation="Horizontal">
<materialDesign:PackIcon
Margin="0,0,8,0"
VerticalAlignment="Center"
Kind="Close" />
<TextBlock Style="{StaticResource ToolbarTextBlock}" Text="{x:Static resx:ResUI.menuClose}" />
</StackPanel>
</Button>
</ToolBar> </ToolBar>
</ToolBarTray> </ToolBarTray>

View file

@ -60,17 +60,5 @@ namespace v2rayN.Views
{ {
ViewModel.SelectedSources = lstSubscription.SelectedItems.Cast<SubItem>().ToList(); ViewModel.SelectedSources = lstSubscription.SelectedItems.Cast<SubItem>().ToList();
} }
private void menuClose_Click(object sender, System.Windows.RoutedEventArgs e)
{
if (ViewModel?.IsModified == true)
{
this.DialogResult = true;
}
else
{
this.Close();
}
}
} }
} }