<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"
    mc:Ignorable="d"
	x:Class="ForzaUI.TVR_Sagaris_05">
	
    <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="False" UseDegreesF="True" UseMPH="True" UsePsi="True" MaxBoost="13" MinBoost="1" MaxSpeed="120" HasAbsLight="False" HasStmLight="False" HasTcsLight="False" HasGAccelX="False" HasGAccelY="False" HasShiftLights="True" HasTextTach="False" HasLapPlaceInfo="False" HasTextBoost="False" HasTextGAccel="False" HasTextOdometer="True" HasTextFuel="True" MaxFuel="20" MaxGear="8" MaxRpm="9000"></local:DigitalGaugeConfig>
		<Storyboard x:Key="Fuel Gauge">
			<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Bar_1">
				<EasingDoubleKeyFrame KeyTime="0" Value="0"/>
				<EasingDoubleKeyFrame KeyTime="0:0:0.125" Value="1"/>
			</DoubleAnimationUsingKeyFrames>
			<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Bar_2">
				<EasingDoubleKeyFrame KeyTime="0:0:0.125" Value="0"/>
				<EasingDoubleKeyFrame KeyTime="0:0:0.25" Value="1"/>
			</DoubleAnimationUsingKeyFrames>
			<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Bar_3">
				<EasingDoubleKeyFrame KeyTime="0:0:0.25" Value="0"/>
				<EasingDoubleKeyFrame KeyTime="0:0:0.375" Value="1"/>
			</DoubleAnimationUsingKeyFrames>
			<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Bar_4">
				<EasingDoubleKeyFrame KeyTime="0:0:0.375" Value="0"/>
				<EasingDoubleKeyFrame KeyTime="0:0:0.5" Value="1"/>
			</DoubleAnimationUsingKeyFrames>
			<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Bar_5">
				<EasingDoubleKeyFrame KeyTime="0:0:0.5" Value="0"/>
				<EasingDoubleKeyFrame KeyTime="0:0:0.625" Value="1"/>
			</DoubleAnimationUsingKeyFrames>
			<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Bar_6">
				<EasingDoubleKeyFrame KeyTime="0:0:0.625" Value="0"/>
				<EasingDoubleKeyFrame KeyTime="0:0:0.75" Value="1"/>
			</DoubleAnimationUsingKeyFrames>
			<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Bar_7">
				<EasingDoubleKeyFrame KeyTime="0:0:0.75" Value="0"/>
				<EasingDoubleKeyFrame KeyTime="0:0:0.875" Value="1"/>
			</DoubleAnimationUsingKeyFrames>
			<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Bar_8">
				<EasingDoubleKeyFrame KeyTime="0:0:0.875" Value="0"/>
				<EasingDoubleKeyFrame KeyTime="0:0:1" Value="1"/>
			</DoubleAnimationUsingKeyFrames>
		</Storyboard>
		<Storyboard x:Key="Shift Lights Progress">
			<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Green_Light_1_On">
				<EasingDoubleKeyFrame KeyTime="0:0:0.591" Value="0"/>
				<EasingDoubleKeyFrame KeyTime="0:0:0.598" Value="1"/>
			</DoubleAnimationUsingKeyFrames>
			<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Yellow_Light_1_On">
				<EasingDoubleKeyFrame KeyTime="0:0:0.696" Value="0"/>
				<EasingDoubleKeyFrame KeyTime="0:0:0.704" Value="1"/>
			</DoubleAnimationUsingKeyFrames>
			<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Red_Light_1_On">
				<EasingDoubleKeyFrame KeyTime="0:0:0.81" Value="0"/>
				<EasingDoubleKeyFrame KeyTime="0:0:0.818" Value="1"/>
			</DoubleAnimationUsingKeyFrames>
			<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="Green_Light_1_On">
				<DiscreteObjectKeyFrame KeyTime="0:0:0.598" Value="{x:Static Visibility.Visible}"/>
				<DiscreteObjectKeyFrame KeyTime="0:0:0.835" Value="{x:Static Visibility.Hidden}"/>
			</ObjectAnimationUsingKeyFrames>
			<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="Yellow_Light_1_On">
				<DiscreteObjectKeyFrame KeyTime="0:0:0.704" Value="{x:Static Visibility.Visible}"/>
				<DiscreteObjectKeyFrame KeyTime="0:0:0.835" Value="{x:Static Visibility.Hidden}"/>
			</ObjectAnimationUsingKeyFrames>
			<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="Red_Light_1_On">
				<DiscreteObjectKeyFrame KeyTime="0:0:0.818" Value="{x:Static Visibility.Visible}"/>
				<DiscreteObjectKeyFrame KeyTime="0:0:0.835" Value="{x:Static Visibility.Hidden}"/>
			</ObjectAnimationUsingKeyFrames>
			<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="FLASHING">
				<DiscreteObjectKeyFrame KeyTime="0" Value="{x:Static Visibility.Hidden}"/>
				<DiscreteObjectKeyFrame KeyTime="0:0:0.835" Value="{x:Static Visibility.Visible}"/>
			</ObjectAnimationUsingKeyFrames>
		</Storyboard>
		<Storyboard x:Key="Shift Lights Flash" RepeatBehavior="Forever">
			<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="Green_Light_1_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="Yellow_Light_1_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="Red_Light_1_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>
		<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>
	</Page.Resources>
	<Page.Triggers>
		<EventTrigger RoutedEvent="FrameworkElement.Loaded" SourceName="LayoutRoot">
			<BeginStoryboard Storyboard="{StaticResource Shift Lights Flash}"/>
		</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" Stroke="Black" Width="1280" Canvas.Left="0" Canvas.Top="0" />
        <Rectangle x:Name="Background_GaugeDisplay" Fill="#FF1F190A" Height="200" Canvas.Left="325" Canvas.Top="260" Width="630"/>
        <Canvas x:Name="Fuel" Canvas.Left="724.5" Canvas.Top="319" Height="168" Width="256">
            <Rectangle x:Name="Bar_1" Fill="#FF889E2E" Height="3" Canvas.Left="37" Canvas.Top="91" Width="22" Opacity="0"/>
            <Rectangle x:Name="Bar_2" Fill="#FF889E2E" Height="6" Canvas.Left="58" Canvas.Top="88" Width="22" Opacity="0"/>
            <Rectangle x:Name="Bar_3" Fill="#FF889E2E" Height="9" Canvas.Left="79" Canvas.Top="85" Width="22" Opacity="0"/>
            <Rectangle x:Name="Bar_4" Fill="#FF889E2E" Height="12" Canvas.Left="100" Canvas.Top="82" Width="22" Opacity="0"/>
            <Rectangle x:Name="Bar_5" Fill="#FF889E2E" Height="15" Canvas.Left="121" Canvas.Top="79" Width="22" Opacity="0"/>
            <Rectangle x:Name="Bar_6" Fill="#FF889E2E" Height="18" Canvas.Left="139" Canvas.Top="76" Width="22" Opacity="0"/>
            <Rectangle x:Name="Bar_7" Fill="#FF889E2E" Height="21" Canvas.Left="160" Canvas.Top="73" Width="22" Opacity="0"/>
            <Rectangle x:Name="Bar_8" Fill="#FF889E2E" Height="24" Canvas.Left="178" Canvas.Top="70" Width="22" Opacity="0"/>
		</Canvas>
        <Image x:Name="Text_Trip_Baked"
            Height="32" Source="game:/media/cars/TVR_Sagaris_05/UI/Textures/TVR_Sagaris_05_txt_trip.png" Stretch="Fill" Width="128" Canvas.Left="640" Canvas.Top="330"/>
        <Image x:Name="Text_Fuel_Baked" Height="32" Canvas.Left="642" Source="game:/media/cars/TVR_Sagaris_05/UI/Textures/TVR_Sagaris_05_txt_fuel.png" Stretch="Fill" Canvas.Top="404" Width="128"/>
        <Image x:Name="Text_Mph_Baked" Height="32" Canvas.Left="518" Source="game:/media/cars/TVR_Sagaris_05/UI/Textures/TVR_Sagaris_05_txt_mph.png" Stretch="Fill" Canvas.Top="330" Width="64"/>
		<Canvas x:Name="Text" Height="720" Width="1280">
            <local:FastTextBlock x:Name="Text_Speed" Canvas.Left="270.793" Canvas.Top="244.501" Text="{Binding Speed}" Width="250" FontSize="80" Style="{StaticResource TextBlockStyle}" Foreground="#FF889E2E" FontFamily="DG4_PF_Ronda_Seven"/>
            <local:FastTextBlock x:Name="Text_Trip_Odo" Canvas.Left="812.192" Canvas.Top="322.5" Text="{Binding TripMeter}" Width="98.333" FontSize="24" Style="{StaticResource TextBlockStyle}" Foreground="#FF889E2E" FontFamily="DG4_PF_Ronda_Seven"/>
            <local:FastTextBlock x:Name="Text_Clock" Canvas.Left="838.525" Canvas.Top="264.466" Text="{Binding Time}" FontSize="24" Style="{StaticResource TextBlockStyle}" Foreground="#FF889E2E" FontFamily="DG4_PF_Ronda_Seven"/>
		</Canvas>
        <Canvas x:Name="Shift_Lights" Height="32" Width="600" Canvas.Left="341" Canvas.Top="154.5">
        	<Canvas x:Name="OFF" Height="32" Width="600">
        		<Image x:Name="Green_Light_1_Off" Height="64" Source="game:/media/cars/TVR_Sagaris_05/UI/Textures/TVR_Sagaris_05_GreenLight_Off.PNG" Stretch="Fill" Width="64" Canvas.Top="-15" Canvas.Left="222" RenderTransformOrigin="0.5,0.5" Opacity="0.25" OpacityMask="Black">
        			<Image.RenderTransform>
        				<TransformGroup>
        					<ScaleTransform ScaleX="2.2" ScaleY="2.2"/>
        					<SkewTransform/>
        					<RotateTransform/>
        					<TranslateTransform/>
        				</TransformGroup>
        			</Image.RenderTransform>
        		</Image>
        		<Image x:Name="Yellow_Light_1_Off" Height="64" Source="game:/media/cars/TVR_Sagaris_05/UI/Textures/TVR_Sagaris_05_YellowLight_Off.PNG" Stretch="Fill" Width="64" Canvas.Top="-15" Canvas.Left="268" RenderTransformOrigin="0.5,0.5" Opacity="0.25">
        			<Image.RenderTransform>
        				<TransformGroup>
        					<ScaleTransform ScaleX="2.1" ScaleY="2.1"/>
        					<SkewTransform/>
        					<RotateTransform/>
        					<TranslateTransform/>
        				</TransformGroup>
        			</Image.RenderTransform>
        		</Image>
        		<Image x:Name="Red_Light_1_Off" Height="64" Source="game:/media/cars/TVR_Sagaris_05/UI/Textures/TVR_Sagaris_05_RedLight_Off.PNG" Stretch="Fill" Width="64" Canvas.Top="-15" Canvas.Left="315" RenderTransformOrigin="0.5,0.5" Opacity="0.25">
        			<Image.RenderTransform>
        				<TransformGroup>
        					<ScaleTransform ScaleX="2.2" ScaleY="2.2"/>
        					<SkewTransform/>
        					<RotateTransform/>
        					<TranslateTransform/>
        				</TransformGroup>
        			</Image.RenderTransform>
        		</Image>
        	</Canvas>
        	<Canvas x:Name="ON" Height="32" Width="600">
        		<Image x:Name="Green_Light_1_On" Height="64" Source="game:/media/cars/TVR_Sagaris_05/UI/Textures/TVR_Sagaris_05_GreenLight_On.PNG" Stretch="Fill" Width="64" Canvas.Top="-15" Canvas.Left="222" Opacity="0" RenderTransformOrigin="0.5,0.5">
        			<Image.RenderTransform>
        				<TransformGroup>
        					<ScaleTransform ScaleX="2.2" ScaleY="2.2"/>
        					<SkewTransform/>
        					<RotateTransform/>
        					<TranslateTransform/>
        				</TransformGroup>
        			</Image.RenderTransform>
        		</Image>
        		<Image x:Name="Yellow_Light_1_On" Height="64" Source="game:/media/cars/TVR_Sagaris_05/UI/Textures/TVR_Sagaris_05_YellowLight_On.PNG" Stretch="Fill" Width="64" Canvas.Top="-15" Canvas.Left="268" Opacity="0" RenderTransformOrigin="0.5,0.5">
        			<Image.RenderTransform>
        				<TransformGroup>
        					<ScaleTransform ScaleX="2.1" ScaleY="2.1"/>
        					<SkewTransform/>
        					<RotateTransform/>
        					<TranslateTransform/>
        				</TransformGroup>
        			</Image.RenderTransform>
        		</Image>
        		<Image x:Name="Red_Light_1_On" Height="64" Source="game:/media/cars/TVR_Sagaris_05/UI/Textures/TVR_Sagaris_05_RedLight_On.PNG" Stretch="Fill" Width="64" Canvas.Top="-15" Canvas.Left="315" Opacity="0" RenderTransformOrigin="0.5,0.5">
        			<Image.RenderTransform>
        				<TransformGroup>
        					<ScaleTransform ScaleX="2.2" ScaleY="2.2"/>
        					<SkewTransform/>
        					<RotateTransform/>
        					<TranslateTransform/>
        				</TransformGroup>
        			</Image.RenderTransform>
        		</Image>
        	</Canvas>
        	<Canvas x:Name="FLASHING" Height="32" Width="600" Visibility="Hidden">
        		<Image x:Name="Green_Light_1_Flashing" Height="64" Source="game:/media/cars/TVR_Sagaris_05/UI/Textures/TVR_Sagaris_05_GreenLight_On.PNG" Stretch="Fill" Width="64" Canvas.Top="-15" Canvas.Left="222" RenderTransformOrigin="0.5,0.5">
        			<Image.RenderTransform>
        				<TransformGroup>
        					<ScaleTransform ScaleX="2.2" ScaleY="2.2"/>
        					<SkewTransform/>
        					<RotateTransform/>
        					<TranslateTransform/>
        				</TransformGroup>
        			</Image.RenderTransform>
        		</Image>
        		<Image x:Name="Yellow_Light_1_Flashing" Height="64" Source="game:/media/cars/TVR_Sagaris_05/UI/Textures/TVR_Sagaris_05_YellowLight_On.PNG" Stretch="Fill" Width="64" Canvas.Top="-15" Canvas.Left="268" RenderTransformOrigin="0.5,0.5">
        			<Image.RenderTransform>
        				<TransformGroup>
        					<ScaleTransform ScaleX="2.1" ScaleY="2.1"/>
        					<SkewTransform/>
        					<RotateTransform/>
        					<TranslateTransform/>
        				</TransformGroup>
        			</Image.RenderTransform>
        		</Image>
        		<Image x:Name="Red_Light_1_Flashing" Height="64" Source="game:/media/cars/TVR_Sagaris_05/UI/Textures/TVR_Sagaris_05_RedLight_On.PNG" Stretch="Fill" Width="64" Canvas.Top="-15" Canvas.Left="315" RenderTransformOrigin="0.5,0.5">
        			<Image.RenderTransform>
        				<TransformGroup>
        					<ScaleTransform ScaleX="2.2" ScaleY="2.2"/>
        					<SkewTransform/>
        					<RotateTransform/>
        					<TranslateTransform/>
        				</TransformGroup>
        			</Image.RenderTransform>
        		</Image>
        	</Canvas>
        </Canvas>
        <Canvas x:Name="Fuel_Static_Graphics" Height="50" Canvas.Left="755" Canvas.Top="383" Width="176">
        	<Rectangle x:Name="Top" Fill="#FF889E2E" Height="3" Canvas.Left="6" Canvas.Top="33" Width="165"/>
        	<Rectangle x:Name="Tic_1" Fill="#FF889E2E" Height="10" Canvas.Left="6" Canvas.Top="36" Width="3"/>
        	<Rectangle x:Name="Tic_2" Fill="#FF889E2E" Height="10" Canvas.Left="27" Canvas.Top="36" Width="3"/>
        	<Rectangle x:Name="Tic_3" Fill="#FF889E2E" Height="10" Canvas.Left="48" Canvas.Top="36" Width="3"/>
        	<Rectangle x:Name="Tic_4" Fill="#FF889E2E" Height="10" Canvas.Left="69" Canvas.Top="36" Width="3"/>
        	<Rectangle x:Name="Tic_5" Fill="#FF889E2E" Height="10" Canvas.Left="90" Canvas.Top="36" Width="3"/>
        	<Rectangle x:Name="Tic_6" Fill="#FF889E2E" Height="10" Canvas.Left="110" Canvas.Top="36" Width="3"/>
        	<Rectangle x:Name="Tic_7" Fill="#FF889E2E" Height="10" Canvas.Left="129" Canvas.Top="36" Width="3"/>
        	<Rectangle x:Name="Tic_8" Fill="#FF889E2E" Height="10" Canvas.Left="149" Canvas.Top="36" Width="3"/>
        	<Rectangle x:Name="Tic_9" Fill="#FF889E2E" Height="10" Canvas.Left="168" Canvas.Top="36" Width="3"/>
        </Canvas>
        <Rectangle x:Name="Start_Up_Mask" Fill="Black" Height="668" Stroke="Black" Width="1186" Canvas.Left="58" Canvas.Top="53" Opacity="0"/>
		
						<!-- Storyboard binding controllers -->
		<local:StoryboardController SeekPct="{Binding Tach}" Target="{StaticResource Shift Lights Progress}"/>
		<local:StoryboardController SeekPct="{Binding Fuel}" Target="{StaticResource Fuel Gauge}"/>
	</Canvas>
</Page>