<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="DigitalGauge.TOY_CelicaSSi_03"
	 >
	
    <Page.Resources>
        <Style x:Key="TextBlockStyle" TargetType="{x:Type local:FastTextBlock}">
            <Setter Property="FontFamily" Value="DG2_LCD"/>
            <Setter Property="Foreground" Value="#FFFDAD4E"/>
             
            <Setter Property="TextAlignment" Value="Right"/>
        </Style>
		
		<local:DigitalGaugeConfig x:Key="Config" HasClock="False" HasExternalTemp="False" UseDegreesF="False" UseMPH="False" UsePsi="False" MaxBoost="13" MinBoost="1" MaxSpeed="00" HasAbsLight="False" HasStmLight="False" HasTcsLight="False" HasGAccelX="False" HasGAccelY="False" HasShiftLights="False" HasTextTach="False" HasLapPlaceInfo="False" HasTextBoost="False" HasTextGAccel="False" HasTextOdometer="True" HasTextFuel="False" MaxFuel="20" MaxGear="8" MaxRpm="10000"></local:DigitalGaugeConfig>
		<Storyboard x:Key="Fuel Gauge">
			<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)" Storyboard.TargetName="Fuel_Gauge_Animation">
				<EasingDoubleKeyFrame KeyTime="0" Value="0"/>
				<EasingDoubleKeyFrame KeyTime="0:0:1" Value="106.788"/>
			</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>
	</Page.Resources>
	<Page.Triggers>
		<EventTrigger RoutedEvent="FrameworkElement.Loaded">
			<BeginStoryboard Storyboard="{StaticResource Fuel Gauge}"/>
		</EventTrigger>
	</Page.Triggers>
	  

	<Canvas x:Name="LayoutRoot" Background="#FF3F3F3F" Width="1280" Height="720" TextBlock.Foreground="#E1000000">
		<VisualStateManager.VisualStateGroups>
			<VisualStateGroup x:Name="NightDaySplit">
				<VisualState x:Name="Day"/>
				<VisualState x:Name="Night"/>
			</VisualStateGroup>
		</VisualStateManager.VisualStateGroups>
        <Rectangle Fill="Black" Height="272" Canvas.Left="468" Stroke="Black" Canvas.Top="280" Width="300"/>
		<Canvas x:Name="Fuel_Gauge_Animation" Height="110" Canvas.Left="513" Canvas.Top="411" Width="220" RenderTransformOrigin="0.5,0">
			<Canvas.RenderTransform>
				<TransformGroup>
					<ScaleTransform/>
					<SkewTransform/>
					<RotateTransform/>
					<TranslateTransform/>
				</TransformGroup>
			</Canvas.RenderTransform>
			<Image x:Name="Cell_1" Height="110" Source="game:/media/cars/TOY_CelicaSSI_03/UI/Textures/TOY_CEL_SSI_03_FuelGaugeFill.png" Stretch="Fill" Canvas.Top="0" Width="110" RenderTransformOrigin="0.5,0.5" >
				<Image.RenderTransform>
					<TransformGroup>
						<ScaleTransform/>
						<SkewTransform/>
						<RotateTransform Angle="-90"/>
						<TranslateTransform/>
					</TransformGroup>
				</Image.RenderTransform>
			</Image>
			<Image x:Name="Cell_2" Height="110" Canvas.Left="110" Source="game:/media/cars/TOY_CelicaSSI_03/UI/Textures/TOY_CEL_SSI_03_FuelGaugeFill.png" Stretch="Fill" Canvas.Top="0" Width="110" RenderTransformOrigin="0.5,0.5" >
				<Image.RenderTransform>
					<TransformGroup>
						<ScaleTransform/>
						<SkewTransform/>
						<RotateTransform Angle="-180"/>
						<TranslateTransform/>
					</TransformGroup>
				</Image.RenderTransform>
			</Image>
		</Canvas>
        <Image x:Name="Gagues" Height="128" Canvas.Left="512" Source="game:/media/cars/TOY_CelicaSSI_03/UI/Textures/TOY_CEL_SSI_03_Fuel.png" Stretch="Fill" Canvas.Top="296" Width="256"/>
		<Canvas x:Name="Text"
		Height="720" Width="1280">
			<local:FastTextBlock x:Name="Text_Odometer" Canvas.Left="630" Canvas.Top="391.045" Text="{Binding Odometer}" Width="100" FontSize="24" Style="{StaticResource TextBlockStyle}" RenderTransformOrigin="0.5,0.5"/>
		</Canvas>
		<Rectangle x:Name="Fuel_Mask" Fill="Black" Height="140.333" Canvas.Left="468" Canvas.Top="412" Width="300.333"/>
        <Rectangle x:Name="Start_Up_Mask" Fill="#FFBFE8FE" Height="668" Stroke="Black" Width="1186" Canvas.Left="57.688" Canvas.Top="52" Opacity="0"/>

        <!-- Storyboard binding controllers -->
		<local:StoryboardController SeekPct="{Binding Fuel}" Target="{StaticResource Fuel Gauge}"/>
	</Canvas>
</Page>