删除退出按钮
This commit is contained in:
parent
a4348eb472
commit
9e51dea52d
@ -22,7 +22,6 @@
|
||||
<!-- 标题栏 -->
|
||||
<StackPanel Grid.ColumnSpan="2" Orientation="Horizontal" Margin="2,2,2,10">
|
||||
<TextBlock Style="{StaticResource Title}" Text="{Binding Title}" />
|
||||
<Button Content="退出" Command="{Binding ExitCommand}" Margin="16,0,0,0" Padding="12,4" />
|
||||
</StackPanel>
|
||||
|
||||
<!-- 侧导航 -->
|
||||
|
||||
@ -35,15 +35,5 @@ public class MainWindowViewModel : BindableBase
|
||||
/// </summary>
|
||||
public NavigationModel Navigation => _navigation;
|
||||
|
||||
private DelegateCommand? _exitCommand;
|
||||
|
||||
/// <summary>
|
||||
/// 退出
|
||||
/// </summary>
|
||||
public DelegateCommand ExitCommand => _exitCommand ??= new DelegateCommand(OnExit);
|
||||
|
||||
private void OnExit()
|
||||
{
|
||||
System.Windows.Application.Current.Shutdown();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user