mirror of
https://github.com/chylex/Backup-Essentials.git
synced 2024-09-14 09:42:50 +02:00
857 lines
73 KiB
XML
857 lines
73 KiB
XML
<Application
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:sys="clr-namespace:System;assembly=mscorlib"
|
|
xmlns:ed="http://schemas.microsoft.com/expression/2010/drawing"
|
|
xmlns:Themes="clr-namespace:Microsoft.Windows.Themes;assembly=PresentationFramework.Aero"
|
|
x:Class="BackupEssentials.App"
|
|
Startup="StartApp" DispatcherUnhandledException="HandleException" ShutdownMode="OnMainWindowClose">
|
|
<Application.Resources>
|
|
<ResourceDictionary>
|
|
<sys:String x:Key="PathButtonClose">M7,0 L9,0 9,7 16,7 16,9 9,9 9,16 7,16 7,9 0,9 0,7 7,7 z</sys:String>
|
|
<sys:String x:Key="PathButtonMaximized">M1,2 L1,9 13,9 13,2 z M0,0 L14,0 14,10 0,10 z</sys:String>
|
|
<sys:String x:Key="PathButtonWindowed">M2.5,3.75 L2.5,8.75 10.5,8.75 10.5,3.75 z M1.5,1.75 L11.5,1.75 11.5,9.75 1.5,9.75 z M0,0 L10,0 10,1.25 1,1.25 1,2 1,7 1,8 0,8 z</sys:String>
|
|
<sys:String x:Key="PathButtonMinimize">M0,0 L20,0 L20,3 L0,3 z</sys:String>
|
|
|
|
<sys:Double x:Key="PageWidth">796</sys:Double>
|
|
<sys:Double x:Key="PageHeight">482</sys:Double>
|
|
<sys:Double x:Key="HomePageWidth">636</sys:Double>
|
|
<sys:Double x:Key="HomePageHeight">466</sys:Double>
|
|
<SolidColorBrush x:Key="PageBackground">#FF2E2E2E</SolidColorBrush>
|
|
|
|
<Style x:Key="TextBlockTitle" TargetType="{x:Type TextBlock}">
|
|
<Setter Property="Foreground" Value="#FFDDDDDD"/>
|
|
<Setter Property="FontSize" Value="24"/>
|
|
</Style>
|
|
|
|
<Style x:Key="TextBlockSubTitle" TargetType="{x:Type TextBlock}">
|
|
<Setter Property="Foreground" Value="#FFDDDDDD"/>
|
|
<Setter Property="FontSize" Value="18"/>
|
|
</Style>
|
|
|
|
<Style x:Key="DockPanelStyleTitleBar" TargetType="{x:Type DockPanel}">
|
|
<Setter Property="LastChildFill" Value="False"/>
|
|
<Setter Property="VerticalAlignment" Value="Top"/>
|
|
<Setter Property="Width" Value="Auto"/>
|
|
<Setter Property="Height" Value="36"/>
|
|
<Setter Property="Background">
|
|
<Setter.Value>
|
|
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
|
|
<GradientStop Color="#FF171717" Offset="0"/>
|
|
<GradientStop Color="#FF1D1D1D" Offset="1"/>
|
|
</LinearGradientBrush>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
|
|
<Style x:Key="WrapPanelStyleTitleBar" TargetType="{x:Type WrapPanel}">
|
|
<Setter Property="Height" Value="36"/>
|
|
<Setter Property="Orientation" Value="Horizontal"/>
|
|
<Setter Property="VerticalAlignment" Value="Top"/>
|
|
<Setter Property="HorizontalAlignment" Value="Right"/>
|
|
<Setter Property="FlowDirection" Value="RightToLeft"/>
|
|
</Style>
|
|
|
|
<Style x:Key="ButtonStyleTitleBar" TargetType="{x:Type Button}">
|
|
<Setter Property="HorizontalContentAlignment" Value="Center"/>
|
|
<Setter Property="VerticalContentAlignment" Value="Center"/>
|
|
<Setter Property="Width" Value="36"/>
|
|
<Setter Property="Height" Value="36"/>
|
|
<Setter Property="Padding" Value="3"/>
|
|
<Setter Property="RenderOptions.EdgeMode" Value="Aliased"/>
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type Button}">
|
|
<Grid HorizontalAlignment="Left" Height="36" VerticalAlignment="Top" Width="36">
|
|
<VisualStateManager.VisualStateGroups>
|
|
<VisualStateGroup x:Name="CommonStates">
|
|
<VisualStateGroup.Transitions>
|
|
<VisualTransition GeneratedDuration="0:0:0.1" To="MouseOver">
|
|
<Storyboard>
|
|
<PointAnimation Duration="0:0:0.12" To="36,0" Storyboard.TargetProperty="(UIElement.Clip).(PathGeometry.Figures)[0].(PathFigure.Segments)[1].(LineSegment.Point)" Storyboard.TargetName="GridHover"/>
|
|
<PointAnimation Duration="0:0:0.12" To="0,36" Storyboard.TargetProperty="(UIElement.Clip).(PathGeometry.Figures)[0].(PathFigure.StartPoint)" Storyboard.TargetName="GridHover"/>
|
|
<PointAnimation Duration="0:0:0.12" To="36,36" Storyboard.TargetProperty="(UIElement.Clip).(PathGeometry.Figures)[0].(PathFigure.Segments)[0].(LineSegment.Point)" Storyboard.TargetName="GridHover"/>
|
|
<PointAnimation Duration="0:0:0.12" To="0,0" Storyboard.TargetProperty="(UIElement.Clip).(PathGeometry.Figures)[0].(PathFigure.Segments)[2].(LineSegment.Point)" Storyboard.TargetName="GridHover"/>
|
|
</Storyboard>
|
|
</VisualTransition>
|
|
</VisualStateGroup.Transitions>
|
|
<VisualState x:Name="Normal"/>
|
|
<VisualState x:Name="MouseOver">
|
|
<Storyboard>
|
|
<PointAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Clip).(PathGeometry.Figures)[0].(PathFigure.StartPoint)" Storyboard.TargetName="GridHover">
|
|
<EasingPointKeyFrame KeyTime="0" Value="0,36"/>
|
|
</PointAnimationUsingKeyFrames>
|
|
<PointAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Clip).(PathGeometry.Figures)[0].(PathFigure.Segments)[0].(LineSegment.Point)" Storyboard.TargetName="GridHover">
|
|
<EasingPointKeyFrame KeyTime="0" Value="36,36"/>
|
|
</PointAnimationUsingKeyFrames>
|
|
<PointAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Clip).(PathGeometry.Figures)[0].(PathFigure.Segments)[1].(LineSegment.Point)" Storyboard.TargetName="GridHover">
|
|
<EasingPointKeyFrame KeyTime="0" Value="36,0"/>
|
|
</PointAnimationUsingKeyFrames>
|
|
<PointAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Clip).(PathGeometry.Figures)[0].(PathFigure.Segments)[2].(LineSegment.Point)" Storyboard.TargetName="GridHover">
|
|
<EasingPointKeyFrame KeyTime="0" Value="0,0"/>
|
|
</PointAnimationUsingKeyFrames>
|
|
</Storyboard>
|
|
</VisualState>
|
|
<VisualState x:Name="Pressed"/>
|
|
<VisualState x:Name="Disabled"/>
|
|
</VisualStateGroup>
|
|
</VisualStateManager.VisualStateGroups>
|
|
<Rectangle x:Name="CollisionBackground" Fill="#FFFFFFFF" HorizontalAlignment="Stretch" Height="36" VerticalAlignment="Stretch" Width="36" Visibility="Visible" Opacity="0"/>
|
|
<Grid x:Name="GridDefault">
|
|
<Rectangle x:Name="ButtonBackground" Fill="#FFC3C3C3" HorizontalAlignment="Stretch" Height="0" VerticalAlignment="Bottom" Width="36" Visibility="Visible" StrokeThickness="0"/>
|
|
<Path x:Name="ButtonForeground" Fill="#FFC3C3C3" HorizontalAlignment="Center" VerticalAlignment="Center" Width="{Binding CXPathWidth, RelativeSource={RelativeSource TemplatedParent}}" Height="{Binding CXPathHeight, RelativeSource={RelativeSource TemplatedParent}}" Margin="{Binding CXPathMargin, RelativeSource={RelativeSource TemplatedParent}}" StrokeThickness="0" Data="{Binding CXPathData, RelativeSource={RelativeSource TemplatedParent}}" RenderTransformOrigin="0.5,0.5" Stretch="Fill">
|
|
<Path.RenderTransform>
|
|
<TransformGroup>
|
|
<RotateTransform Angle="{Binding CXPathRotation, RelativeSource={RelativeSource TemplatedParent}}"/>
|
|
</TransformGroup>
|
|
</Path.RenderTransform>
|
|
</Path>
|
|
</Grid>
|
|
<Grid x:Name="GridHover">
|
|
<Grid.Clip>
|
|
<PathGeometry>
|
|
<PathFigure IsClosed="True" StartPoint="0,36">
|
|
<LineSegment Point="36,36"/>
|
|
<LineSegment Point="36,36"/>
|
|
<LineSegment Point="0,36"/>
|
|
</PathFigure>
|
|
</PathGeometry>
|
|
</Grid.Clip>
|
|
<Rectangle x:Name="ButtonBackgroundHover" HorizontalAlignment="Stretch" Height="36" VerticalAlignment="Bottom" Width="36" Visibility="Visible" StrokeThickness="0">
|
|
<Rectangle.Fill>
|
|
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
|
|
<GradientStop Color="#FF2C2C2C" Offset="0"/>
|
|
<GradientStop Color="#FF252525" Offset="1"/>
|
|
</LinearGradientBrush>
|
|
</Rectangle.Fill>
|
|
</Rectangle>
|
|
<Path x:Name="ButtonForegroundHover" Fill="#FF38B6FD" HorizontalAlignment="Center" VerticalAlignment="Center" Width="{Binding CXPathWidth, RelativeSource={RelativeSource TemplatedParent}}" Height="{Binding CXPathHeight, RelativeSource={RelativeSource TemplatedParent}}" Margin="{Binding CXPathMargin, RelativeSource={RelativeSource TemplatedParent}}" StrokeThickness="0" Data="{Binding CXPathData, RelativeSource={RelativeSource TemplatedParent}}" RenderTransformOrigin="0.5,0.5" Stretch="Fill" Stroke="{x:Null}">
|
|
<Path.RenderTransform>
|
|
<TransformGroup>
|
|
<RotateTransform Angle="{Binding CXPathRotation, RelativeSource={RelativeSource TemplatedParent}}"/>
|
|
</TransformGroup>
|
|
</Path.RenderTransform>
|
|
</Path>
|
|
</Grid>
|
|
</Grid>
|
|
<ControlTemplate.Triggers/>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
|
|
<Storyboard x:Key="StoryboardButtonDisabled">
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(TextElement.Foreground).(SolidColorBrush.Color)" Storyboard.TargetName="label">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF7A7A7A"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.OpacityMask)" Storyboard.TargetName="border">
|
|
<DiscreteObjectKeyFrame KeyTime="0" Value="{x:Null}"/>
|
|
</ObjectAnimationUsingKeyFrames>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(GradientBrush.GradientStops)[1].(GradientStop.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#B23E3E3E"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(GradientBrush.GradientStops)[0].(GradientStop.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#B2494949"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Border.BorderBrush).(GradientBrush.GradientStops)[1].(GradientStop.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#B2212121"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Border.BorderBrush).(GradientBrush.GradientStops)[0].(GradientStop.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#B2292929"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
</Storyboard>
|
|
|
|
<ControlTemplate x:Key="ButtonStyleDefault" TargetType="{x:Type ButtonBase}">
|
|
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch" SnapsToDevicePixels="True">
|
|
<VisualStateManager.VisualStateGroups>
|
|
<VisualStateGroup x:Name="CommonStates">
|
|
<VisualStateGroup.Transitions>
|
|
<VisualTransition From="Disabled" GeneratedDuration="0:0:0.1" To="Normal">
|
|
<Storyboard/>
|
|
</VisualTransition>
|
|
<VisualTransition From="Normal" GeneratedDuration="0:0:0.05" To="MouseOver"/>
|
|
<VisualTransition From="MouseOver" GeneratedDuration="0:0:0.03" To="Pressed"/>
|
|
<VisualTransition From="MouseOver" GeneratedDuration="0:0:0.15" To="Normal"/>
|
|
<VisualTransition From="Pressed" GeneratedDuration="0:0:0.3" To="MouseOver"/>
|
|
</VisualStateGroup.Transitions>
|
|
<VisualState x:Name="Normal">
|
|
<Storyboard>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(TextElement.Foreground).(SolidColorBrush.Color)" Storyboard.TargetName="label">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FFE0E0E0"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(GradientBrush.GradientStops)[1].(GradientStop.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF303638"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
</Storyboard>
|
|
</VisualState>
|
|
<VisualState x:Name="MouseOver">
|
|
<Storyboard>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(GradientBrush.GradientStops)[0].(GradientStop.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF4F5355"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(GradientBrush.GradientStops)[1].(GradientStop.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF356276"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
</Storyboard>
|
|
</VisualState>
|
|
<VisualState x:Name="Pressed">
|
|
<Storyboard>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(GradientBrush.GradientStops)[1].(GradientStop.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF1D6C8F"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(GradientBrush.GradientStops)[0].(GradientStop.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF4E5961"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Border.BorderBrush).(GradientBrush.GradientStops)[0].(GradientStop.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF292929"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Border.BorderBrush).(GradientBrush.GradientStops)[1].(GradientStop.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF212121"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
</Storyboard>
|
|
</VisualState>
|
|
<VisualState x:Name="Disabled" Storyboard="{StaticResource StoryboardButtonDisabled}"/>
|
|
</VisualStateGroup>
|
|
</VisualStateManager.VisualStateGroups>
|
|
|
|
<Border x:Name="border" BorderThickness="2" HorizontalAlignment="Stretch" Height="Auto" VerticalAlignment="Stretch" Width="Auto">
|
|
<Border.BorderBrush>
|
|
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
|
|
<GradientStop Color="#FF292929" Offset="0"/>
|
|
<GradientStop Color="#FF212121" Offset="1"/>
|
|
</LinearGradientBrush>
|
|
</Border.BorderBrush>
|
|
<Border.Background>
|
|
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
|
|
<GradientStop Color="#FF494949" Offset="0"/>
|
|
<GradientStop Color="#FF3E3E3E" Offset="1"/>
|
|
</LinearGradientBrush>
|
|
</Border.Background>
|
|
<Label x:Name="label" Foreground="#FFDDDDDD" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="{TemplateBinding FontSize}" TextOptions.TextRenderingMode="ClearType">
|
|
<ContentPresenter ContentTemplate="{TemplateBinding ContentTemplate}" Content="{TemplateBinding Content}" ContentStringFormat="{TemplateBinding ContentStringFormat}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" Margin="10,0" RecognizesAccessKey="True" SnapsToDevicePixels="True"/>
|
|
</Label>
|
|
</Border>
|
|
</Grid>
|
|
</ControlTemplate>
|
|
|
|
<ControlTemplate x:Key="ButtonStyleRedDefault" TargetType="{x:Type ButtonBase}">
|
|
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch" SnapsToDevicePixels="True">
|
|
<VisualStateManager.VisualStateGroups>
|
|
<VisualStateGroup x:Name="CommonStates">
|
|
<VisualStateGroup.Transitions>
|
|
<VisualTransition From="Disabled" GeneratedDuration="0:0:0.1" To="Normal">
|
|
<Storyboard/>
|
|
</VisualTransition>
|
|
<VisualTransition From="Normal" GeneratedDuration="0:0:0.05" To="MouseOver"/>
|
|
<VisualTransition From="MouseOver" GeneratedDuration="0:0:0.03" To="Pressed"/>
|
|
<VisualTransition From="MouseOver" GeneratedDuration="0:0:0.15" To="Normal"/>
|
|
<VisualTransition From="Pressed" GeneratedDuration="0:0:0.3" To="MouseOver"/>
|
|
</VisualStateGroup.Transitions>
|
|
<VisualState x:Name="Normal">
|
|
<Storyboard>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(TextElement.Foreground).(SolidColorBrush.Color)" Storyboard.TargetName="label">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FFE0E0E0"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(GradientBrush.GradientStops)[1].(GradientStop.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF383030"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
</Storyboard>
|
|
</VisualState>
|
|
<VisualState x:Name="MouseOver">
|
|
<Storyboard>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(GradientBrush.GradientStops)[0].(GradientStop.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF554F4F"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(GradientBrush.GradientStops)[1].(GradientStop.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF763535"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
</Storyboard>
|
|
</VisualState>
|
|
<VisualState x:Name="Pressed">
|
|
<Storyboard>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(GradientBrush.GradientStops)[1].(GradientStop.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF8F1D1D"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(GradientBrush.GradientStops)[0].(GradientStop.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF614E4E"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Border.BorderBrush).(GradientBrush.GradientStops)[0].(GradientStop.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF292929"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Border.BorderBrush).(GradientBrush.GradientStops)[1].(GradientStop.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF212121"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
</Storyboard>
|
|
</VisualState>
|
|
<VisualState x:Name="Disabled" Storyboard="{StaticResource StoryboardButtonDisabled}"/>
|
|
</VisualStateGroup>
|
|
</VisualStateManager.VisualStateGroups>
|
|
|
|
<Border x:Name="border" BorderThickness="2" HorizontalAlignment="Stretch" Height="Auto" VerticalAlignment="Stretch" Width="Auto">
|
|
<Border.BorderBrush>
|
|
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
|
|
<GradientStop Color="#FF292929" Offset="0"/>
|
|
<GradientStop Color="#FF212121" Offset="1"/>
|
|
</LinearGradientBrush>
|
|
</Border.BorderBrush>
|
|
<Border.Background>
|
|
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
|
|
<GradientStop Color="#FF494949" Offset="0"/>
|
|
<GradientStop Color="#FF3E3E3E" Offset="1"/>
|
|
</LinearGradientBrush>
|
|
</Border.Background>
|
|
<Label x:Name="label" Foreground="#FFDDDDDD" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="{TemplateBinding FontSize}" TextOptions.TextRenderingMode="ClearType">
|
|
<ContentPresenter ContentTemplate="{TemplateBinding ContentTemplate}" Content="{TemplateBinding Content}" ContentStringFormat="{TemplateBinding ContentStringFormat}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" Margin="10,0" RecognizesAccessKey="True" SnapsToDevicePixels="True"/>
|
|
</Label>
|
|
</Border>
|
|
</Grid>
|
|
</ControlTemplate>
|
|
|
|
<Style x:Key="ListViewStyleDefault" TargetType="ListView">
|
|
<Setter Property="Margin" Value="8"/>
|
|
<Setter Property="BorderThickness" Value="2"/>
|
|
<Setter Property="BorderBrush" Value="#FF252525"/>
|
|
<Setter Property="Background" Value="#FF444444"/>
|
|
</Style>
|
|
|
|
<Storyboard x:Key="ListViewItemStoryboardMouseOver">
|
|
<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background)" Storyboard.TargetName="border">
|
|
<DiscreteObjectKeyFrame KeyTime="0">
|
|
<DiscreteObjectKeyFrame.Value>
|
|
<SolidColorBrush Color="#15FFFFFF"/>
|
|
</DiscreteObjectKeyFrame.Value>
|
|
</DiscreteObjectKeyFrame>
|
|
</ObjectAnimationUsingKeyFrames>
|
|
</Storyboard>
|
|
|
|
<Storyboard x:Key="ListViewItemStoryboardSelected">
|
|
<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background)" Storyboard.TargetName="border">
|
|
<DiscreteObjectKeyFrame KeyTime="0">
|
|
<DiscreteObjectKeyFrame.Value>
|
|
<SolidColorBrush Color="#FF1b7aa5"/>
|
|
</DiscreteObjectKeyFrame.Value>
|
|
</DiscreteObjectKeyFrame>
|
|
</ObjectAnimationUsingKeyFrames>
|
|
</Storyboard>
|
|
|
|
<LinearGradientBrush x:Key="TextBoxBorder" EndPoint="0,20" MappingMode="Absolute" StartPoint="0,0">
|
|
<GradientStop Color="#ABADB3" Offset="0.05"/>
|
|
<GradientStop Color="#E2E3EA" Offset="0.07"/>
|
|
<GradientStop Color="#E3E9EF" Offset="1"/>
|
|
</LinearGradientBrush>
|
|
|
|
<Style x:Key="TextBoxStyleDefault" BasedOn="{x:Null}" TargetType="{x:Type TextBox}">
|
|
<Setter Property="Foreground" Value="#FFC5C5C5"/>
|
|
<Setter Property="Background" Value="{x:Null}"/>
|
|
<Setter Property="BorderBrush" Value="{x:Null}"/>
|
|
<Setter Property="CaretBrush" Value="#FFEEEEEE"/>
|
|
<Setter Property="BorderThickness" Value="2"/>
|
|
<Setter Property="FontSize" Value="16"/>
|
|
<Setter Property="VerticalContentAlignment" Value="Center"/>
|
|
<Setter Property="Padding" Value="2"/>
|
|
<Setter Property="AllowDrop" Value="true"/>
|
|
<Setter Property="FocusVisualStyle" Value="{x:Null}"/>
|
|
<Setter Property="ScrollViewer.PanningMode" Value="VerticalFirst"/>
|
|
<Setter Property="Stylus.IsFlicksEnabled" Value="False"/>
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type TextBox}">
|
|
<Themes:ListBoxChrome x:Name="Bd" BorderThickness="{TemplateBinding BorderThickness}" RenderMouseOver="{TemplateBinding IsMouseOver}" RenderFocused="{TemplateBinding IsKeyboardFocusWithin}" SnapsToDevicePixels="true">
|
|
<VisualStateManager.VisualStateGroups>
|
|
<VisualStateGroup x:Name="TextBoxStates">
|
|
<VisualStateGroup.Transitions>
|
|
<VisualTransition From="Unfocused" GeneratedDuration="0:0:0.1" To="Focused"/>
|
|
<VisualTransition From="Focused" GeneratedDuration="0:0:0.1" To="Unfocused"/>
|
|
<VisualTransition From="Invalid" GeneratedDuration="0:0:0.1" To="*"/>
|
|
</VisualStateGroup.Transitions>
|
|
<VisualState x:Name="Unfocused"/>
|
|
<VisualState x:Name="Focused">
|
|
<Storyboard>
|
|
<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(Border.Background).(GradientBrush.GradientStops)[0].(GradientStop.Offset)" Storyboard.TargetName="Bd">
|
|
<EasingDoubleKeyFrame KeyTime="0" Value="0"/>
|
|
</DoubleAnimationUsingKeyFrames>
|
|
<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(Border.Background).(GradientBrush.GradientStops)[1].(GradientStop.Offset)" Storyboard.TargetName="Bd">
|
|
<EasingDoubleKeyFrame KeyTime="0" Value="1"/>
|
|
</DoubleAnimationUsingKeyFrames>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Border.Background).(GradientBrush.GradientStops)[0].(GradientStop.Color)" Storyboard.TargetName="Bd">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF383838"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Border.Background).(GradientBrush.GradientStops)[1].(GradientStop.Color)" Storyboard.TargetName="Bd">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF294D5C"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
</Storyboard>
|
|
</VisualState>
|
|
<VisualState x:Name="Invalid">
|
|
<Storyboard>
|
|
<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(Border.Background).(GradientBrush.GradientStops)[0].(GradientStop.Offset)" Storyboard.TargetName="Bd">
|
|
<EasingDoubleKeyFrame KeyTime="0" Value="0"/>
|
|
</DoubleAnimationUsingKeyFrames>
|
|
<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(Border.Background).(GradientBrush.GradientStops)[1].(GradientStop.Offset)" Storyboard.TargetName="Bd">
|
|
<EasingDoubleKeyFrame KeyTime="0" Value="1"/>
|
|
</DoubleAnimationUsingKeyFrames>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Border.Background).(GradientBrush.GradientStops)[0].(GradientStop.Color)" Storyboard.TargetName="Bd">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF383838"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Border.Background).(GradientBrush.GradientStops)[1].(GradientStop.Color)" Storyboard.TargetName="Bd">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF5C2929"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
</Storyboard>
|
|
</VisualState>
|
|
</VisualStateGroup>
|
|
</VisualStateManager.VisualStateGroups>
|
|
<Themes:ListBoxChrome.BorderBrush>
|
|
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
|
|
<GradientStop Color="#FF292929" Offset="0"/>
|
|
<GradientStop Color="#FF212121" Offset="1"/>
|
|
</LinearGradientBrush>
|
|
</Themes:ListBoxChrome.BorderBrush>
|
|
<Themes:ListBoxChrome.Background>
|
|
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
|
|
<GradientStop Color="#FF383838" Offset="0"/>
|
|
<GradientStop Color="#FF383838" Offset="1"/>
|
|
</LinearGradientBrush>
|
|
</Themes:ListBoxChrome.Background>
|
|
<ScrollViewer x:Name="PART_ContentHost" Margin="{TemplateBinding Padding}" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
|
|
</Themes:ListBoxChrome>
|
|
<ControlTemplate.Triggers>
|
|
<Trigger Property="IsEnabled" Value="false">
|
|
<Setter Property="Foreground" Value="#FF959595"/>
|
|
</Trigger>
|
|
</ControlTemplate.Triggers>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
|
|
<Style TargetType="ScrollViewer">
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type ScrollViewer}">
|
|
<Grid x:Name="Grid" Background="{TemplateBinding Background}">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="*"/>
|
|
<ColumnDefinition Width="Auto"/>
|
|
</Grid.ColumnDefinitions>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="*"/>
|
|
<RowDefinition Height="Auto"/>
|
|
</Grid.RowDefinitions>
|
|
<Grid.Resources>
|
|
<RadialGradientBrush x:Key="ScrollBarButtonFill">
|
|
<GradientStop Color="#FF666666" Offset="1"/>
|
|
<GradientStop Color="#FF898989"/>
|
|
</RadialGradientBrush>
|
|
<SolidColorBrush x:Key="VerticalScrollBarBackground" Color="#5D5D5D"/>
|
|
<SolidColorBrush x:Key="HorizontalScrollBarBackground" Color="#5D5D5D"/>
|
|
<SolidColorBrush x:Key="ScrollBarDisabledBackground" Color="#5D5D5D"/>
|
|
<Storyboard x:Key="SBStoryboardMouseOver">
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(SolidColorBrush.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF2E2E2E"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
</Storyboard>
|
|
<Storyboard x:Key="SBStoryboardPressed">
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(SolidColorBrush.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF252525"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
</Storyboard>
|
|
<Style x:Key="ScrollBarButtonUP" TargetType="{x:Type RepeatButton}">
|
|
<Setter Property="OverridesDefaultStyle" Value="true"/>
|
|
<Setter Property="Focusable" Value="false"/>
|
|
<Setter Property="IsTabStop" Value="false"/>
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type RepeatButton}">
|
|
<Border x:Name="border" BorderBrush="#FF5D5D5D" BorderThickness="1" HorizontalAlignment="Left" Height="17" VerticalAlignment="Top" Width="17" Background="#FF191919">
|
|
<VisualStateManager.VisualStateGroups>
|
|
<VisualStateGroup x:Name="CommonStates">
|
|
<VisualStateGroup.Transitions>
|
|
<VisualTransition GeneratedDuration="0:0:0.05"/>
|
|
</VisualStateGroup.Transitions>
|
|
<VisualState x:Name="Normal"/>
|
|
<VisualState x:Name="MouseOver" Storyboard="{StaticResource SBStoryboardMouseOver}"/>
|
|
<VisualState x:Name="Pressed" Storyboard="{StaticResource SBStoryboardPressed}"/>
|
|
<VisualState x:Name="Disabled"/>
|
|
</VisualStateGroup>
|
|
</VisualStateManager.VisualStateGroups>
|
|
<ed:BlockArrow Orientation="Up" Fill="{StaticResource ScrollBarButtonFill}" Width="7" Height="5" Margin="0" ArrowBodySize="0" ArrowheadAngle="0" StrokeThickness="0"/>
|
|
</Border>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
<Style x:Key="ScrollBarButtonDOWN" TargetType="{x:Type RepeatButton}">
|
|
<Setter Property="OverridesDefaultStyle" Value="true"/>
|
|
<Setter Property="Focusable" Value="false"/>
|
|
<Setter Property="IsTabStop" Value="false"/>
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type RepeatButton}">
|
|
<Border x:Name="border" BorderBrush="#FF5D5D5D" BorderThickness="1" HorizontalAlignment="Left" Height="17" VerticalAlignment="Top" Width="17" Background="#FF191919">
|
|
<VisualStateManager.VisualStateGroups>
|
|
<VisualStateGroup x:Name="CommonStates">
|
|
<VisualStateGroup.Transitions>
|
|
<VisualTransition GeneratedDuration="0:0:0.05"/>
|
|
</VisualStateGroup.Transitions>
|
|
<VisualState x:Name="Normal"/>
|
|
<VisualState x:Name="MouseOver" Storyboard="{StaticResource SBStoryboardMouseOver}"/>
|
|
<VisualState x:Name="Pressed" Storyboard="{StaticResource SBStoryboardPressed}"/>
|
|
<VisualState x:Name="Disabled"/>
|
|
</VisualStateGroup>
|
|
</VisualStateManager.VisualStateGroups>
|
|
<ed:BlockArrow Orientation="Down" Fill="{StaticResource ScrollBarButtonFill}" Width="7" Height="5" Margin="0,1,0,0" ArrowBodySize="0" ArrowheadAngle="0" StrokeThickness="0"/>
|
|
</Border>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
<Style x:Key="ScrollBarButtonLEFT" TargetType="{x:Type RepeatButton}">
|
|
<Setter Property="OverridesDefaultStyle" Value="true"/>
|
|
<Setter Property="Focusable" Value="false"/>
|
|
<Setter Property="IsTabStop" Value="false"/>
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type RepeatButton}">
|
|
<Border x:Name="border" BorderBrush="#FF5D5D5D" BorderThickness="1" HorizontalAlignment="Left" Height="17" VerticalAlignment="Top" Width="17" Background="#FF191919">
|
|
<VisualStateManager.VisualStateGroups>
|
|
<VisualStateGroup x:Name="CommonStates">
|
|
<VisualStateGroup.Transitions>
|
|
<VisualTransition GeneratedDuration="0:0:0.05"/>
|
|
</VisualStateGroup.Transitions>
|
|
<VisualState x:Name="Normal"/>
|
|
<VisualState x:Name="MouseOver" Storyboard="{StaticResource SBStoryboardMouseOver}"/>
|
|
<VisualState x:Name="Pressed" Storyboard="{StaticResource SBStoryboardPressed}"/>
|
|
<VisualState x:Name="Disabled"/>
|
|
</VisualStateGroup>
|
|
</VisualStateManager.VisualStateGroups>
|
|
<ed:BlockArrow Orientation="Left" Fill="{StaticResource ScrollBarButtonFill}" Width="5" Height="7" Margin="0,0,1,0" ArrowBodySize="0" ArrowheadAngle="0" StrokeThickness="0"/>
|
|
</Border>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
<Style x:Key="ScrollBarButtonRIGHT" TargetType="{x:Type RepeatButton}">
|
|
<Setter Property="OverridesDefaultStyle" Value="true"/>
|
|
<Setter Property="Focusable" Value="false"/>
|
|
<Setter Property="IsTabStop" Value="false"/>
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type RepeatButton}">
|
|
<Border x:Name="border" BorderBrush="#FF5D5D5D" BorderThickness="1" HorizontalAlignment="Left" Height="17" VerticalAlignment="Top" Width="17" Background="#FF191919">
|
|
<VisualStateManager.VisualStateGroups>
|
|
<VisualStateGroup x:Name="CommonStates">
|
|
<VisualStateGroup.Transitions>
|
|
<VisualTransition GeneratedDuration="0:0:0.05"/>
|
|
</VisualStateGroup.Transitions>
|
|
<VisualState x:Name="Normal"/>
|
|
<VisualState x:Name="MouseOver" Storyboard="{StaticResource SBStoryboardMouseOver}"/>
|
|
<VisualState x:Name="Pressed" Storyboard="{StaticResource SBStoryboardPressed}"/>
|
|
<VisualState x:Name="Disabled"/>
|
|
</VisualStateGroup>
|
|
</VisualStateManager.VisualStateGroups>
|
|
<ed:BlockArrow Orientation="Right" Fill="{StaticResource ScrollBarButtonFill}" Width="5" Height="7" Margin="0" ArrowBodySize="0" ArrowheadAngle="0" StrokeThickness="0"/>
|
|
</Border>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
<Style x:Key="VerticalScrollBarPageButton" TargetType="{x:Type RepeatButton}">
|
|
<Setter Property="OverridesDefaultStyle" Value="true"/>
|
|
<Setter Property="Background" Value="Transparent"/>
|
|
<Setter Property="Focusable" Value="false"/>
|
|
<Setter Property="IsTabStop" Value="false"/>
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type RepeatButton}">
|
|
<Rectangle Fill="{TemplateBinding Background}" Height="{TemplateBinding Height}" Width="{TemplateBinding Width}"/>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
<Storyboard x:Key="SBStoryboardThumbMouseOver">
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(SolidColorBrush.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF2E2E2E"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
</Storyboard>
|
|
<Storyboard x:Key="SBStoryboardThumbPressed">
|
|
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(SolidColorBrush.Color)" Storyboard.TargetName="border">
|
|
<EasingColorKeyFrame KeyTime="0" Value="#FF252525"/>
|
|
</ColorAnimationUsingKeyFrames>
|
|
</Storyboard>
|
|
<Style x:Key="ScrollBarThumbVertical" TargetType="{x:Type Thumb}">
|
|
<Setter Property="OverridesDefaultStyle" Value="true"/>
|
|
<Setter Property="IsTabStop" Value="false"/>
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type Thumb}">
|
|
<Border x:Name="border" BorderBrush="#FF5D5D5D" BorderThickness="1,0" HorizontalAlignment="Left" VerticalAlignment="Stretch" Width="17" Height="Auto" Background="#FF191919">
|
|
<VisualStateManager.VisualStateGroups>
|
|
<VisualStateGroup x:Name="CommonStates">
|
|
<VisualStateGroup.Transitions>
|
|
<VisualTransition GeneratedDuration="0:0:0.05"/>
|
|
</VisualStateGroup.Transitions>
|
|
<VisualState x:Name="Normal"/>
|
|
<VisualState x:Name="MouseOver" Storyboard="{StaticResource SBStoryboardThumbMouseOver}"/>
|
|
<VisualState x:Name="Pressed" Storyboard="{StaticResource SBStoryboardThumbPressed}"/>
|
|
<VisualState x:Name="Disabled"/>
|
|
</VisualStateGroup>
|
|
</VisualStateManager.VisualStateGroups>
|
|
</Border>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
<Style x:Key="ScrollBarThumbHorizontal" TargetType="{x:Type Thumb}">
|
|
<Setter Property="OverridesDefaultStyle" Value="true"/>
|
|
<Setter Property="IsTabStop" Value="false"/>
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type Thumb}">
|
|
<Border x:Name="border" BorderBrush="#FF5D5D5D" BorderThickness="0,1" HorizontalAlignment="Stretch" VerticalAlignment="Top" Width="Auto" Height="17" Background="#FF191919" Margin="0,0,-16,0">
|
|
<VisualStateManager.VisualStateGroups>
|
|
<VisualStateGroup x:Name="CommonStates">
|
|
<VisualStateGroup.Transitions>
|
|
<VisualTransition GeneratedDuration="0:0:0.05"/>
|
|
</VisualStateGroup.Transitions>
|
|
<VisualState x:Name="Normal"/>
|
|
<VisualState x:Name="MouseOver" Storyboard="{StaticResource SBStoryboardThumbMouseOver}"/>
|
|
<VisualState x:Name="Pressed" Storyboard="{StaticResource SBStoryboardThumbPressed}"/>
|
|
<VisualState x:Name="Disabled"/>
|
|
</VisualStateGroup>
|
|
</VisualStateManager.VisualStateGroups>
|
|
</Border>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
<Style x:Key="HorizontalScrollBarPageButton" TargetType="{x:Type RepeatButton}">
|
|
<Setter Property="OverridesDefaultStyle" Value="true"/>
|
|
<Setter Property="Background" Value="Transparent"/>
|
|
<Setter Property="Focusable" Value="false"/>
|
|
<Setter Property="IsTabStop" Value="false"/>
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type RepeatButton}">
|
|
<Rectangle Fill="{TemplateBinding Background}" Height="{TemplateBinding Height}" Width="{TemplateBinding Width}"/>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
<Style x:Key="ScrollBarTemplate" TargetType="{x:Type ScrollBar}">
|
|
<Setter Property="Background" Value="{StaticResource VerticalScrollBarBackground}"/>
|
|
<Setter Property="Stylus.IsPressAndHoldEnabled" Value="false"/>
|
|
<Setter Property="Stylus.IsFlicksEnabled" Value="false"/>
|
|
<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}"/>
|
|
<Setter Property="Width" Value="{DynamicResource {x:Static SystemParameters.VerticalScrollBarWidthKey}}"/>
|
|
<Setter Property="MinWidth" Value="{DynamicResource {x:Static SystemParameters.VerticalScrollBarWidthKey}}"/>
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type ScrollBar}">
|
|
<Grid x:Name="Bg" Background="{TemplateBinding Background}" SnapsToDevicePixels="true">
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition MaxHeight="{DynamicResource {x:Static SystemParameters.VerticalScrollBarButtonHeightKey}}"/>
|
|
<RowDefinition Height="*"/>
|
|
<RowDefinition MaxHeight="{DynamicResource {x:Static SystemParameters.VerticalScrollBarButtonHeightKey}}"/>
|
|
</Grid.RowDefinitions>
|
|
<RepeatButton Command="{x:Static ScrollBar.LineUpCommand}" IsEnabled="{TemplateBinding IsMouseOver}" Style="{StaticResource ScrollBarButtonUP}"/>
|
|
<Track x:Name="PART_Track" IsDirectionReversed="true" IsEnabled="{TemplateBinding IsMouseOver}" Grid.Row="1">
|
|
<Track.DecreaseRepeatButton>
|
|
<RepeatButton Command="{x:Static ScrollBar.PageUpCommand}" Style="{StaticResource VerticalScrollBarPageButton}"/>
|
|
</Track.DecreaseRepeatButton>
|
|
<Track.IncreaseRepeatButton>
|
|
<RepeatButton Command="{x:Static ScrollBar.PageDownCommand}" Style="{StaticResource VerticalScrollBarPageButton}"/>
|
|
</Track.IncreaseRepeatButton>
|
|
<Track.Thumb>
|
|
<Thumb Style="{StaticResource ScrollBarThumbVertical}"/>
|
|
</Track.Thumb>
|
|
</Track>
|
|
<RepeatButton Command="{x:Static ScrollBar.LineDownCommand}" IsEnabled="{TemplateBinding IsMouseOver}" Grid.Row="2" Style="{StaticResource ScrollBarButtonDOWN}"/>
|
|
</Grid>
|
|
<ControlTemplate.Triggers>
|
|
<Trigger Property="IsEnabled" Value="false">
|
|
<Setter Property="Background" TargetName="Bg" Value="{StaticResource ScrollBarDisabledBackground}"/>
|
|
</Trigger>
|
|
</ControlTemplate.Triggers>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
<Style.Triggers>
|
|
<Trigger Property="Orientation" Value="Horizontal">
|
|
<Setter Property="Width" Value="Auto"/>
|
|
<Setter Property="MinWidth" Value="0"/>
|
|
<Setter Property="Height" Value="{DynamicResource {x:Static SystemParameters.HorizontalScrollBarHeightKey}}"/>
|
|
<Setter Property="MinHeight" Value="{DynamicResource {x:Static SystemParameters.HorizontalScrollBarHeightKey}}"/>
|
|
<Setter Property="Background" Value="{StaticResource HorizontalScrollBarBackground}"/>
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type ScrollBar}">
|
|
<Grid x:Name="Bg" Background="{TemplateBinding Background}" SnapsToDevicePixels="true">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition MaxWidth="{DynamicResource {x:Static SystemParameters.HorizontalScrollBarButtonWidthKey}}"/>
|
|
<ColumnDefinition Width="*"/>
|
|
<ColumnDefinition MaxWidth="{DynamicResource {x:Static SystemParameters.HorizontalScrollBarButtonWidthKey}}"/>
|
|
</Grid.ColumnDefinitions>
|
|
<RepeatButton Command="{x:Static ScrollBar.LineLeftCommand}" IsEnabled="{TemplateBinding IsMouseOver}" Style="{StaticResource ScrollBarButtonLEFT}" Themes:ScrollChrome.ScrollGlyph="LeftArrow"/>
|
|
<Track x:Name="PART_Track" Grid.Column="1" IsEnabled="{TemplateBinding IsMouseOver}">
|
|
<Track.DecreaseRepeatButton>
|
|
<RepeatButton Command="{x:Static ScrollBar.PageLeftCommand}" Style="{StaticResource HorizontalScrollBarPageButton}"/>
|
|
</Track.DecreaseRepeatButton>
|
|
<Track.IncreaseRepeatButton>
|
|
<RepeatButton Command="{x:Static ScrollBar.PageRightCommand}" Style="{StaticResource HorizontalScrollBarPageButton}"/>
|
|
</Track.IncreaseRepeatButton>
|
|
<Track.Thumb>
|
|
<Thumb Style="{StaticResource ScrollBarThumbHorizontal}"/>
|
|
</Track.Thumb>
|
|
</Track>
|
|
<RepeatButton Grid.Column="2" Command="{x:Static ScrollBar.LineRightCommand}" IsEnabled="{TemplateBinding IsMouseOver}" Style="{StaticResource ScrollBarButtonRIGHT}" Themes:ScrollChrome.ScrollGlyph="RightArrow"/>
|
|
</Grid>
|
|
<ControlTemplate.Triggers>
|
|
<Trigger Property="IsEnabled" Value="false">
|
|
<Setter Property="Background" TargetName="Bg" Value="{StaticResource ScrollBarDisabledBackground}"/>
|
|
</Trigger>
|
|
</ControlTemplate.Triggers>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Trigger>
|
|
</Style.Triggers>
|
|
</Style>
|
|
</Grid.Resources>
|
|
<Rectangle x:Name="Corner" Grid.Column="1" Fill="#FF5D5D5D" Grid.Row="1"/>
|
|
<ScrollContentPresenter x:Name="PART_ScrollContentPresenter" CanContentScroll="{TemplateBinding CanContentScroll}" CanHorizontallyScroll="False" CanVerticallyScroll="False" ContentTemplate="{TemplateBinding ContentTemplate}" Content="{TemplateBinding Content}" Grid.Column="0" Margin="{TemplateBinding Padding}" Grid.Row="0"/>
|
|
<ScrollBar x:Name="PART_VerticalScrollBar" AutomationProperties.AutomationId="VerticalScrollBar" Cursor="Arrow" Grid.Column="1" Maximum="{TemplateBinding ScrollableHeight}" Minimum="0" Grid.Row="0" Visibility="{TemplateBinding ComputedVerticalScrollBarVisibility}" Value="{Binding VerticalOffset, Mode=OneWay, RelativeSource={RelativeSource TemplatedParent}}" ViewportSize="{TemplateBinding ViewportHeight}" Style="{DynamicResource ScrollBarTemplate}"></ScrollBar>
|
|
<ScrollBar x:Name="PART_HorizontalScrollBar" AutomationProperties.AutomationId="HorizontalScrollBar" Cursor="Arrow" Grid.Column="0" Maximum="{TemplateBinding ScrollableWidth}" Minimum="0" Orientation="Horizontal" Grid.Row="1" Visibility="{TemplateBinding ComputedHorizontalScrollBarVisibility}" Value="{Binding HorizontalOffset, Mode=OneWay, RelativeSource={RelativeSource TemplatedParent}}" ViewportSize="{TemplateBinding ViewportWidth}" Style="{DynamicResource ScrollBarTemplate}"/>
|
|
</Grid>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
|
|
<Style x:Key="ExpanderHeaderFocusVisual">
|
|
<Setter Property="Control.Template">
|
|
<Setter.Value>
|
|
<ControlTemplate>
|
|
<Border>
|
|
<Rectangle Margin="0" SnapsToDevicePixels="true" Stroke="Black" StrokeThickness="1" StrokeDashArray="1 2"/>
|
|
</Border>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
|
|
<Style x:Key="ExpanderDownHeaderStyle" TargetType="{x:Type ToggleButton}">
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type ToggleButton}">
|
|
<Border Padding="{TemplateBinding Padding}" SnapsToDevicePixels="True">
|
|
<VisualStateManager.VisualStateGroups>
|
|
<VisualStateGroup x:Name="CommonStates">
|
|
<VisualStateGroup.Transitions>
|
|
<VisualTransition GeneratedDuration="0:0:0.1" From="MouseOver"/>
|
|
<VisualTransition GeneratedDuration="0:0:0.1" To="MouseOver"/>
|
|
</VisualStateGroup.Transitions>
|
|
<VisualState x:Name="Normal"/>
|
|
<VisualState x:Name="MouseOver">
|
|
<Storyboard>
|
|
<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(Shape.StrokeThickness)" Storyboard.TargetName="circle">
|
|
<EasingDoubleKeyFrame KeyTime="0" Value="2"/>
|
|
</DoubleAnimationUsingKeyFrames>
|
|
</Storyboard>
|
|
</VisualState>
|
|
<VisualState x:Name="Pressed"/>
|
|
<VisualState x:Name="Disabled"/>
|
|
</VisualStateGroup>
|
|
<VisualStateGroup x:Name="CheckStates">
|
|
<VisualStateGroup.Transitions>
|
|
<VisualTransition GeneratedDuration="0:0:0.1" To="Checked"/>
|
|
<VisualTransition GeneratedDuration="0:0:0.1" From="Checked"/>
|
|
</VisualStateGroup.Transitions>
|
|
<VisualState x:Name="Unchecked"/>
|
|
<VisualState x:Name="Indeterminate"/>
|
|
</VisualStateGroup>
|
|
</VisualStateManager.VisualStateGroups>
|
|
|
|
<Grid Background="Transparent" SnapsToDevicePixels="False">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="19"/>
|
|
<ColumnDefinition Width="*"/>
|
|
</Grid.ColumnDefinitions>
|
|
<Ellipse x:Name="circle" Fill="Transparent" HorizontalAlignment="Center" Height="18" Stroke="#FFCCCCCC" VerticalAlignment="Center" Width="18" StrokeDashArray="1 0"/>
|
|
<Path x:Name="arrow" Data="M 1,1.5 L 4.5,5 L 8,1.5" HorizontalAlignment="Center" SnapsToDevicePixels="false" Stroke="#FFCCCCCC" StrokeThickness="2" VerticalAlignment="Center" RenderTransformOrigin="0.5,0.5">
|
|
<Path.RenderTransform>
|
|
<TransformGroup>
|
|
<ScaleTransform/>
|
|
<SkewTransform/>
|
|
<RotateTransform/>
|
|
<TranslateTransform/>
|
|
</TransformGroup>
|
|
</Path.RenderTransform>
|
|
</Path>
|
|
<ContentPresenter Grid.Column="1" HorizontalAlignment="Left" Margin="4,0,0,0" RecognizesAccessKey="True" SnapsToDevicePixels="True" VerticalAlignment="Center"/>
|
|
</Grid>
|
|
</Border>
|
|
|
|
<ControlTemplate.Triggers>
|
|
<Trigger Property="IsChecked" Value="true">
|
|
<Setter Property="Data" TargetName="arrow" Value="M 1,4.5 L 4.5,1 L 8,4.5"/>
|
|
<Setter Property="RenderTransform" TargetName="arrow">
|
|
<Setter.Value>
|
|
<TransformGroup>
|
|
<RotateTransform Angle="0"/>
|
|
</TransformGroup>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Trigger>
|
|
<Trigger Property="IsMouseOver" Value="true">
|
|
<Setter Property="Stroke" TargetName="circle" Value="#FFE8E8E8"/>
|
|
<Setter Property="Fill" TargetName="circle" Value="Transparent"/>
|
|
<Setter Property="Stroke" TargetName="arrow" Value="#FFE8E8E8"/>
|
|
</Trigger>
|
|
<Trigger Property="IsPressed" Value="true">
|
|
<Setter Property="Stroke" TargetName="circle" Value="#FFCCCCCC"/>
|
|
<Setter Property="StrokeThickness" TargetName="circle" Value="1.5"/>
|
|
<Setter Property="Fill" TargetName="circle" Value="Transparent"/>
|
|
<Setter Property="Stroke" TargetName="arrow" Value="#FFCCCCCC"/>
|
|
</Trigger>
|
|
<Trigger Property="IsEnabled" Value="false">
|
|
<Setter Property="Stroke" TargetName="circle" Value="#FFA2A2A2"/>
|
|
<Setter Property="Fill" TargetName="circle" Value="Transparent"/>
|
|
<Setter Property="Stroke" TargetName="arrow" Value="#FFA2A2A2"/>
|
|
</Trigger>
|
|
</ControlTemplate.Triggers>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
|
|
<Style x:Key="ExpanderStyleDefault" TargetType="{x:Type Expander}">
|
|
<Setter Property="Foreground" Value="White"/>
|
|
<Setter Property="Background" Value="Transparent"/>
|
|
<Setter Property="HorizontalContentAlignment" Value="Stretch"/>
|
|
<Setter Property="VerticalContentAlignment" Value="Stretch"/>
|
|
<Setter Property="BorderBrush" Value="Transparent"/>
|
|
<Setter Property="BorderThickness" Value="1"/>
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type Expander}">
|
|
<Border BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" CornerRadius="3" SnapsToDevicePixels="true">
|
|
<DockPanel>
|
|
<ToggleButton x:Name="HeaderSite" ContentTemplate="{TemplateBinding HeaderTemplate}" ContentTemplateSelector="{TemplateBinding HeaderTemplateSelector}" Content="{TemplateBinding Header}" DockPanel.Dock="Top" Foreground="{TemplateBinding Foreground}" FontWeight="{TemplateBinding FontWeight}" FocusVisualStyle="{StaticResource ExpanderHeaderFocusVisual}" FontStyle="{TemplateBinding FontStyle}" FontStretch="{TemplateBinding FontStretch}" FontSize="{TemplateBinding FontSize}" FontFamily="{TemplateBinding FontFamily}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" IsChecked="{Binding IsExpanded, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}" Margin="1" MinWidth="0" MinHeight="0" Padding="{TemplateBinding Padding}" Style="{StaticResource ExpanderDownHeaderStyle}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}"/>
|
|
<ContentPresenter x:Name="ExpandSite" DockPanel.Dock="Bottom" Focusable="false" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" Visibility="Collapsed" VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
|
|
</DockPanel>
|
|
</Border>
|
|
<ControlTemplate.Triggers>
|
|
<Trigger Property="IsExpanded" Value="true">
|
|
<Setter Property="Visibility" TargetName="ExpandSite" Value="Visible"/>
|
|
</Trigger>
|
|
<Trigger Property="IsEnabled" Value="false">
|
|
<Setter Property="Foreground" Value="#FFCCCCCC"/>
|
|
</Trigger>
|
|
</ControlTemplate.Triggers>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
</ResourceDictionary>
|
|
</Application.Resources>
|
|
</Application>
|