<Page
	xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
	xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
	xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
    xmlns:System="clr-namespace:System;assembly=mscorlib"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
    xmlns:local="clr-namespace:ForzaUI"
    xmlns:ed="http://schemas.microsoft.com/expression/2010/drawing"
    mc:Ignorable="d"
	x:Class="ForzaUI.CAD_CT5VBlackwing_22">

    <Page.Resources>
        <Style x:Key="TextBlockStyle" TargetType="{x:Type local:FastTextBlock}">
            <Setter Property="FontFamily" Value="Moire"/>
            <Setter Property="Foreground" Value="White"/>
             
            <Setter Property="TextAlignment" Value="Right"/>
        </Style>

        <local:DigitalGaugeConfig x:Key="Config" HasClock="True" HasExternalTemp="True" UseDegreesF="True" UseMPH="True" UsePsi="True" MaxBoost="13" MinBoost="1" MaxSpeed="100.08" HasAbsLight="False" HasStmLight="False" HasTcsLight="False" HasGAccelX="True" HasGAccelY="True" HasShiftLights="False" HasTextTach="False" HasLapPlaceInfo="False" HasTextBoost="True" HasTextGAccel="True" HasTextOdometer="True" HasTextFuel="False" MaxFuel="20.0" MinGear="-1" MaxGear="6" MaxRpm="7000"/>

        <Storyboard x:Key="Tach">
            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" Storyboard.TargetName="Textures_CAD_CT4VBlackwing_22_Tach_png">
                <EasingDoubleKeyFrame KeyTime="0" Value="-53.974"/>
                <EasingDoubleKeyFrame KeyTime="0:0:1" Value="197.873"/>
            </DoubleAnimationUsingKeyFrames>
            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(ed:Arc.EndAngle)" Storyboard.TargetName="Tach_2">
                <EasingDoubleKeyFrame KeyTime="0" Value="90"/>
                <EasingDoubleKeyFrame KeyTime="0:0:1" Value="342"/>
            </DoubleAnimationUsingKeyFrames>
        </Storyboard>
        <Storyboard x:Key="Start Up Animation">
            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Start_Up_Mask">
                <EasingDoubleKeyFrame KeyTime="0" Value="1"/>
                <EasingDoubleKeyFrame KeyTime="0:0:1" Value="0"/>
            </DoubleAnimationUsingKeyFrames>
        </Storyboard>
        <Storyboard x:Key="Fuel Gauge">
            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(FrameworkElement.Width)" Storyboard.TargetName="Fuel">
                <EasingDoubleKeyFrame KeyTime="0" Value="0"/>
                <EasingDoubleKeyFrame KeyTime="0:0:1" Value="114"/>
            </DoubleAnimationUsingKeyFrames>
        </Storyboard>
        <Storyboard x:Key="Shift Light Progress">
            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="Textures_CAD_CT4VBlackwing_22_YellowLight_ON">
                <DiscreteObjectKeyFrame KeyTime="0" Value="{x:Static Visibility.Hidden}"/>
                <DiscreteObjectKeyFrame KeyTime="0:0:0.8" Value="{x:Static Visibility.Visible}"/>
                <DiscreteObjectKeyFrame KeyTime="0:0:1" Value="{x:Static Visibility.Hidden}"/>
            </ObjectAnimationUsingKeyFrames>
            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="Textures_CAD_CT4VBlackwing_22_RedLight_ON">
                <DiscreteObjectKeyFrame KeyTime="0" Value="{x:Static Visibility.Hidden}"/>
                <DiscreteObjectKeyFrame KeyTime="0:0:1" Value="{x:Static Visibility.Visible}"/>
            </ObjectAnimationUsingKeyFrames>
            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="FLASHING">
                <DiscreteObjectKeyFrame KeyTime="0" Value="{x:Static Visibility.Hidden}"/>
                <DiscreteObjectKeyFrame KeyTime="0:0:1" Value="{x:Static Visibility.Visible}"/>
            </ObjectAnimationUsingKeyFrames>
        </Storyboard>
        <Storyboard x:Key="Shift Lights Flash">
            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="Textures_CAD_CT4VBlackwing_22_YellowLight_FLASHING">
                <DiscreteObjectKeyFrame KeyTime="0" Value="{x:Static Visibility.Visible}"/>
                <DiscreteObjectKeyFrame KeyTime="0:0:0.25" Value="{x:Static Visibility.Hidden}"/>
                <DiscreteObjectKeyFrame KeyTime="0:0:0.5" Value="{x:Static Visibility.Hidden}"/>
            </ObjectAnimationUsingKeyFrames>
            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="Textures_CAD_CT4VBlackwing_22_RedLight_FLASHING">
                <DiscreteObjectKeyFrame KeyTime="0" Value="{x:Static Visibility.Visible}"/>
                <DiscreteObjectKeyFrame KeyTime="0:0:0.25" Value="{x:Static Visibility.Hidden}"/>
                <DiscreteObjectKeyFrame KeyTime="0:0:0.5" Value="{x:Static Visibility.Hidden}"/>
            </ObjectAnimationUsingKeyFrames>
        </Storyboard>
    </Page.Resources>
    <Page.Triggers>
        <EventTrigger RoutedEvent="FrameworkElement.Loaded" SourceName="LayoutRoot">
            <BeginStoryboard Storyboard="{StaticResource Tach}"/>
            <BeginStoryboard x:Name="Shift_Light_Progress_BeginStoryboard" Storyboard="{StaticResource Shift Light Progress}"/>
            <BeginStoryboard x:Name="Shift_Lights_Flash_BeginStoryboard" Storyboard="{StaticResource Shift Lights Flash}"/>
            <BeginStoryboard x:Name="Fuel_Gauge_BeginStoryboard" Storyboard="{StaticResource Fuel Gauge}"/>
        </EventTrigger>
    </Page.Triggers>


    <Canvas x:Name="LayoutRoot" Background="Transparent" Width="1280" Height="720">
        <VisualStateManager.VisualStateGroups>
            <VisualStateGroup x:Name="NightDaySplit">
                <VisualState x:Name="Day"/>
                <VisualState x:Name="Night"/>
            </VisualStateGroup>
        </VisualStateManager.VisualStateGroups>
        <Rectangle x:Name="Background_Black" Fill="Black" Height="720" Width="1280" Canvas.Left="0" Canvas.Top="0"/>
        <Rectangle x:Name="Start_Up_Mask" Fill="Black" Height="720" Stroke="Black" Width="1280" Opacity="0"/>
        <ed:Arc x:Name="Tach_2" ArcThickness="1" ArcThicknessUnit="Percent" Fill="#FFAA0909" Height="340" Canvas.Left="380" Stretch="None" StartAngle="90" Canvas.Top="130" Width="340" RenderTransformOrigin="0.5,0.5">
            <ed:Arc.RenderTransform>
                <TransformGroup>
                    <ScaleTransform/>
                    <SkewTransform/>
                    <RotateTransform Angle="36.09"/>
                    <TranslateTransform/>
                </TransformGroup>
            </ed:Arc.RenderTransform>
        </ed:Arc>
        <Image x:Name="Textures_CAD_CT4VBlackwing_22_Driver_png" Height="600" Source="game:/media/cars/CAD_CT5VBlackwing_22/UI/Textures/CAD_CT4VBlackwing_22_Driver.png" Stretch="Fill" Width="1100" RenderTransformOrigin="0.5,0.5">
            <Image.RenderTransform>
                <TransformGroup>
                    <ScaleTransform ScaleY="0.8" ScaleX="0.8"/>
                    <SkewTransform/>
                    <RotateTransform/>
                    <TranslateTransform/>
                </TransformGroup>
            </Image.RenderTransform>
        </Image>
        <Canvas x:Name="Fuel" Height="10" Width="114" ClipToBounds="True" Canvas.Top="437.598" Canvas.Left="777.034" RenderTransformOrigin="0.5,0.5">
            <Canvas.RenderTransform>
                <TransformGroup>
                    <ScaleTransform ScaleY="0.8" ScaleX="0.8"/>
                    <SkewTransform/>
                    <RotateTransform/>
                    <TranslateTransform/>
                </TransformGroup>
            </Canvas.RenderTransform>
            <Image x:Name="Textures_CAD_CT4VBlackwing_22_Fuel_png" Height="10" Source="game:/media/cars/CAD_CT5VBlackwing_22/UI/Textures/CAD_CT4VBlackwing_22_Fuel.png" Stretch="Fill" Width="114"/>
        </Canvas>
        <Image x:Name="Textures_CAD_CT4VBlackwing_22_Tach_png" Height="380" Source="game:/media/cars/CAD_CT5VBlackwing_22/UI/Textures/CAD_CT4VBlackwing_22_Tach.png" Stretch="Fill" Width="140" RenderTransformOrigin="0.5,0.5" Canvas.Top="110.198" Canvas.Left="480.2">
            <Image.RenderTransform>
                <TransformGroup>
                    <ScaleTransform ScaleY="0.8" ScaleX="0.8"/>
                    <SkewTransform/>
                    <RotateTransform/>
                    <TranslateTransform/>
                </TransformGroup>
            </Image.RenderTransform>
        </Image>
        <Image x:Name="Textures_CAD_CT4VBlackwing_22_Center_png" Height="600" Source="game:/media/cars/CAD_CT5VBlackwing_22/UI/Textures/CAD_CT4VBlackwing_22_Center.png" Stretch="Fill" Width="1100" Canvas.Left="622.664" RenderTransformOrigin="0.5,0.5" Canvas.Top="225">
            <Image.RenderTransform>
                <TransformGroup>
                    <ScaleTransform ScaleX="0.35" ScaleY="0.35"/>
                    <SkewTransform/>
                    <RotateTransform Angle="-90"/>
                    <TranslateTransform/>
                </TransformGroup>
            </Image.RenderTransform>
        </Image>
        <Canvas x:Name="ShiftLights" Height="230" Canvas.Left="435" Canvas.Top="185" Width="230">
            <Canvas x:Name="OFF" Height="230" Width="230">
                <Image x:Name="Textures_CAD_CT4VBlackwing_22_YellowLight_OFF" Height="230" Source="game:/media/cars/CAD_CT5VBlackwing_22/UI/Textures/CAD_CT4VBlackwing_22_YellowLight.png" Stretch="Fill" Width="230" RenderTransformOrigin="0.5,0.5" Opacity="0.1">
                    <Image.RenderTransform>
                        <TransformGroup>
                            <ScaleTransform ScaleX="0.8" ScaleY="0.8"/>
                            <SkewTransform/>
                            <RotateTransform/>
                            <TranslateTransform/>
                        </TransformGroup>
                    </Image.RenderTransform>
                </Image>
                <Image x:Name="Textures_CAD_CT4VBlackwing_22_RedLight_OFF" Height="230" Source="game:/media/cars/CAD_CT5VBlackwing_22/UI/Textures/CAD_CT4VBlackwing_22_RedLight.png" Stretch="Fill" Width="230" RenderTransformOrigin="0.5,0.5" Opacity="0.1">
                    <Image.RenderTransform>
                        <TransformGroup>
                            <ScaleTransform ScaleX="0.8" ScaleY="0.8"/>
                            <SkewTransform/>
                            <RotateTransform/>
                            <TranslateTransform/>
                        </TransformGroup>
                    </Image.RenderTransform>
                </Image>
            </Canvas>
            <Canvas x:Name="ON" Height="230" Width="230">
                <Image x:Name="Textures_CAD_CT4VBlackwing_22_YellowLight_ON" Height="230" Source="game:/media/cars/CAD_CT5VBlackwing_22/UI/Textures/CAD_CT4VBlackwing_22_YellowLight.png" Stretch="Fill" Width="230" RenderTransformOrigin="0.5,0.5">
                    <Image.RenderTransform>
                        <TransformGroup>
                            <ScaleTransform ScaleX="0.8" ScaleY="0.8"/>
                            <SkewTransform/>
                            <RotateTransform/>
                            <TranslateTransform/>
                        </TransformGroup>
                    </Image.RenderTransform>
                </Image>
                <Image x:Name="Textures_CAD_CT4VBlackwing_22_RedLight_ON" Height="230" Source="game:/media/cars/CAD_CT5VBlackwing_22/UI/Textures/CAD_CT4VBlackwing_22_RedLight.png" Stretch="Fill" Width="230" RenderTransformOrigin="0.5,0.5">
                    <Image.RenderTransform>
                        <TransformGroup>
                            <ScaleTransform ScaleX="0.8" ScaleY="0.8"/>
                            <SkewTransform/>
                            <RotateTransform/>
                            <TranslateTransform/>
                        </TransformGroup>
                    </Image.RenderTransform>
                </Image>
            </Canvas>
            <Canvas x:Name="FLASHING" Height="230" Width="230">
                <Image x:Name="Textures_CAD_CT4VBlackwing_22_YellowLight_FLASHING" Height="230" Source="game:/media/cars/CAD_CT5VBlackwing_22/UI/Textures/CAD_CT4VBlackwing_22_YellowLight.png" Stretch="Fill" Width="230" RenderTransformOrigin="0.5,0.5">
                    <Image.RenderTransform>
                        <TransformGroup>
                            <ScaleTransform ScaleX="0.8" ScaleY="0.8"/>
                            <SkewTransform/>
                            <RotateTransform/>
                            <TranslateTransform/>
                        </TransformGroup>
                    </Image.RenderTransform>
                </Image>
                <Image x:Name="Textures_CAD_CT4VBlackwing_22_RedLight_FLASHING" Height="230" Source="game:/media/cars/CAD_CT5VBlackwing_22/UI/Textures/CAD_CT4VBlackwing_22_RedLight.png" Stretch="Fill" Width="230" RenderTransformOrigin="0.5,0.5">
                    <Image.RenderTransform>
                        <TransformGroup>
                            <ScaleTransform ScaleX="0.8" ScaleY="0.8"/>
                            <SkewTransform/>
                            <RotateTransform/>
                            <TranslateTransform/>
                        </TransformGroup>
                    </Image.RenderTransform>
                </Image>
            </Canvas>
        </Canvas>
        <local:FastTextBlock x:Name="Text_G_Meter" Text="{Binding GAccelText}" Height="35"   Width="85" FontFamily="DG1_Arial" FontSize="36" Foreground="White" RenderTransformOrigin="0.5,0.5" TextAlignment="Right" Canvas.Top="243.5" Canvas.Left="145.5">
            <local:FastTextBlock.RenderTransform>
                <TransformGroup>
                    <ScaleTransform ScaleY="0.88000000000000012" ScaleX="0.88000000000000012"/>
                    <SkewTransform/>
                    <RotateTransform/>
                    <TranslateTransform/>
                </TransformGroup>
            </local:FastTextBlock.RenderTransform>
        </local:FastTextBlock>
        <local:FastTextBlock x:Name="Text_Boost" Text="{Binding BoostText}" Height="35"   Width="85" FontFamily="DG1_Arial" FontSize="36" Foreground="White" RenderTransformOrigin="0.5,0.5" TextAlignment="Center" Canvas.Top="344.5" Canvas.Left="281.5">
            <local:FastTextBlock.RenderTransform>
                <TransformGroup>
                    <ScaleTransform ScaleY="0.88000000000000012" ScaleX="0.88000000000000012"/>
                    <SkewTransform/>
                    <RotateTransform/>
                    <TranslateTransform/>
                </TransformGroup>
            </local:FastTextBlock.RenderTransform>
        </local:FastTextBlock>
        <local:FastTextBlock x:Name="Text_Odometer" Text="{Binding Odometer}" Height="25" Canvas.Left="55"   Canvas.Top="428.792" Width="100" FontFamily="DG1_Arial" Foreground="White" FontSize="22" TextAlignment="Right"/>
        <local:FastTextBlock x:Name="Text_External_Temp" Text="{Binding ExternalTemp}" Height="15" Canvas.Left="1250"   Canvas.Top="420" Width="40" FontFamily="DG1_Arial" Foreground="White" TextAlignment="Right" RenderTransformOrigin="0.5,0.5">
            <local:FastTextBlock.RenderTransform>
                <TransformGroup>
                    <ScaleTransform/>
                    <SkewTransform/>
                    <RotateTransform Angle="-90"/>
                    <TranslateTransform/>
                </TransformGroup>
            </local:FastTextBlock.RenderTransform>
        </local:FastTextBlock>
        <local:FastTextBlock x:Name="Text_Clock" Height="15" Canvas.Left="1250"   Canvas.Top="365" Width="40" FontFamily="DG1_Arial" Foreground="White" TextAlignment="Right" RenderTransformOrigin="0.5,0.5">
            <local:FastTextBlock.RenderTransform>
                <TransformGroup>
                    <ScaleTransform/>
                    <SkewTransform/>
                    <RotateTransform Angle="-90"/>
                    <TranslateTransform/>
                </TransformGroup>
            </local:FastTextBlock.RenderTransform></local:FastTextBlock>
        <local:FastTextBlock x:Name="Text_Speed" Text="{Binding Speed}" Height="55"   Width="104" TextAlignment="Right" FontFamily="DG1_Arial" FontSize="48" Foreground="White" Canvas.Left="596" Canvas.Top="269" RenderTransformOrigin="0.5,0.5">
            <local:FastTextBlock.RenderTransform>
                <TransformGroup>
                    <ScaleTransform ScaleX="1.25" ScaleY="1.25"/>
                    <SkewTransform AngleX="-10"/>
                    <RotateTransform/>
                    <TranslateTransform/>
                </TransformGroup>
            </local:FastTextBlock.RenderTransform>
        </local:FastTextBlock>
        <local:FastTextBlock x:Name="Text_Gear" Text="{Binding Gear}" Height="50" Canvas.Left="523.335"   Canvas.Top="270.5" Width="55" FontFamily="DG1_Arial" FontSize="48" Foreground="White" TextAlignment="Center" RenderTransformOrigin="0.5,0.5">
            <local:FastTextBlock.RenderTransform>
                <TransformGroup>
                    <ScaleTransform ScaleX="1.2" ScaleY="1.2"/>
                    <SkewTransform/>
                    <RotateTransform/>
                    <TranslateTransform/>
                </TransformGroup>
            </local:FastTextBlock.RenderTransform>
        </local:FastTextBlock>

        <!-- Storyboard binding controllers -->
        <local:StoryboardController SeekPct="{Binding Tach}" Target="{StaticResource Tach}"/>
        <local:StoryboardController SeekPct="{Binding Tach}" Target="{StaticResource Shift Light Progress}"/>
        <local:StoryboardController SeekPct="{Binding Fuel}" Target="{StaticResource Fuel Gauge}"/>


    </Canvas>
</Page>