2 xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
3 xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
4 xmlns:v="clr-namespace:Microsoft.SDK.Samples.VistaBridge.Controls"
6 <Style x:Key="BackButtonStyle" TargetType="{x:Type Button}">
7 <Setter Property="Template">
9 <ControlTemplate TargetType="{x:Type Button}">
11 <Canvas Background="Red">
12 <Image Width="29" Height="26" Name="LeftBackButtonDisabled" Source="pack://application:,,/VistaBridgeControls;component/Images/BackButtons/LeftBackButtonDisabled.png" Opacity="1"/>
13 <Image Width="29" Height="26" Name="LeftBackButtonEnabled" Source="pack://application:,,/VistaBridgeControls;component/Images/BackButtons/LeftBackButtonEnabled.png" Opacity="0"/>
14 <Image Width="29" Height="26" Name="LeftBackButtonHover" Source="pack://application:,,/VistaBridgeControls;component/Images/BackButtons/LeftBackButtonHover.png" Opacity="0"/>
15 <Image Width="29" Height="26" Name="LeftBackButtonPressed" Source="pack://application:,,/VistaBridgeControls;component/Images/BackButtons/LeftBackButtonPressed.png" Opacity="0"/>
18 <ControlTemplate.Triggers>
19 <Trigger Value="True" Property="IsEnabled">
20 <Setter Property="Opacity" Value="1" TargetName="LeftBackButtonEnabled"/>
22 <EventTrigger RoutedEvent="Button.MouseEnter">
23 <EventTrigger.Actions>
25 <Storyboard Storyboard.TargetName="LeftBackButtonHover" Storyboard.TargetProperty="Opacity">
26 <DoubleAnimation To="1" Duration="0:0:0.5"/>
29 </EventTrigger.Actions>
31 <EventTrigger RoutedEvent="Button.MouseLeave">
32 <EventTrigger.Actions>
34 <Storyboard Storyboard.TargetName="LeftBackButtonHover" Storyboard.TargetProperty="Opacity">
35 <DoubleAnimation To="0" Duration="0:0:0.5"/>
38 </EventTrigger.Actions>
40 <EventTrigger RoutedEvent="Button.PreviewMouseLeftButtonDown">
41 <EventTrigger.Actions>
43 <Storyboard Storyboard.TargetName="LeftBackButtonPressed" Storyboard.TargetProperty="Opacity">
44 <DoubleAnimation To="1" Duration="0:0:0.2"/>
47 </EventTrigger.Actions>
49 <EventTrigger RoutedEvent="Button.PreviewMouseLeftButtonUp">
50 <EventTrigger.Actions>
52 <Storyboard Storyboard.TargetName="LeftBackButtonPressed" Storyboard.TargetProperty="Opacity">
53 <DoubleAnimation To="0" Duration="0:0:0.2"/>
56 </EventTrigger.Actions>
58 </ControlTemplate.Triggers>
63 <Style TargetType="{x:Type v:AeroWizard}">
64 <Setter Property="Template">
66 <ControlTemplate TargetType="{x:Type v:AeroWizard}">
67 <StackPanel Margin="-1,-2,0,0" Background="Transparent">
68 <StackPanel Height="37" Orientation="Horizontal" VerticalAlignment="Top">
69 <Button VerticalAlignment="Top" Width="29" Margin="0,5,0,2" Name="BackButton" Command="BrowseBack" Style="{StaticResource BackButtonStyle}"/>
70 <Image VerticalAlignment="Top" Name="ico" Margin="7,2,7,2" Source="{TemplateBinding Glyph}"/>
71 <TextBlock TextAlignment="Center" VerticalAlignment="Center" Foreground="#000000" FontFamily="Segoe UI" FontSize="12" Text="{TemplateBinding Title}">
72 <TextBlock.BitmapEffect>
73 <OuterGlowBitmapEffect GlowColor="White" GlowSize="7"/>
74 </TextBlock.BitmapEffect>
77 <Border BorderBrush="Black" BorderThickness="1" Margin="0,1,-1,0" CornerRadius="2">
78 <StackPanel x:Name="clientArea" Background="White">
80 <TextBlock Margin="38,19,38,19" FontFamily="Segoe UI Regular" TextWrapping="Wrap" Text="{TemplateBinding MainInstruction}" FontSize="16" Foreground="#1370AB"/>
82 <ContentPresenter Content="{TemplateBinding ContentArea}" HorizontalAlignment="Left" Margin="38,19,38,19" Width="555" Height="286" />
83 <Grid Background="#F5F5F5" Name="CommandArea">
84 <Line X1="0" X2="{Binding ElementName=CommandArea, Path=ActualWidth}" Y1="0" Y2="0" Stroke="Gray" StrokeThickness="1"/>
85 <DockPanel LastChildFill="False" Margin="0,14,19,14" Name="Commands">
86 <Button Padding="12,0,12,0" VerticalAlignment="Center" Margin="7,0,0,0" DockPanel.Dock="Right" Content="Cancel"/>
87 <Button Visibility="Hidden" DockPanel.Dock="Right" Content="Next"/>
93 <ControlTemplate.Triggers>
94 <DataTrigger Binding="{Binding Path=ContentArea.CanGoBack, RelativeSource={RelativeSource Self}}" Value="True">
95 <Setter Property="Button.IsEnabled" Value="True" TargetName="BackButton" />
97 <DataTrigger Binding="{Binding Path=ContentArea.CanGoBack, RelativeSource={RelativeSource Self}}" Value="False">
98 <Setter Property="Button.IsEnabled" Value="False" TargetName="BackButton" />
100 </ControlTemplate.Triggers>
104 <Setter Property="WindowStyle" Value="SingleBorderWindow"/>
105 <!--<Setter Property="Icon" Value="pack://application:,,,/None.ico"/>-->
106 <Setter Property="Background" Value="Transparent"/>
107 <Setter Property="Width" Value="620"/>
108 <Setter Property="Height" Value="489"/>
109 <Setter Property="WindowState" Value="Minimized"/>
110 <Setter Property="ResizeMode" Value="CanMinimize"/>
112 </ResourceDictionary>