2026-06-28 06:51:35 +00:00
|
|
|
|
<!--
|
|
|
|
|
|
MainWindow.xaml - Better-Seewo 管理器主窗口
|
|
|
|
|
|
Fluent Design 风格,包含自定义标题栏、左侧导航栏、右侧内容区域和底部状态栏
|
|
|
|
|
|
作者:雾启工作室
|
|
|
|
|
|
-->
|
|
|
|
|
|
|
|
|
|
|
|
<Window x:Class="Better_Seewo.Manager.MainWindow"
|
|
|
|
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
|
|
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
|
|
|
|
Title="Better-Seewo 管理器"
|
|
|
|
|
|
Width="960" Height="600"
|
|
|
|
|
|
MinWidth="800" MinHeight="500"
|
|
|
|
|
|
WindowStyle="None"
|
|
|
|
|
|
AllowsTransparency="True"
|
|
|
|
|
|
Background="Transparent"
|
|
|
|
|
|
WindowStartupLocation="CenterScreen"
|
|
|
|
|
|
Loaded="Window_Loaded">
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ===== 窗口入场动画 ===== -->
|
|
|
|
|
|
<Window.Triggers>
|
|
|
|
|
|
<EventTrigger RoutedEvent="Window.Loaded">
|
|
|
|
|
|
<BeginStoryboard>
|
|
|
|
|
|
<Storyboard>
|
|
|
|
|
|
<!-- 窗口从透明渐入不透明 -->
|
|
|
|
|
|
<DoubleAnimation Storyboard.TargetName="RootBorder"
|
|
|
|
|
|
Storyboard.TargetProperty="Opacity"
|
|
|
|
|
|
From="0" To="1"
|
|
|
|
|
|
Duration="0:0:0.500">
|
|
|
|
|
|
<DoubleAnimation.EasingFunction>
|
|
|
|
|
|
<CubicEase EasingMode="EaseOut" />
|
|
|
|
|
|
</DoubleAnimation.EasingFunction>
|
|
|
|
|
|
</DoubleAnimation>
|
|
|
|
|
|
<!-- 窗口从略小缩放到正常大小 -->
|
|
|
|
|
|
<DoubleAnimation Storyboard.TargetName="RootBorder"
|
|
|
|
|
|
Storyboard.TargetProperty="(UIElement.RenderTransform).(ScaleTransform.ScaleX)"
|
|
|
|
|
|
From="0.97" To="1.0"
|
|
|
|
|
|
Duration="0:0:0.500">
|
|
|
|
|
|
<DoubleAnimation.EasingFunction>
|
|
|
|
|
|
<CubicEase EasingMode="EaseOut" />
|
|
|
|
|
|
</DoubleAnimation.EasingFunction>
|
|
|
|
|
|
</DoubleAnimation>
|
|
|
|
|
|
<DoubleAnimation Storyboard.TargetName="RootBorder"
|
|
|
|
|
|
Storyboard.TargetProperty="(UIElement.RenderTransform).(ScaleTransform.ScaleY)"
|
|
|
|
|
|
From="0.97" To="1.0"
|
|
|
|
|
|
Duration="0:0:0.500">
|
|
|
|
|
|
<DoubleAnimation.EasingFunction>
|
|
|
|
|
|
<CubicEase EasingMode="EaseOut" />
|
|
|
|
|
|
</DoubleAnimation.EasingFunction>
|
|
|
|
|
|
</DoubleAnimation>
|
|
|
|
|
|
</Storyboard>
|
|
|
|
|
|
</BeginStoryboard>
|
|
|
|
|
|
</EventTrigger>
|
|
|
|
|
|
</Window.Triggers>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ===== 窗口根容器(带阴影和圆角) ===== -->
|
|
|
|
|
|
<Border x:Name="RootBorder"
|
|
|
|
|
|
Background="{DynamicResource BackgroundBrush}"
|
|
|
|
|
|
CornerRadius="{DynamicResource StandardCornerRadius}"
|
|
|
|
|
|
BorderThickness="1"
|
|
|
|
|
|
BorderBrush="{DynamicResource BorderBrush}"
|
|
|
|
|
|
ClipToBounds="True"
|
|
|
|
|
|
Opacity="0">
|
|
|
|
|
|
|
2026-06-28 07:55:33 +00:00
|
|
|
|
<Border.Effect>
|
|
|
|
|
|
<DropShadowEffect ShadowDepth="4" BlurRadius="20" Opacity="0.5" Color="#000000" />
|
|
|
|
|
|
</Border.Effect>
|
|
|
|
|
|
|
2026-06-28 06:51:35 +00:00
|
|
|
|
<!-- 缩放变换(用于入场动画) -->
|
|
|
|
|
|
<Border.RenderTransform>
|
|
|
|
|
|
<ScaleTransform ScaleX="1.0" ScaleY="1.0" />
|
|
|
|
|
|
</Border.RenderTransform>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ===== 主网格布局 ===== -->
|
|
|
|
|
|
<Grid>
|
|
|
|
|
|
<Grid.RowDefinitions>
|
|
|
|
|
|
<!-- 顶部标题栏 -->
|
|
|
|
|
|
<RowDefinition Height="40" />
|
|
|
|
|
|
<!-- 中间内容区域(导航栏 + 页面) -->
|
|
|
|
|
|
<RowDefinition Height="*" />
|
|
|
|
|
|
<!-- 底部状态栏 -->
|
|
|
|
|
|
<RowDefinition Height="28" />
|
|
|
|
|
|
</Grid.RowDefinitions>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ============================== -->
|
|
|
|
|
|
<!-- ===== 顶部自定义标题栏 ===== -->
|
|
|
|
|
|
<!-- ============================== -->
|
|
|
|
|
|
<Grid Grid.Row="0"
|
|
|
|
|
|
Background="{DynamicResource TitleBarBackgroundBrush}"
|
|
|
|
|
|
MouseLeftButtonDown="TitleBar_MouseLeftButtonDown">
|
|
|
|
|
|
|
|
|
|
|
|
<Grid.ColumnDefinitions>
|
|
|
|
|
|
<!-- 左侧:应用图标和标题 -->
|
|
|
|
|
|
<ColumnDefinition Width="Auto" />
|
|
|
|
|
|
<!-- 中间:标题文字 -->
|
|
|
|
|
|
<ColumnDefinition Width="*" />
|
|
|
|
|
|
<!-- 右侧:窗口控制按钮 -->
|
|
|
|
|
|
<ColumnDefinition Width="Auto" />
|
|
|
|
|
|
</Grid.ColumnDefinitions>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- 应用图标(用Path绘制简洁的六边形Logo) -->
|
|
|
|
|
|
<Border Grid.Column="0"
|
|
|
|
|
|
Width="28" Height="28"
|
|
|
|
|
|
Margin="8,0,0,0"
|
|
|
|
|
|
VerticalAlignment="Center"
|
|
|
|
|
|
CornerRadius="6">
|
|
|
|
|
|
<Path Data="M14 2L25 8V18L14 24L3 18V8L14 2Z"
|
|
|
|
|
|
Fill="{DynamicResource AccentBrush}"
|
|
|
|
|
|
Stretch="Uniform"
|
|
|
|
|
|
Margin="2" />
|
|
|
|
|
|
</Border>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- 标题文字 -->
|
|
|
|
|
|
<TextBlock Grid.Column="1"
|
|
|
|
|
|
Text="Better-Seewo 管理器"
|
|
|
|
|
|
FontSize="13"
|
|
|
|
|
|
FontWeight="SemiBold"
|
|
|
|
|
|
Foreground="{DynamicResource TextPrimaryBrush}"
|
|
|
|
|
|
VerticalAlignment="Center"
|
|
|
|
|
|
Margin="10,0,0,0" />
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ===== 窗口控制按钮组 ===== -->
|
|
|
|
|
|
<StackPanel Grid.Column="2"
|
|
|
|
|
|
Orientation="Horizontal"
|
|
|
|
|
|
HorizontalAlignment="Right">
|
|
|
|
|
|
|
|
|
|
|
|
<!-- 最小化按钮 -->
|
|
|
|
|
|
<Button x:Name="BtnMinimize"
|
|
|
|
|
|
Content=""
|
|
|
|
|
|
FontFamily="Segoe MDL2 Assets"
|
|
|
|
|
|
FontSize="10"
|
|
|
|
|
|
Width="46" Height="40"
|
|
|
|
|
|
Background="Transparent"
|
|
|
|
|
|
Foreground="{DynamicResource TextPrimaryBrush}"
|
|
|
|
|
|
BorderThickness="0"
|
|
|
|
|
|
Cursor="Hand"
|
|
|
|
|
|
Click="BtnMinimize_Click"
|
|
|
|
|
|
Style="{DynamicResource WindowButtonStyle}" />
|
|
|
|
|
|
|
|
|
|
|
|
<!-- 最大化/还原按钮 -->
|
|
|
|
|
|
<Button x:Name="BtnMaximize"
|
|
|
|
|
|
Content=""
|
|
|
|
|
|
FontFamily="Segoe MDL2 Assets"
|
|
|
|
|
|
FontSize="10"
|
|
|
|
|
|
Width="46" Height="40"
|
|
|
|
|
|
Background="Transparent"
|
|
|
|
|
|
Foreground="{DynamicResource TextPrimaryBrush}"
|
|
|
|
|
|
BorderThickness="0"
|
|
|
|
|
|
Cursor="Hand"
|
|
|
|
|
|
Click="BtnMaximize_Click"
|
|
|
|
|
|
Style="{DynamicResource WindowButtonStyle}" />
|
|
|
|
|
|
|
|
|
|
|
|
<!-- 关闭按钮(悬停红色) -->
|
|
|
|
|
|
<Button x:Name="BtnClose"
|
|
|
|
|
|
Content=""
|
|
|
|
|
|
FontFamily="Segoe MDL2 Assets"
|
|
|
|
|
|
FontSize="10"
|
|
|
|
|
|
Width="46" Height="40"
|
|
|
|
|
|
Background="Transparent"
|
|
|
|
|
|
Foreground="{DynamicResource TextPrimaryBrush}"
|
|
|
|
|
|
BorderThickness="0"
|
|
|
|
|
|
Cursor="Hand"
|
|
|
|
|
|
Click="BtnClose_Click"
|
|
|
|
|
|
Style="{DynamicResource CloseButtonStyle}" />
|
|
|
|
|
|
|
|
|
|
|
|
</StackPanel>
|
|
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ============================== -->
|
|
|
|
|
|
<!-- ===== 中间内容区域 ===== -->
|
|
|
|
|
|
<!-- ============================== -->
|
|
|
|
|
|
<Grid Grid.Row="1">
|
|
|
|
|
|
|
|
|
|
|
|
<Grid.ColumnDefinitions>
|
|
|
|
|
|
<!-- 左侧导航栏 -->
|
|
|
|
|
|
<ColumnDefinition Width="60" />
|
|
|
|
|
|
<!-- 右侧内容区域 -->
|
|
|
|
|
|
<ColumnDefinition Width="*" />
|
|
|
|
|
|
</Grid.ColumnDefinitions>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ===== 左侧导航栏 ===== -->
|
|
|
|
|
|
<Border Grid.Column="0"
|
|
|
|
|
|
Background="{DynamicResource SecondaryBackgroundBrush}"
|
|
|
|
|
|
CornerRadius="{DynamicResource StandardCornerRadius}"
|
2026-06-28 07:55:33 +00:00
|
|
|
|
Margin="4,4,0,4">
|
|
|
|
|
|
|
|
|
|
|
|
<Border.Effect>
|
|
|
|
|
|
<DropShadowEffect ShadowDepth="2" BlurRadius="8" Opacity="0.25" Color="#000000" />
|
|
|
|
|
|
</Border.Effect>
|
2026-06-28 06:51:35 +00:00
|
|
|
|
|
|
|
|
|
|
<!-- 导航按钮列表(竖向排列) -->
|
|
|
|
|
|
<StackPanel VerticalAlignment="Center"
|
|
|
|
|
|
HorizontalAlignment="Center">
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ===== 安装按钮(齿轮图标) ===== -->
|
|
|
|
|
|
<Grid>
|
|
|
|
|
|
<!-- 选中指示条(左侧竖条) -->
|
|
|
|
|
|
<Border x:Name="IndicatorInstall"
|
|
|
|
|
|
Width="0"
|
|
|
|
|
|
Height="24"
|
|
|
|
|
|
HorizontalAlignment="Left"
|
|
|
|
|
|
VerticalAlignment="Center"
|
|
|
|
|
|
Margin="0,0,0,0"
|
|
|
|
|
|
CornerRadius="0,2,2,0"
|
|
|
|
|
|
Background="{DynamicResource AccentBrush}" />
|
|
|
|
|
|
|
|
|
|
|
|
<Button x:Name="BtnInstall"
|
|
|
|
|
|
Tag="Install"
|
|
|
|
|
|
Width="48" Height="48"
|
|
|
|
|
|
Margin="4"
|
|
|
|
|
|
Padding="0"
|
|
|
|
|
|
Background="Transparent"
|
|
|
|
|
|
Foreground="{DynamicResource TextSecondaryBrush}"
|
|
|
|
|
|
BorderThickness="0"
|
|
|
|
|
|
Cursor="Hand"
|
|
|
|
|
|
Click="NavButton_Click"
|
|
|
|
|
|
Style="{DynamicResource NavButtonStyle}">
|
|
|
|
|
|
|
|
|
|
|
|
<!-- 齿轮图标 -->
|
|
|
|
|
|
<Path Data="M12,15.5A3.5,3.5 0 0,1 8.5,12A3.5,3.5 0 0,1 12,8.5A3.5,3.5 0 0,1 15.5,12A3.5,3.5 0 0,1 12,15.5M19.43,12.97C19.47,12.65 19.5,12.33 19.5,12C19.5,11.67 19.47,11.34 19.43,11L21.54,9.37C21.73,9.22 21.78,8.95 21.66,8.73L19.66,5.27C19.54,5.05 19.27,4.96 19.05,5.05L16.56,6.05C16.04,5.66 15.5,5.32 14.87,5.07L14.5,2.42C14.46,2.18 14.25,2 14,2H10C9.75,2 9.54,2.18 9.5,2.42L9.13,5.07C8.5,5.32 7.96,5.66 7.44,6.05L4.95,5.05C4.73,4.96 4.46,5.05 4.34,5.27L2.34,8.73C2.21,8.95 2.27,9.22 2.46,9.37L4.57,11C4.53,11.34 4.5,11.67 4.5,12C4.5,12.33 4.53,12.65 4.57,13L2.46,14.63C2.27,14.78 2.21,15.05 2.34,15.27L4.34,18.73C4.46,18.95 4.73,19.04 4.95,18.95L7.44,17.94C7.96,18.34 8.5,18.68 9.13,18.93L9.5,21.58C9.54,21.82 9.75,22 10,22H14C14.25,22 14.46,21.82 14.5,21.58L14.87,18.93C15.5,18.67 16.04,18.34 16.56,17.94L19.05,18.95C19.27,19.04 19.54,18.95 19.66,18.73L21.66,15.27C21.78,15.05 21.73,14.78 21.54,14.63L19.43,12.97Z"
|
|
|
|
|
|
Stretch="Uniform"
|
|
|
|
|
|
Fill="{Binding Path=Foreground, RelativeSource={RelativeSource AncestorType=Button}}"
|
|
|
|
|
|
Width="22" Height="22" />
|
|
|
|
|
|
</Button>
|
|
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ===== 墨迹按钮(画笔图标) ===== -->
|
|
|
|
|
|
<Grid>
|
|
|
|
|
|
<Border x:Name="IndicatorInk"
|
|
|
|
|
|
Width="0"
|
|
|
|
|
|
Height="24"
|
|
|
|
|
|
HorizontalAlignment="Left"
|
|
|
|
|
|
VerticalAlignment="Center"
|
|
|
|
|
|
Margin="0,0,0,0"
|
|
|
|
|
|
CornerRadius="0,2,2,0"
|
|
|
|
|
|
Background="{DynamicResource AccentBrush}" />
|
|
|
|
|
|
|
|
|
|
|
|
<Button x:Name="BtnInk"
|
|
|
|
|
|
Tag="Ink"
|
|
|
|
|
|
Width="48" Height="48"
|
|
|
|
|
|
Margin="4"
|
|
|
|
|
|
Padding="0"
|
|
|
|
|
|
Background="Transparent"
|
|
|
|
|
|
Foreground="{DynamicResource TextSecondaryBrush}"
|
|
|
|
|
|
BorderThickness="0"
|
|
|
|
|
|
Cursor="Hand"
|
|
|
|
|
|
Click="NavButton_Click"
|
|
|
|
|
|
Style="{DynamicResource NavButtonStyle}">
|
|
|
|
|
|
|
|
|
|
|
|
<!-- 画笔图标 -->
|
|
|
|
|
|
<Path Data="M20.71,7.04C21.1,6.65 21.1,6 20.71,5.63L18.37,3.29C18,2.9 17.35,2.9 16.96,3.29L15.28,4.96L19.03,8.71M3,17.25V21H6.75L17.81,9.93L14.06,6.18L3,17.25Z"
|
|
|
|
|
|
Stretch="Uniform"
|
|
|
|
|
|
Fill="{Binding Path=Foreground, RelativeSource={RelativeSource AncestorType=Button}}"
|
|
|
|
|
|
Width="22" Height="22" />
|
|
|
|
|
|
</Button>
|
|
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ===== 转换按钮(箭头图标) ===== -->
|
|
|
|
|
|
<Grid>
|
|
|
|
|
|
<Border x:Name="IndicatorConvert"
|
|
|
|
|
|
Width="0"
|
|
|
|
|
|
Height="24"
|
|
|
|
|
|
HorizontalAlignment="Left"
|
|
|
|
|
|
VerticalAlignment="Center"
|
|
|
|
|
|
Margin="0,0,0,0"
|
|
|
|
|
|
CornerRadius="0,2,2,0"
|
|
|
|
|
|
Background="{DynamicResource AccentBrush}" />
|
|
|
|
|
|
|
|
|
|
|
|
<Button x:Name="BtnConvert"
|
|
|
|
|
|
Tag="Convert"
|
|
|
|
|
|
Width="48" Height="48"
|
|
|
|
|
|
Margin="4"
|
|
|
|
|
|
Padding="0"
|
|
|
|
|
|
Background="Transparent"
|
|
|
|
|
|
Foreground="{DynamicResource TextSecondaryBrush}"
|
|
|
|
|
|
BorderThickness="0"
|
|
|
|
|
|
Cursor="Hand"
|
|
|
|
|
|
Click="NavButton_Click"
|
|
|
|
|
|
Style="{DynamicResource NavButtonStyle}">
|
|
|
|
|
|
|
|
|
|
|
|
<!-- 箭头转换图标 -->
|
|
|
|
|
|
<Path Data="M16,6L18.29,8.29L13.41,13.17L14.83,14.59L19.71,9.71L22,12V6M16,18H8V6H10V4H8C6.89,4 6,4.89 6,6V18A2,2 0 0,0 8,20H16A2,2 0 0,0 18,18V16H16V18Z"
|
|
|
|
|
|
Stretch="Uniform"
|
|
|
|
|
|
Fill="{Binding Path=Foreground, RelativeSource={RelativeSource AncestorType=Button}}"
|
|
|
|
|
|
Width="22" Height="22" />
|
|
|
|
|
|
</Button>
|
|
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ===== 触摸按钮(手掌图标) ===== -->
|
|
|
|
|
|
<Grid>
|
|
|
|
|
|
<Border x:Name="IndicatorTouch"
|
|
|
|
|
|
Width="0"
|
|
|
|
|
|
Height="24"
|
|
|
|
|
|
HorizontalAlignment="Left"
|
|
|
|
|
|
VerticalAlignment="Center"
|
|
|
|
|
|
Margin="0,0,0,0"
|
|
|
|
|
|
CornerRadius="0,2,2,0"
|
|
|
|
|
|
Background="{DynamicResource AccentBrush}" />
|
|
|
|
|
|
|
|
|
|
|
|
<Button x:Name="BtnTouch"
|
|
|
|
|
|
Tag="Touch"
|
|
|
|
|
|
Width="48" Height="48"
|
|
|
|
|
|
Margin="4"
|
|
|
|
|
|
Padding="0"
|
|
|
|
|
|
Background="Transparent"
|
|
|
|
|
|
Foreground="{DynamicResource TextSecondaryBrush}"
|
|
|
|
|
|
BorderThickness="0"
|
|
|
|
|
|
Cursor="Hand"
|
|
|
|
|
|
Click="NavButton_Click"
|
|
|
|
|
|
Style="{DynamicResource NavButtonStyle}">
|
|
|
|
|
|
|
|
|
|
|
|
<!-- 手掌/触摸图标 -->
|
|
|
|
|
|
<Path Data="M9,11.75A1.25,1.25 0 0,0 7.75,10.5A1.25,1.25 0 0,0 6.5,11.75V17.25A5.75,5.75 0 0,0 12.25,23H17.25A5.75,5.75 0 0,0 23,17.25V9.25A1.25,1.25 0 0,0 21.75,8A1.25,1.25 0 0,0 20.5,9.25V12H19V7.25A1.25,1.25 0 0,0 17.75,6A1.25,1.25 0 0,0 16.5,7.25V12H15V5.25A1.25,1.25 0 0,0 13.75,4A1.25,1.25 0 0,0 12.5,5.25V12H11V11.75A1.25,1.25 0 0,0 9.75,10.5M9,11.75V12H11V11.75A1.25,1.25 0 0,1 12.5,10.5V5.25C12.5,4.56 13.06,4 13.75,4C14.44,4 15,4.56 15,5.25V12H16.5V7.25C16.5,6.56 17.06,6 17.75,6C18.44,6 19,6.56 19,7.25V12H20.5V9.25C20.5,8.56 21.06,8 21.75,8C22.44,8 23,8.56 23,9.25V17.25C23,20.42 20.42,23 17.25,23H12.25C9.08,23 6.5,20.42 6.5,17.25V11.75C6.5,11.06 7.06,10.5 7.75,10.5C8.44,10.5 9,11.06 9,11.75Z"
|
|
|
|
|
|
Stretch="Uniform"
|
|
|
|
|
|
Fill="{Binding Path=Foreground, RelativeSource={RelativeSource AncestorType=Button}}"
|
|
|
|
|
|
Width="22" Height="22" />
|
|
|
|
|
|
</Button>
|
|
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ===== 激活按钮(钥匙图标) ===== -->
|
|
|
|
|
|
<Grid>
|
|
|
|
|
|
<Border x:Name="IndicatorActivate"
|
|
|
|
|
|
Width="0"
|
|
|
|
|
|
Height="24"
|
|
|
|
|
|
HorizontalAlignment="Left"
|
|
|
|
|
|
VerticalAlignment="Center"
|
|
|
|
|
|
Margin="0,0,0,0"
|
|
|
|
|
|
CornerRadius="0,2,2,0"
|
|
|
|
|
|
Background="{DynamicResource AccentBrush}" />
|
|
|
|
|
|
|
|
|
|
|
|
<Button x:Name="BtnActivate"
|
|
|
|
|
|
Tag="Activate"
|
|
|
|
|
|
Width="48" Height="48"
|
|
|
|
|
|
Margin="4"
|
|
|
|
|
|
Padding="0"
|
|
|
|
|
|
Background="Transparent"
|
|
|
|
|
|
Foreground="{DynamicResource TextSecondaryBrush}"
|
|
|
|
|
|
BorderThickness="0"
|
|
|
|
|
|
Cursor="Hand"
|
|
|
|
|
|
Click="NavButton_Click"
|
|
|
|
|
|
Style="{DynamicResource NavButtonStyle}">
|
|
|
|
|
|
|
|
|
|
|
|
<!-- 钥匙图标 -->
|
|
|
|
|
|
<Path Data="M7,14A2,2 0 0,1 9,12A2,2 0 0,1 11,14A2,2 0 0,1 9,16A2,2 0 0,1 7,14M12.65,10C11.83,7.67 9.61,6 7,6C3.69,6 1,8.69 1,12C1,15.31 3.69,18 7,18C9.61,18 11.83,16.33 12.65,14H17V17H20V14H23V11H12.65Z"
|
|
|
|
|
|
Stretch="Uniform"
|
|
|
|
|
|
Fill="{Binding Path=Foreground, RelativeSource={RelativeSource AncestorType=Button}}"
|
|
|
|
|
|
Width="22" Height="22" />
|
|
|
|
|
|
</Button>
|
|
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
|
|
|
|
</StackPanel>
|
|
|
|
|
|
</Border>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ===== 右侧内容区域(Frame导航) ===== -->
|
|
|
|
|
|
<Border Grid.Column="1"
|
|
|
|
|
|
Margin="8,4,4,4"
|
|
|
|
|
|
CornerRadius="{DynamicResource StandardCornerRadius}"
|
|
|
|
|
|
Background="{DynamicResource CardBackgroundBrush}"
|
2026-06-28 07:55:33 +00:00
|
|
|
|
ClipToBounds="True">
|
|
|
|
|
|
|
|
|
|
|
|
<Border.Effect>
|
|
|
|
|
|
<DropShadowEffect ShadowDepth="2" BlurRadius="12" Opacity="0.3" Color="#000000" />
|
|
|
|
|
|
</Border.Effect>
|
2026-06-28 06:51:35 +00:00
|
|
|
|
|
|
|
|
|
|
<!-- 页面导航Frame -->
|
|
|
|
|
|
<Frame x:Name="ContentFrame"
|
|
|
|
|
|
NavigationUIVisibility="Hidden"
|
|
|
|
|
|
ClipToBounds="True" />
|
|
|
|
|
|
|
|
|
|
|
|
</Border>
|
|
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ============================== -->
|
|
|
|
|
|
<!-- ===== 底部状态栏 ===== -->
|
|
|
|
|
|
<!-- ============================== -->
|
|
|
|
|
|
<Grid Grid.Row="2"
|
|
|
|
|
|
Background="{DynamicResource StatusBarBackgroundBrush}">
|
|
|
|
|
|
|
|
|
|
|
|
<Grid.ColumnDefinitions>
|
|
|
|
|
|
<!-- 左侧:版本信息 -->
|
|
|
|
|
|
<ColumnDefinition Width="*" />
|
|
|
|
|
|
<!-- 右侧:主题切换 -->
|
|
|
|
|
|
<ColumnDefinition Width="Auto" />
|
|
|
|
|
|
</Grid.ColumnDefinitions>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- 版本号 -->
|
|
|
|
|
|
<TextBlock Grid.Column="0"
|
|
|
|
|
|
Text="v2.0.0"
|
|
|
|
|
|
FontSize="11"
|
|
|
|
|
|
Foreground="{DynamicResource TextSecondaryBrush}"
|
|
|
|
|
|
VerticalAlignment="Center"
|
|
|
|
|
|
Margin="68,0,0,0" />
|
|
|
|
|
|
|
|
|
|
|
|
<!-- 主题切换按钮 -->
|
|
|
|
|
|
<Button x:Name="BtnThemeToggle"
|
|
|
|
|
|
Grid.Column="1"
|
|
|
|
|
|
Width="32" Height="24"
|
|
|
|
|
|
Margin="0,0,12,0"
|
|
|
|
|
|
Background="Transparent"
|
|
|
|
|
|
Foreground="{DynamicResource TextSecondaryBrush}"
|
|
|
|
|
|
BorderThickness="0"
|
|
|
|
|
|
Cursor="Hand"
|
|
|
|
|
|
Click="BtnThemeToggle_Click"
|
|
|
|
|
|
ToolTip="切换主题">
|
|
|
|
|
|
|
|
|
|
|
|
<!-- 太阳图标(浅色主题时显示) -->
|
|
|
|
|
|
<Path x:Name="ThemeIcon"
|
|
|
|
|
|
Data="M12,7A5,5 0 0,1 17,12A5,5 0 0,1 12,17A5,5 0 0,1 7,12A5,5 0 0,1 12,7M12,9A3,3 0 0,0 9,12A3,3 0 0,0 12,15A3,3 0 0,0 15,12A3,3 0 0,0 12,9M12,2L14.39,5.42C13.73,5.14 13,5 12,5C11,5 10.27,5.14 9.61,5.42L12,2M3.34,7L7.5,6.35C7,7 6.63,7.73 6.43,8.5L3.34,7M3.36,17L6.44,15.5C6.64,16.28 7,17 7.5,17.65L3.36,17M20.64,7L17.55,8.5C17.36,7.72 17,7 16.5,6.35L20.64,7M20.65,17L16.5,17.65C17,17 17.37,16.27 17.57,15.5L20.65,17M12,22L9.61,18.58C10.27,18.86 11,19 12,19C13,19 13.73,18.86 14.39,18.58L12,22Z"
|
|
|
|
|
|
Stretch="Uniform"
|
|
|
|
|
|
Fill="{Binding Path=Foreground, RelativeSource={RelativeSource AncestorType=Button}}"
|
|
|
|
|
|
Width="16" Height="16" />
|
|
|
|
|
|
</Button>
|
|
|
|
|
|
</Grid>
|
|
|
|
|
|
</Grid>
|
|
|
|
|
|
</Border>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ===== 窗口级样式资源 ===== -->
|
|
|
|
|
|
<Window.Resources>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ===== 导航按钮样式 ===== -->
|
|
|
|
|
|
<Style x:Key="NavButtonStyle" TargetType="Button">
|
|
|
|
|
|
<Setter Property="Template">
|
|
|
|
|
|
<Setter.Value>
|
|
|
|
|
|
<ControlTemplate TargetType="Button">
|
|
|
|
|
|
<Grid Background="Transparent">
|
|
|
|
|
|
<!-- 按钮背景(悬停时显示) -->
|
|
|
|
|
|
<Border x:Name="NavButtonBg"
|
|
|
|
|
|
CornerRadius="8"
|
|
|
|
|
|
Background="Transparent"
|
|
|
|
|
|
Margin="-2,0,-2,0" />
|
|
|
|
|
|
|
|
|
|
|
|
<!-- 图标内容 -->
|
|
|
|
|
|
<ContentPresenter HorizontalAlignment="Center"
|
|
|
|
|
|
VerticalAlignment="Center" />
|
|
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
|
|
|
|
<ControlTemplate.Triggers>
|
|
|
|
|
|
<!-- 鼠标悬停动画 -->
|
|
|
|
|
|
<Trigger Property="IsMouseOver" Value="True">
|
|
|
|
|
|
<Trigger.EnterActions>
|
|
|
|
|
|
<BeginStoryboard>
|
|
|
|
|
|
<Storyboard>
|
|
|
|
|
|
<ColorAnimation Storyboard.TargetName="NavButtonBg"
|
|
|
|
|
|
Storyboard.TargetProperty="(Border.Background).(SolidColorBrush.Color)"
|
|
|
|
|
|
To="#2A2A4A"
|
|
|
|
|
|
Duration="0:0:0.200">
|
|
|
|
|
|
<ColorAnimation.EasingFunction>
|
|
|
|
|
|
<CubicEase EasingMode="EaseOut" />
|
|
|
|
|
|
</ColorAnimation.EasingFunction>
|
|
|
|
|
|
</ColorAnimation>
|
|
|
|
|
|
</Storyboard>
|
|
|
|
|
|
</BeginStoryboard>
|
|
|
|
|
|
</Trigger.EnterActions>
|
|
|
|
|
|
<Trigger.ExitActions>
|
|
|
|
|
|
<BeginStoryboard>
|
|
|
|
|
|
<Storyboard>
|
|
|
|
|
|
<ColorAnimation Storyboard.TargetName="NavButtonBg"
|
|
|
|
|
|
Storyboard.TargetProperty="(Border.Background).(SolidColorBrush.Color)"
|
|
|
|
|
|
To="Transparent"
|
|
|
|
|
|
Duration="0:0:0.200">
|
|
|
|
|
|
<ColorAnimation.EasingFunction>
|
|
|
|
|
|
<CubicEase EasingMode="EaseOut" />
|
|
|
|
|
|
</ColorAnimation.EasingFunction>
|
|
|
|
|
|
</ColorAnimation>
|
|
|
|
|
|
</Storyboard>
|
|
|
|
|
|
</BeginStoryboard>
|
|
|
|
|
|
</Trigger.ExitActions>
|
|
|
|
|
|
</Trigger>
|
|
|
|
|
|
</ControlTemplate.Triggers>
|
|
|
|
|
|
</ControlTemplate>
|
|
|
|
|
|
</Setter.Value>
|
|
|
|
|
|
</Setter>
|
|
|
|
|
|
</Style>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ===== 窗口控制按钮样式(最小化/最大化) ===== -->
|
|
|
|
|
|
<Style x:Key="WindowButtonStyle" TargetType="Button">
|
|
|
|
|
|
<Setter Property="Template">
|
|
|
|
|
|
<Setter.Value>
|
|
|
|
|
|
<ControlTemplate TargetType="Button">
|
|
|
|
|
|
<Border x:Name="BtnBg"
|
|
|
|
|
|
Background="Transparent"
|
|
|
|
|
|
CornerRadius="0">
|
|
|
|
|
|
<ContentPresenter HorizontalAlignment="Center"
|
|
|
|
|
|
VerticalAlignment="Center" />
|
|
|
|
|
|
</Border>
|
|
|
|
|
|
|
|
|
|
|
|
<ControlTemplate.Triggers>
|
|
|
|
|
|
<!-- 鼠标悬停 -->
|
|
|
|
|
|
<Trigger Property="IsMouseOver" Value="True">
|
|
|
|
|
|
<Setter TargetName="BtnBg" Property="Background" Value="{DynamicResource WindowButtonHoverBrush}" />
|
|
|
|
|
|
</Trigger>
|
|
|
|
|
|
<!-- 鼠标按下 -->
|
|
|
|
|
|
<Trigger Property="IsPressed" Value="True">
|
|
|
|
|
|
<Setter TargetName="BtnBg" Property="Background" Value="{DynamicResource WindowButtonPressedBrush}" />
|
|
|
|
|
|
</Trigger>
|
|
|
|
|
|
</ControlTemplate.Triggers>
|
|
|
|
|
|
</ControlTemplate>
|
|
|
|
|
|
</Setter.Value>
|
|
|
|
|
|
</Setter>
|
|
|
|
|
|
</Style>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ===== 关闭按钮样式(悬停红色) ===== -->
|
|
|
|
|
|
<Style x:Key="CloseButtonStyle" TargetType="Button">
|
|
|
|
|
|
<Setter Property="Template">
|
|
|
|
|
|
<Setter.Value>
|
|
|
|
|
|
<ControlTemplate TargetType="Button">
|
|
|
|
|
|
<Border x:Name="BtnBg"
|
|
|
|
|
|
Background="Transparent"
|
|
|
|
|
|
CornerRadius="0">
|
|
|
|
|
|
<ContentPresenter x:Name="CloseIcon"
|
|
|
|
|
|
HorizontalAlignment="Center"
|
|
|
|
|
|
VerticalAlignment="Center" />
|
|
|
|
|
|
</Border>
|
|
|
|
|
|
|
|
|
|
|
|
<ControlTemplate.Triggers>
|
|
|
|
|
|
<!-- 鼠标悬停 - 红色背景 -->
|
|
|
|
|
|
<Trigger Property="IsMouseOver" Value="True">
|
|
|
|
|
|
<Setter TargetName="BtnBg" Property="Background" Value="{DynamicResource CloseHoverBrush}" />
|
|
|
|
|
|
<Setter TargetName="CloseIcon" Property="TextBlock.Foreground" Value="White" />
|
|
|
|
|
|
</Trigger>
|
|
|
|
|
|
<!-- 鼠标按下 - 深红色背景 -->
|
|
|
|
|
|
<Trigger Property="IsPressed" Value="True">
|
|
|
|
|
|
<Setter TargetName="BtnBg" Property="Background" Value="{DynamicResource ClosePressedBrush}" />
|
|
|
|
|
|
<Setter TargetName="CloseIcon" Property="TextBlock.Foreground" Value="White" />
|
|
|
|
|
|
</Trigger>
|
|
|
|
|
|
</ControlTemplate.Triggers>
|
|
|
|
|
|
</ControlTemplate>
|
|
|
|
|
|
</Setter.Value>
|
|
|
|
|
|
</Setter>
|
|
|
|
|
|
</Style>
|
|
|
|
|
|
</Window.Resources>
|
|
|
|
|
|
|
|
|
|
|
|
</Window>
|