| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475 |
- <ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- xmlns:ZUI="clr-namespace:CustomUI">
- <SolidColorBrush x:Key="TreeViewItem.TreeArrow.Static.Checked.Fill" Color="#FF595959" />
- <SolidColorBrush x:Key="TreeViewItem.TreeArrow.Static.Checked.Stroke" Color="#FF262626" />
- <SolidColorBrush x:Key="TreeViewItem.TreeArrow.MouseOver.Stroke" Color="#FF27C7F7" />
- <SolidColorBrush x:Key="TreeViewItem.TreeArrow.MouseOver.Fill" Color="#FFCCEEFB" />
- <SolidColorBrush x:Key="TreeViewItem.TreeArrow.MouseOver.Checked.Stroke" Color="#FF1CC4F7" />
- <SolidColorBrush x:Key="TreeViewItem.TreeArrow.MouseOver.Checked.Fill" Color="#FF82DFFB" />
- <PathGeometry x:Key="TreeArrow" Figures="M322.392 90.125l421.803 421.898-421.803 421.852v-843.75z" />
- <SolidColorBrush x:Key="TreeViewItem.TreeArrow.Static.Fill" Color="#657180" />
- <SolidColorBrush x:Key="TreeViewItem.TreeArrow.Static.Stroke" Color="#00818181" />
- <Style TargetType="{x:Type ZUI:AnimationButton}">
- <Setter Property="HorizontalContentAlignment" Value="Center" />
- <Setter Property="VerticalContentAlignment" Value="Center" />
- <Setter Property="Focusable" Value="True" />
- <Setter Property="Background" Value="Transparent" />
- <Setter Property="Template">
- <Setter.Value>
- <ControlTemplate TargetType="{x:Type ZUI:AnimationButton}">
- <Border x:Name="Bd" Background="{TemplateBinding Background}"
- BorderBrush="{TemplateBinding BorderBrush}"
- BorderThickness="{TemplateBinding BorderThickness}"
- SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
- UseLayoutRounding="{TemplateBinding UseLayoutRounding}">
- <Path x:Name="ExpandPath" Width="10" Height="10" Margin="{TemplateBinding Padding}"
- HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
- VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
- Data="{StaticResource TreeArrow}"
- Fill="{StaticResource TreeViewItem.TreeArrow.Static.Fill}"
- RenderTransformOrigin="0.5,0.5" Stretch="Uniform"
- Stroke="{StaticResource TreeViewItem.TreeArrow.Static.Stroke}"
- StrokeThickness="0">
- <Path.RenderTransform>
- <TransformGroup>
- <ScaleTransform />
- <SkewTransform />
- <RotateTransform />
- <TranslateTransform />
- </TransformGroup>
- </Path.RenderTransform>
- </Path>
- <VisualStateManager.VisualStateGroups>
- <VisualStateGroup x:Name="CheckStates">
- <VisualState x:Name="Checked">
- <Storyboard>
- <DoubleAnimation Duration="0:0:0.2" Storyboard.TargetName="ExpandPath"
- Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)"
- To="90" />
- </Storyboard>
- </VisualState>
- <VisualState x:Name="Unchecked">
- <Storyboard>
- <DoubleAnimation Duration="0:0:0.2" Storyboard.TargetName="ExpandPath"
- Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)"
- To="0" />
- </Storyboard>
- </VisualState>
- </VisualStateGroup>
- </VisualStateManager.VisualStateGroups>
- </Border>
- <ControlTemplate.Triggers>
- <Trigger Property="IsMouseOver" Value="True">
- <Setter TargetName="Bd" Property="Cursor" Value="Hand" />
- <Setter TargetName="Bd" Property="Background" Value="#F3F3F3" />
- </Trigger>
- </ControlTemplate.Triggers>
- </ControlTemplate>
- </Setter.Value>
- </Setter>
- </Style>
- </ResourceDictionary>
|