<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.BMW_98_325iFD_89">
	
    <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="False" 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="False" HasTextFuel="False" MaxFuel="20" MaxGear="8" MaxRpm="10000"></local:DigitalGaugeConfig>
        
		<Storyboard x:Key="Shift Lights Progress">
			<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="YellowLight_On">
				<DiscreteObjectKeyFrame KeyTime="0" Value="{x:Static Visibility.Hidden}"/>
				<DiscreteObjectKeyFrame KeyTime="0:0:0.55" Value="{x:Static Visibility.Visible}"/>
				<DiscreteObjectKeyFrame KeyTime="0:0:0.77" Value="{x:Static Visibility.Hidden}"/>
				<DiscreteObjectKeyFrame KeyTime="0:0:1" Value="{x:Static Visibility.Hidden}"/>
			</ObjectAnimationUsingKeyFrames>
			<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="RedLight_On">
				<DiscreteObjectKeyFrame KeyTime="0" Value="{x:Static Visibility.Hidden}"/>
				<DiscreteObjectKeyFrame KeyTime="0:0:0.77" Value="{x:Static Visibility.Visible}"/>
				<DiscreteObjectKeyFrame KeyTime="0:0:1" Value="{x:Static Visibility.Hidden}"/>
			</ObjectAnimationUsingKeyFrames>
		</Storyboard>
		<Storyboard x:Key="Shift Lights Flash" RepeatBehavior="Forever"/>
		<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_Grey" Fill="Black" Height="720" Width="1280" Canvas.Left="0" Canvas.Top="0" />
        <Rectangle x:Name="Background_Shift_Lights" Fill="Black" Height="107" Canvas.Left="340" Canvas.Top="301" Width="600"/>
        <Canvas x:Name="Shift_Lights" Height="92" Width="600" Canvas.Left="432" Canvas.Top="316">
        	<Canvas x:Name="OFF" Height="92" Width="600">
        		<Image x:Name="YellowLight_Off" Height="128" Source="game:/media/cars/BMW_98_325iFD_89/UI/Textures/AST_007_DBR9_06_YellowLight_Off.PNG" Stretch="Fill" Width="128" Canvas.Top="-15" Canvas.Left="109" Opacity="0.25"/>
        		<Image x:Name="RedLight_Off" Height="128" Source="game:/media/cars/BMW_98_325iFD_89/UI/Textures/AST_007_DBR9_06_RedLight_Off.PNG" Stretch="Fill" Width="128" Canvas.Top="-15" Canvas.Left="165" Opacity="0.25"/>
        	</Canvas>
        	<Canvas x:Name="ON" Height="92" Width="600">
        		<Image x:Name="YellowLight_On" Height="128" Source="game:/media/cars/BMW_98_325iFD_89/UI/Textures/AST_007_DBR9_06_YellowLight_On.PNG" Stretch="Fill" Width="128" Canvas.Top="-15" Canvas.Left="109" Visibility="Hidden"/>
        		<Image x:Name="RedLight_On" Height="128" Source="game:/media/cars/BMW_98_325iFD_89/UI/Textures/AST_007_DBR9_06_RedLight_On.PNG" Stretch="Fill" Width="128" Canvas.Top="-15" Canvas.Left="165" Visibility="Hidden"/>
        	</Canvas>
        	<Canvas x:Name="FLASHING" Height="92" Width="600" Visibility="Hidden">
        		<Image x:Name="YellowLight_FLASHING" Height="128" Source="game:/media/cars/BMW_98_325iFD_89/UI/Textures/AST_007_DBR9_06_YellowLight_On.PNG" Stretch="Fill" Width="128" Canvas.Top="-15" Canvas.Left="109"/>
        		<Image x:Name="RedLight_FLASHING" Height="128" Source="game:/media/cars/BMW_98_325iFD_89/UI/Textures/AST_007_DBR9_06_RedLight_On.PNG" Stretch="Fill" Width="128" Canvas.Top="-15" Canvas.Left="165"/>
        	</Canvas>
        </Canvas>
        <Rectangle x:Name="Start_Up_Mask" Fill="Black" Height="720" Stroke="Black" Width="1280" Canvas.Left="0" Canvas.Top="0" Opacity="0"/>
		
				<!-- Storyboard binding controllers -->
		<local:StoryboardController SeekPct="{Binding Tach}" Target="{StaticResource Shift Lights Progress}"/>
		
		
	</Canvas>
</Page>