<Page xmlns:local="clr-namespace:ForzaUI"
      xmlns:System="clr-namespace:System;assembly=mscorlib"
      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
      xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
      x:Class="ForzaUI.A_GameOptions"
      mc:Ignorable="d"
      Style="{StaticResource A_Style_Page_Generic}"
      DataContext="{Binding RelativeSource={RelativeSource Self}}">

    <Page.Resources>
        <ResourceDictionary>
            <local:TileMenuDataItem x:Key="A_MenuDataItem_Assists"
                                    Heading="{local:Loc TiledMenus.IDS_Options_TileTitle_Difficulty}"
                                    Description="{local:Loc TiledMenus.IDS_Options_TileText_Difficulty}"
                                    Icon="/ForzaUI;component/Textures/Anthem/TileBackgrounds/Difficulty.png"
                                    FloatingIcon="/ForzaUI;component/Textures/Anthem/Icons/TiledMenus/FloatingIcons/Cog.png"/>
            <local:TileMenuDataItem x:Key="A_MenuDataItem_Controls"
                                    Heading="{local:Loc TiledMenus.IDS_Options_TileTitle_Controls}"
                                    Description="{local:Loc TiledMenus.IDS_Options_TileText_Controls}"
                                    Icon="/ForzaUI;component/Textures/Anthem/TileBackgrounds/Controls.png"
                                    FloatingIcon="/ForzaUI;component/Textures/Anthem/Icons/TiledMenus/FloatingIcons/Controller.png"/>
            <local:TileMenuDataItem x:Key="A_MenuDataItem_Hud"
                                    Heading="{local:Loc TiledMenus.IDS_Options_TileTitle_Hud}"
                                    Description="{local:Loc TiledMenus.IDS_Options_TileText_Hud}"
                                    Icon="/ForzaUI;component/Textures/Anthem/TileBackgrounds/Hud.png"
                                    FloatingIcon="/ForzaUI;component/Textures/Anthem/Icons/TiledMenus/FloatingIcons/Hud.png"/>
            <local:TileMenuDataItem x:Key="A_MenuDataItem_Accessibility"
                                    Heading="{local:Loc TiledMenus.IDS_Options_TileTitle_Accessibility}"
                                    Description="{local:Loc TiledMenus.IDS_Options_TileText_Accessibility}"
                                    Icon="/ForzaUI;component/Textures/Anthem/TileBackgrounds/Accessibility.png"
                                    FloatingIcon="/ForzaUI;component/Textures/Anthem/Icons/TiledMenus/FloatingIcons/Cog.png"/>
            <local:TileMenuDataItem x:Key="A_MenuDataItem_Audio"
                                    Description="{local:Loc TiledMenus.IDS_Options_TileText_Audio}"
                                    Icon="/ForzaUI;component/Textures/Anthem/Icons/TiledMenus/Audio.png" />
            <local:TileMenuDataItem x:Key="A_MenuDataItem_Video"
                                    Description="{local:Loc TiledMenus.IDS_Options_TileText_Video}"
                                    Icon="/ForzaUI;component/Textures/Anthem/Icons/TiledMenus/Video.png" />
            <local:TileMenuDataItem x:Key="A_MenuDataItem_QuickChatSelect"
                                    Description="{local:Loc TiledMenus.IDS_Options_TileText_QuickChatSelect}"
                                    Icon="/ForzaUI;component/Textures/Anthem/Icons/TiledMenus/QuickChatSelect.png"/>
        </ResourceDictionary>
    </Page.Resources>

    <local:UIPageTransitionManager.TransitionManager>
        <local:UIPageTransitionManager Preset="{StaticResource A_UIPageTransitionManagerPreset_TiledSubMenu}"/>
    </local:UIPageTransitionManager.TransitionManager>

    <Grid>
        <!-- Bars -->
        <local:PlayerBarControl x:Name="TopBar" Style="{StaticResource A_Style_PlayerBarControl}" />
        <ContentControl x:Name="BottomBar"
                        Style="{StaticResource A_Style_ButtonBar}">
            <ContentControl x:Name="DefaultHelpPanel"
                            local:ControllerButtonPanel.ADescription="{local:Loc HelpButtons.IDS_Select}"
                            local:ControllerButtonPanel.BDescription="{local:Loc HelpButtons.IDS_Back}"
                            Style="{StaticResource A_Style_ContentControl_DefaultButtonBar}" />
        </ContentControl>

        <Border Style="{StaticResource A_Style_Border_ScenePadding_TiledScene}">
            <Grid x:Name="LayoutRoot"
                KeyboardNavigation.DirectionalNavigation="Contained"
                Style="{StaticResource A_Style_FrameworkElement_ScreenTilt}">
                <Grid.RowDefinitions>
                    <RowDefinition Height="*"/>
                    <RowDefinition Height="{StaticResource A_GridLength_TileMenu_Height}"/>
                </Grid.RowDefinitions>
                <Decorator Style="{StaticResource A_Style_FrameworkElement_TiledMenuTransition_1}"
                           HorizontalAlignment="Left"
                           VerticalAlignment="Bottom"
                           Margin="408,0,0,0"
                           Grid.Row="0">
                    <ContentControl Content="{local:Loc ScreenTitles.IDS_GameOptions}" Style="{StaticResource A_Style_ContentControl_ScreenTitleBlock}"
                                    local:BindingProxy.A="/ForzaUI;component/Textures/Anthem/Icons/Titles/Options.png"/>
                </Decorator>

                <StackPanel x:Name="PART_MenuContent"
                    RenderTransformOrigin="0.5,0.5"
                    Grid.Row="1">
                    <local:AutoSizeCanvas x:Name="PART_SCOPE_Home">
                        <local:FZButton x:Name="PART_Button_Controls"
                                DataContext="{StaticResource A_MenuDataItem_Controls}"
                                Style="{StaticResource A_Style_Button_ImageTile}"
                                local:TileMenuNavigationManager.GridX="52"
                                local:TileMenuNavigationManager.GridY="0"
                                local:TileMenuNavigationManager.GridWidth="13"
                                local:TileMenuNavigationManager.GridHeight="16"/>
                        <local:FZButton x:Name="PART_Button_Accessibility"
                                DataContext="{StaticResource A_MenuDataItem_Accessibility}"
                                Style="{StaticResource A_Style_Button_ImageTile_TileColorScheme_Border}"
                                local:TileMenuNavigationManager.GridX="9"
                                local:TileMenuNavigationManager.GridY="0"
                                local:TileMenuNavigationManager.GridWidth="13"
                                local:TileMenuNavigationManager.GridHeight="16"
                                local:TileMenuNavigationManager.TileColorScheme="{x:Static local:TileColorScheme.Accessibility}"/>
                        <local:FZButton x:Name="PART_Button_Audio"
                                DataContext="{StaticResource A_MenuDataItem_Audio}"
                                Style="{StaticResource A_Style_Button_IconTile}"
                                local:TileMenuNavigationManager.GridX="14"
                                local:TileMenuNavigationManager.GridY="16"/>
                        <local:FZButton x:Name="PART_Button_Hud"
                                Style="{StaticResource A_Style_Button_ImageTile}"
                                DataContext="{StaticResource A_MenuDataItem_Hud}"
                                local:TileMenuNavigationManager.GridX="23"
                                local:TileMenuNavigationManager.GridY="16"
                                local:TileMenuNavigationManager.GridWidth="21"
                                local:TileMenuNavigationManager.GridHeight="14"/>
                        <local:FZButton x:Name="PART_Button_Video"
                                Style="{StaticResource A_Style_Button_IconTile}"
                                DataContext="{StaticResource A_MenuDataItem_Video}"
                                local:TileMenuNavigationManager.GridX="14"
                                local:TileMenuNavigationManager.GridY="20"/>
                        
                        <local:FZButton x:Name="PART_Button_QuickChatSelect"
                                Style="{StaticResource A_Style_Button_IconTile}"
                                DataContext="{StaticResource A_MenuDataItem_QuickChatSelect}"
                                local:TileMenuNavigationManager.GridX="14"
                                local:TileMenuNavigationManager.GridY="24"
                                local:TileMenuNavigationManager.TileState="{x:Static local:TileState.Disabled}"/>
                        <local:FZButton x:Name="PART_Button_Assists"
                                DataContext="{StaticResource A_MenuDataItem_Assists}"
                                Style="{StaticResource A_Style_Button_MainImageTile}"
                                local:TileMenuNavigationManager.GridX="22"
                                local:TileMenuNavigationManager.GridY="0"/>
                        <local:DifficultyBonusInfographicTile x:Name="PART_Button_Infographic"
                                               Style="{StaticResource A_Style_Infographics_Button_Difficulty}"
                                               local:TileMenuNavigationManager.GridX="44"
                                               local:TileMenuNavigationManager.GridY="16">
                            <local:DifficultyBonusInfographicTile.DataContext>
                                <local:RadialInfographicData Title="{local:Loc TiledMenus.IDS_Infographics_DifficultyBonus}"
                                    Color="#00B18F"
                                    ProgressStringFormat="{x:Static local:InfographicStringFormat.PercentageAbsolute}"
                                    ForcePositiveSign="True"
                                    StatIcon="/ForzaUI;component/Textures/Data_Bound/Infographics/Difficulty_Bonus.png">
                                    <local:RadialInfographicData.LocalUserInfographicData>
                                        <local:UserInfographicData />
                                    </local:RadialInfographicData.LocalUserInfographicData>
                                </local:RadialInfographicData>
                            </local:DifficultyBonusInfographicTile.DataContext>
                        </local:DifficultyBonusInfographicTile>
                    </local:AutoSizeCanvas>
                </StackPanel>
            </Grid>
        </Border>
    </Grid>
</Page>
