|
|
|
@ -7,111 +7,264 @@ |
|
|
|
|
xmlns:local="clr-namespace:SparkClient.Views.BaseWindow" |
|
|
|
|
xmlns:baseWindow="clr-namespace:SparkClient.ViewModel.BaseWindow" |
|
|
|
|
mc:Ignorable="d" |
|
|
|
|
Loaded="HomeWindow_OnLoaded" |
|
|
|
|
> |
|
|
|
|
<!-- Height="450" Width="800" --> |
|
|
|
|
<Border.Resources> |
|
|
|
|
<!-- 定义一个缩放变换,用于按钮的放大缩小 --> |
|
|
|
|
<ScaleTransform x:Key="ButtonScaleTransform" ScaleX="1" ScaleY="1" x:Shared="False" /> |
|
|
|
|
|
|
|
|
|
<!-- 鼠标移入的放大动画 --> |
|
|
|
|
<Storyboard x:Key="MouseEnterStoryboard"> |
|
|
|
|
<!-- 放大ScaleX --> |
|
|
|
|
<DoubleAnimation |
|
|
|
|
From="1" To="1.1" |
|
|
|
|
Duration="0:0:0.3" |
|
|
|
|
Storyboard.TargetProperty="(UIElement.RenderTransform).(ScaleTransform.ScaleX)"> |
|
|
|
|
<DoubleAnimation.EasingFunction> |
|
|
|
|
<CubicEase EasingMode="EaseOut"/> |
|
|
|
|
</DoubleAnimation.EasingFunction> |
|
|
|
|
</DoubleAnimation> |
|
|
|
|
<!-- 放大ScaleY --> |
|
|
|
|
<DoubleAnimation |
|
|
|
|
From="1" To="1.1" |
|
|
|
|
Duration="0:0:0.3" |
|
|
|
|
Storyboard.TargetProperty="(UIElement.RenderTransform).(ScaleTransform.ScaleY)"> |
|
|
|
|
<DoubleAnimation.EasingFunction> |
|
|
|
|
<CubicEase EasingMode="EaseOut"/> |
|
|
|
|
</DoubleAnimation.EasingFunction> |
|
|
|
|
</DoubleAnimation> |
|
|
|
|
</Storyboard> |
|
|
|
|
|
|
|
|
|
<!-- 鼠标移出的缩小动画 --> |
|
|
|
|
<Storyboard x:Key="MouseLeaveStoryboard"> |
|
|
|
|
<!-- 缩回ScaleX --> |
|
|
|
|
<DoubleAnimation |
|
|
|
|
From="1.1" To="1" |
|
|
|
|
Duration="0:0:0.3" |
|
|
|
|
Storyboard.TargetProperty="(UIElement.RenderTransform).(ScaleTransform.ScaleX)"> |
|
|
|
|
<DoubleAnimation.EasingFunction> |
|
|
|
|
<CubicEase EasingMode="EaseOut"/> |
|
|
|
|
</DoubleAnimation.EasingFunction> |
|
|
|
|
</DoubleAnimation> |
|
|
|
|
<!-- 缩回ScaleY --> |
|
|
|
|
<DoubleAnimation |
|
|
|
|
From="1.1" To="1" |
|
|
|
|
Duration="0:0:0.3" |
|
|
|
|
Storyboard.TargetProperty="(UIElement.RenderTransform).(ScaleTransform.ScaleY)"> |
|
|
|
|
<DoubleAnimation.EasingFunction> |
|
|
|
|
<CubicEase EasingMode="EaseOut"/> |
|
|
|
|
</DoubleAnimation.EasingFunction> |
|
|
|
|
</DoubleAnimation> |
|
|
|
|
</Storyboard> |
|
|
|
|
</Border.Resources> |
|
|
|
|
<Border.Background> |
|
|
|
|
<ImageBrush ImageSource="pack://application:,,,/Resource/Images/UIResource/01-bg.jpg" Stretch="UniformToFill" /> |
|
|
|
|
</Border.Background> |
|
|
|
|
|
|
|
|
|
<Grid> |
|
|
|
|
<Grid.ColumnDefinitions> |
|
|
|
|
<ColumnDefinition Width="*" /> |
|
|
|
|
<ColumnDefinition Width="*" /> |
|
|
|
|
</Grid.ColumnDefinitions> |
|
|
|
|
<Grid.RowDefinitions> |
|
|
|
|
<RowDefinition Height="50"/> |
|
|
|
|
<RowDefinition /> |
|
|
|
|
</Grid.RowDefinitions> |
|
|
|
|
|
|
|
|
|
<Grid Grid.Row="0" Height="50" VerticalAlignment="Top" MouseLeftButtonDown="UIElement_OnMouseLeftButtonDown"> |
|
|
|
|
<!-- 顶部布局 --> |
|
|
|
|
<Grid.ColumnDefinitions> |
|
|
|
|
<ColumnDefinition Width="Auto" /> |
|
|
|
|
<ColumnDefinition Width="Auto" /> |
|
|
|
|
<ColumnDefinition Width="*" /> |
|
|
|
|
</Grid.ColumnDefinitions> |
|
|
|
|
|
|
|
|
|
<!-- 首位元素:图标 --> |
|
|
|
|
<Image Grid.Column="0" Source="../../Resource/Images/UIResource/03-1-1.png" |
|
|
|
|
Width="30" Height="50" |
|
|
|
|
VerticalAlignment="Center" HorizontalAlignment="Center" Margin="20 0 5 0" /> |
|
|
|
|
|
|
|
|
|
<!-- 次位元素:标题 --> |
|
|
|
|
<TextBlock Grid.Column="1" Text="{DynamicResource ProcName}" |
|
|
|
|
VerticalAlignment="Center" FontWeight="Bold" |
|
|
|
|
HorizontalAlignment="Left" FontSize="20" > |
|
|
|
|
<TextBlock.Foreground> |
|
|
|
|
<LinearGradientBrush StartPoint="1,0" EndPoint="1,1"> |
|
|
|
|
<GradientStop Color="#11ceff" Offset="0" /> |
|
|
|
|
<GradientStop Color="#0a699f" Offset="1" /> |
|
|
|
|
</LinearGradientBrush> |
|
|
|
|
</TextBlock.Foreground> |
|
|
|
|
</TextBlock> |
|
|
|
|
<!-- 末位元素:操作按钮 --> |
|
|
|
|
<Grid Grid.Column="2" Width="260" HorizontalAlignment="Right"> |
|
|
|
|
<Grid.ColumnDefinitions> |
|
|
|
|
<ColumnDefinition Width="*" /> |
|
|
|
|
<ColumnDefinition Width="*" /> |
|
|
|
|
<ColumnDefinition Width="Auto" /> |
|
|
|
|
<ColumnDefinition Width="Auto" /> |
|
|
|
|
</Grid.ColumnDefinitions> |
|
|
|
|
<!-- 最小化 --> |
|
|
|
|
<Button Grid.Column="2" BorderBrush="Transparent" Background="Transparent" |
|
|
|
|
Padding="0" Height="40" BorderThickness="0" FocusVisualStyle="{x:Null}"> |
|
|
|
|
<Border Grid.Column="2" |
|
|
|
|
Width="40" Height="40" |
|
|
|
|
HorizontalAlignment="Center" VerticalAlignment="Center" |
|
|
|
|
Background="Transparent" |
|
|
|
|
MouseEnter="Border_Minimize_MouseEnter" |
|
|
|
|
MouseLeave="Border_MouseLeave" |
|
|
|
|
MouseLeftButtonDown="Minimize_Click"> |
|
|
|
|
<Image Source="../../Resource/Images/UIResource/01-3.png" Height="30"></Image> |
|
|
|
|
</Border> |
|
|
|
|
</Button> |
|
|
|
|
|
|
|
|
|
<!-- 关闭 --> |
|
|
|
|
<Border Grid.Column="3" |
|
|
|
|
Width="40" Height="40" |
|
|
|
|
HorizontalAlignment="Center" VerticalAlignment="Center" |
|
|
|
|
Background="Transparent" |
|
|
|
|
Margin="10 0 " |
|
|
|
|
MouseEnter="Border_Close_MouseEnter" |
|
|
|
|
MouseLeave="Border_MouseLeave" |
|
|
|
|
MouseLeftButtonDown="Close_Click"> |
|
|
|
|
<Image Source="../../Resource/Images/UIResource/01-4.png" Height="30"></Image> |
|
|
|
|
</Border> |
|
|
|
|
</Grid> |
|
|
|
|
</Grid> |
|
|
|
|
|
|
|
|
|
<Grid Row="1"> |
|
|
|
|
<Grid.ColumnDefinitions> |
|
|
|
|
<ColumnDefinition Width="*" /> |
|
|
|
|
<ColumnDefinition Width="*" /> |
|
|
|
|
</Grid.ColumnDefinitions> |
|
|
|
|
|
|
|
|
|
<!-- 左侧占位 --> |
|
|
|
|
<Grid Grid.Column="0"></Grid> |
|
|
|
|
<!-- 左侧占位 --> |
|
|
|
|
<Grid Grid.Column="0"></Grid> |
|
|
|
|
|
|
|
|
|
<!-- 右侧主内容 --> |
|
|
|
|
<Grid Grid.Column="1" VerticalAlignment="Center" Height="800" Width="500"> |
|
|
|
|
<Grid.RowDefinitions> |
|
|
|
|
<!-- 第一排 --> |
|
|
|
|
<RowDefinition Height="8*" /> |
|
|
|
|
<!-- 第二排 --> |
|
|
|
|
<RowDefinition Height="5*" /> |
|
|
|
|
</Grid.RowDefinitions> |
|
|
|
|
<!-- 右侧主内容 --> |
|
|
|
|
<Grid Grid.Column="1" VerticalAlignment="Center"> |
|
|
|
|
<Grid.RowDefinitions> |
|
|
|
|
<!-- 第一排 --> |
|
|
|
|
<RowDefinition Height="8*" /> |
|
|
|
|
<RowDefinition Height="20" /> |
|
|
|
|
<!-- 第二排 --> |
|
|
|
|
<RowDefinition Height="5*" /> |
|
|
|
|
</Grid.RowDefinitions> |
|
|
|
|
|
|
|
|
|
<!-- 第一排按钮 --> |
|
|
|
|
<Button Grid.Row="0" Height="500" |
|
|
|
|
Background="Transparent" BorderBrush="Transparent" Command="{Binding ShowDiamondSelPageCommand}"> |
|
|
|
|
<Border BorderBrush="Transparent" BorderThickness="1" CornerRadius="20" MouseLeave="UIElement_OnMouseLeave" MouseEnter="UIElement_OnMouseEnter"> |
|
|
|
|
<Border.Background> |
|
|
|
|
<RadialGradientBrush GradientOrigin="0.5,0.5" Center="0.5,0.5" RadiusX="0.5" RadiusY="0.5"> |
|
|
|
|
<!-- 内部颜色 --> |
|
|
|
|
<GradientStop Color="#FF4C4D4F" Offset="0.0" /> |
|
|
|
|
<!-- 外部颜色 --> |
|
|
|
|
<GradientStop Color="#FF944703" Offset="2.0" /> |
|
|
|
|
</RadialGradientBrush> |
|
|
|
|
</Border.Background> |
|
|
|
|
<Grid Margin="0 " > |
|
|
|
|
<!-- 第一排按钮 --> |
|
|
|
|
<Button Grid.Row="0" Height="260" Width="500" BorderBrush="Transparent" |
|
|
|
|
Padding="0" FocusVisualStyle="{x:Null}" |
|
|
|
|
RenderTransformOrigin="0.5,0.5" |
|
|
|
|
RenderTransform="{StaticResource ButtonScaleTransform}" |
|
|
|
|
Command="{Binding ShowDiamondSelPageCommand}"> |
|
|
|
|
<Button.Background> |
|
|
|
|
<ImageBrush ImageSource="../../Resource/Images/UIResource/01-5.png"/> |
|
|
|
|
</Button.Background> |
|
|
|
|
<Button.Triggers> |
|
|
|
|
<EventTrigger RoutedEvent="UIElement.MouseEnter"> |
|
|
|
|
<BeginStoryboard Storyboard="{StaticResource MouseEnterStoryboard}" /> |
|
|
|
|
</EventTrigger> |
|
|
|
|
<EventTrigger RoutedEvent="UIElement.MouseLeave"> |
|
|
|
|
<BeginStoryboard Storyboard="{StaticResource MouseLeaveStoryboard}" /> |
|
|
|
|
</EventTrigger> |
|
|
|
|
</Button.Triggers> |
|
|
|
|
|
|
|
|
|
<Grid Width="450"> |
|
|
|
|
<Grid.ColumnDefinitions> |
|
|
|
|
<ColumnDefinition Width="1*"/> |
|
|
|
|
<ColumnDefinition Width="2*"/> |
|
|
|
|
</Grid.ColumnDefinitions> |
|
|
|
|
<Grid.RowDefinitions> |
|
|
|
|
<RowDefinition Height="Auto"/> |
|
|
|
|
<RowDefinition Height="Auto"/> |
|
|
|
|
<RowDefinition Height="4*"/> |
|
|
|
|
<RowDefinition Height="2*"/> |
|
|
|
|
</Grid.RowDefinitions> |
|
|
|
|
<Image Grid.Row="0" Source="pack://application:,,,/Resource/Images/diamtest_3x.png" Height="400" Width="400" Margin="20 0" /> |
|
|
|
|
|
|
|
|
|
<TextBlock Grid.Row="1" Text="{DynamicResource StartTest}" FontSize="36" Margin="10" |
|
|
|
|
TextAlignment="Center" Foreground="Azure"/> |
|
|
|
|
<TextBlock Grid.Column="1" Grid.Row="0" Foreground="Azure" FontWeight="Bold" FontSize="46" |
|
|
|
|
TextAlignment="Center" |
|
|
|
|
Text="{StaticResource StartTest}"/> |
|
|
|
|
<TextBlock Grid.Column="1" Grid.Row="1" Foreground="Azure" FontWeight="Bold" FontSize="26" |
|
|
|
|
TextAlignment="Center" |
|
|
|
|
Text="{StaticResource StartTestFan}"/> |
|
|
|
|
</Grid> |
|
|
|
|
</Border> |
|
|
|
|
</Button> |
|
|
|
|
</Button> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!-- 第二排两个按钮 --> |
|
|
|
|
<Grid Grid.Row="1" Margin="0 10 0 0"> |
|
|
|
|
<Grid.ColumnDefinitions> |
|
|
|
|
<ColumnDefinition Width="*" /> |
|
|
|
|
<ColumnDefinition Width="*" /> |
|
|
|
|
</Grid.ColumnDefinitions> |
|
|
|
|
|
|
|
|
|
<!-- 第二排第一个按钮 --> |
|
|
|
|
<Button Grid.Column="0" Command="{Binding ShowConfigPageCommand}" Background="Transparent" BorderBrush="Transparent" Height="300" > |
|
|
|
|
<Border BorderBrush="Transparent" BorderThickness="1" CornerRadius="20" MouseLeave="UIElement_OnMouseLeave" MouseEnter="UIElement_OnMouseEnter"> |
|
|
|
|
<Border.Background> |
|
|
|
|
<RadialGradientBrush GradientOrigin="0.5,0.5" Center="0.5,0.5" RadiusX="0.5" RadiusY="0.5"> |
|
|
|
|
<!-- 内部颜色 --> |
|
|
|
|
<GradientStop Color="#FF4C4D4F" Offset="0.0" /> |
|
|
|
|
<!-- 外部颜色 --> |
|
|
|
|
<GradientStop Color="#FF944703" Offset="2.0" /> |
|
|
|
|
</RadialGradientBrush> |
|
|
|
|
</Border.Background> |
|
|
|
|
<Grid Margin="0 " > |
|
|
|
|
<!-- 第二排两个按钮 --> |
|
|
|
|
<Grid Grid.Row="2" Width="500"> |
|
|
|
|
<Grid.ColumnDefinitions> |
|
|
|
|
<ColumnDefinition Width="*" /> |
|
|
|
|
<ColumnDefinition Width="20" /> |
|
|
|
|
<ColumnDefinition Width="*" /> |
|
|
|
|
</Grid.ColumnDefinitions> |
|
|
|
|
|
|
|
|
|
<Button Grid.Column="0" Height="150" Width="240" BorderBrush="Transparent" |
|
|
|
|
Padding="0" FocusVisualStyle="{x:Null}" |
|
|
|
|
RenderTransformOrigin="0.5,0.5" |
|
|
|
|
RenderTransform="{StaticResource ButtonScaleTransform}" |
|
|
|
|
Command="{Binding ShowConfigPageCommand}"> |
|
|
|
|
<Button.Background> |
|
|
|
|
<ImageBrush Stretch="Uniform" ImageSource="../../Resource/Images/UIResource/01-6.png"/> |
|
|
|
|
</Button.Background> |
|
|
|
|
<Button.Triggers> |
|
|
|
|
<EventTrigger RoutedEvent="UIElement.MouseEnter"> |
|
|
|
|
<BeginStoryboard Storyboard="{StaticResource MouseEnterStoryboard}" /> |
|
|
|
|
</EventTrigger> |
|
|
|
|
<EventTrigger RoutedEvent="UIElement.MouseLeave"> |
|
|
|
|
<BeginStoryboard Storyboard="{StaticResource MouseLeaveStoryboard}" /> |
|
|
|
|
</EventTrigger> |
|
|
|
|
</Button.Triggers> |
|
|
|
|
|
|
|
|
|
<Grid Width="240"> |
|
|
|
|
<Grid.ColumnDefinitions> |
|
|
|
|
<ColumnDefinition Width="1*"/> |
|
|
|
|
<ColumnDefinition Width="2*"/> |
|
|
|
|
</Grid.ColumnDefinitions> |
|
|
|
|
<Grid.RowDefinitions> |
|
|
|
|
<RowDefinition Height="Auto"/> |
|
|
|
|
<RowDefinition Height="Auto"/> |
|
|
|
|
<RowDefinition Height="4*"/> |
|
|
|
|
<RowDefinition Height="2*"/> |
|
|
|
|
</Grid.RowDefinitions> |
|
|
|
|
<Image Grid.Row="0" Source="pack://application:,,,/Resource/Images/config_3x.png" Height="200" Width="130" Margin="30 0" /> |
|
|
|
|
|
|
|
|
|
<TextBlock Grid.Row="1" Text="{DynamicResource Config}" FontSize="28" Margin="10" |
|
|
|
|
TextAlignment="Center" Foreground="Azure"/> |
|
|
|
|
<TextBlock Grid.Column="1" Grid.Row="0" Foreground="Azure" FontWeight="Bold" FontSize="42" |
|
|
|
|
TextAlignment="Center" |
|
|
|
|
Text="{StaticResource Config}"/> |
|
|
|
|
<TextBlock Grid.Column="1" Grid.Row="1" Foreground="Azure" FontWeight="Bold" FontSize="22" |
|
|
|
|
TextAlignment="Center" |
|
|
|
|
Text="{StaticResource ConfigFan}"/> |
|
|
|
|
</Grid> |
|
|
|
|
</Border> |
|
|
|
|
</Button> |
|
|
|
|
|
|
|
|
|
</Button> |
|
|
|
|
|
|
|
|
|
<Button Grid.Column="1" Command="{Binding ShowHelperPageCommand}" Background="Transparent" BorderBrush="Transparent" Height="300" > |
|
|
|
|
<Border BorderBrush="Transparent" BorderThickness="1" CornerRadius="20" MouseLeave="UIElement_OnMouseLeave" MouseEnter="UIElement_OnMouseEnter"> |
|
|
|
|
<Border.Background> |
|
|
|
|
<RadialGradientBrush GradientOrigin="0.5,0.5" Center="0.5,0.5" RadiusX="0.5" RadiusY="0.5"> |
|
|
|
|
<!-- 内部颜色 --> |
|
|
|
|
<GradientStop Color="#FF4C4D4F" Offset="0.0" /> |
|
|
|
|
<!-- 外部颜色 --> |
|
|
|
|
<GradientStop Color="#FF944703" Offset="2.0" /> |
|
|
|
|
</RadialGradientBrush> |
|
|
|
|
</Border.Background> |
|
|
|
|
<Grid Margin="0 " > |
|
|
|
|
<Button Grid.Column="2" Height="150" Width="240" BorderBrush="Transparent" |
|
|
|
|
Padding="0" FocusVisualStyle="{x:Null}" |
|
|
|
|
RenderTransformOrigin="0.5,0.5" |
|
|
|
|
RenderTransform="{StaticResource ButtonScaleTransform}" |
|
|
|
|
Command="{Binding ShowHelperPageCommand}"> |
|
|
|
|
<Button.Background> |
|
|
|
|
<ImageBrush Stretch="Uniform" ImageSource="../../Resource/Images/UIResource/01-7.png"/> |
|
|
|
|
</Button.Background> |
|
|
|
|
<Button.Triggers> |
|
|
|
|
<EventTrigger RoutedEvent="UIElement.MouseEnter"> |
|
|
|
|
<BeginStoryboard Storyboard="{StaticResource MouseEnterStoryboard}" /> |
|
|
|
|
</EventTrigger> |
|
|
|
|
<EventTrigger RoutedEvent="UIElement.MouseLeave"> |
|
|
|
|
<BeginStoryboard Storyboard="{StaticResource MouseLeaveStoryboard}" /> |
|
|
|
|
</EventTrigger> |
|
|
|
|
</Button.Triggers> |
|
|
|
|
|
|
|
|
|
<Grid Width="240"> |
|
|
|
|
<Grid.ColumnDefinitions> |
|
|
|
|
<ColumnDefinition Width="1*"/> |
|
|
|
|
<ColumnDefinition Width="2*"/> |
|
|
|
|
</Grid.ColumnDefinitions> |
|
|
|
|
<Grid.RowDefinitions> |
|
|
|
|
<RowDefinition Height="Auto"/> |
|
|
|
|
<RowDefinition Height="Auto"/> |
|
|
|
|
<RowDefinition Height="4*"/> |
|
|
|
|
<RowDefinition Height="2*"/> |
|
|
|
|
</Grid.RowDefinitions> |
|
|
|
|
<Image Grid.Row="0" Source="pack://application:,,,/Resource/Images/help_3x.png" Height="200" Width="140" Margin="20 0" /> |
|
|
|
|
|
|
|
|
|
<TextBlock Grid.Row="1" Text="{DynamicResource Help}" FontSize="28" Margin="10" |
|
|
|
|
TextAlignment="Center" Foreground="Azure"/> |
|
|
|
|
<TextBlock Grid.Column="1" Grid.Row="0" Foreground="Azure" FontWeight="Bold" FontSize="42" |
|
|
|
|
TextAlignment="Center" |
|
|
|
|
Text="{StaticResource Help}"/> |
|
|
|
|
<TextBlock Grid.Column="1" Grid.Row="1" Foreground="Azure" FontWeight="Bold" FontSize="22" |
|
|
|
|
TextAlignment="Center" |
|
|
|
|
Text="{StaticResource HelpFan}"/> |
|
|
|
|
</Grid> |
|
|
|
|
</Border> |
|
|
|
|
</Button> |
|
|
|
|
</Button> |
|
|
|
|
</Grid> |
|
|
|
|
</Grid> |
|
|
|
|
</Grid> |
|
|
|
|
|
|
|
|
|
</Grid> |
|
|
|
|
|
|
|
|
|
</Border> |
|
|
|
|