<Application
    x:Class="GridTreeViewSamples.App"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="using:GridTreeViewSamples" >

    <Application.Resources>
        <ResourceDictionary>
            <ResourceDictionary.ThemeDictionaries>
                <ResourceDictionary x:Key="Default">
                    <x:String x:Key="BackButtonGlyph">&#xE071;</x:String>
                    <x:String x:Key="BackButtonSnappedGlyph">&#xE0BA;</x:String>
                </ResourceDictionary>

                <ResourceDictionary x:Key="HighContrast">
                    <x:String x:Key="BackButtonGlyph">&#xE0A6;</x:String>
                    <x:String x:Key="BackButtonSnappedGlyph">&#xE0C4;</x:String>
                </ResourceDictionary>
            </ResourceDictionary.ThemeDictionaries>

            <!-- Application-specific resources -->
            <local:Strings x:Key="GridTreeViewSamplesLocalization" />
            <!--***************** CONTROL ICONS *****************-->

            <SolidColorBrush x:Key="IconBrush" Color="White"/>

            <SolidColorBrush x:Key="IconGrayBackground" Color="#FF777777"/>
            <!-- Page layout roots typically use entrance animations and a theme-appropriate background color -->

            <Style x:Key="LayoutRootStyle" TargetType="Panel">
                <Setter Property="Background" Value="{StaticResource ApplicationPageBackgroundThemeBrush}"/>
                <Setter Property="ChildrenTransitions">
                    <Setter.Value>
                        <TransitionCollection>
                            <EntranceThemeTransition/>
                        </TransitionCollection>
                    </Setter.Value>
                </Setter>
            </Style>

            <Style x:Key="IconName" TargetType="TextBlock">
                <Setter Property="Foreground" Value="{StaticResource IconBrush}"/>
                <!-- <Setter Property="FontSize" Value="12"/>-->
                <Setter Property="TextAlignment" Value="Center"/>
                <Setter Property="VerticalAlignment" Value="Bottom"/>
                <Setter Property="Margin" Value="-5,0,-5,1"/>
            </Style>

            <DataTemplate x:Key="IconC1Gray">
                <Grid Background="{StaticResource IconGrayBackground}" Height="60" Width="60">
                    <TextBlock TextWrapping="Wrap" Text="{Binding}" Style="{StaticResource IconName}"/>
                </Grid>
            </DataTemplate>

            <DataTemplate x:Key="Standard250x250ItemTemplate">
                <Grid HorizontalAlignment="Left" Width="150" Height="150">
                    <Border Background="#FF2C383D">
                        <ContentControl ContentTemplate="{Binding Icon}" VerticalContentAlignment="Stretch" HorizontalContentAlignment="Stretch" Margin="28 16 28 40"/>
                    </Border>
                    <Border VerticalAlignment="Bottom" Height="34">
                        <TextBlock Text="{Binding Name}" Foreground="White" FontFamily="Segoe WP" FontSize="17" VerticalAlignment="Center" TextAlignment="Center"/>
                    </Border>
                </Grid>
            </DataTemplate>
            <DataTemplate x:Key="Standard80ItemTemplate">
                <Grid Margin="6">
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition Width="Auto"/>
                        <ColumnDefinition Width="*"/>
                    </Grid.ColumnDefinitions>
                    <Border Background="{StaticResource ListViewItemPlaceholderBackgroundThemeBrush}" Width="60" Height="60">
                        <ContentControl ContentTemplate="{Binding Icon}" VerticalContentAlignment="Stretch" HorizontalContentAlignment="Stretch"/>
                    </Border>
                    <StackPanel Grid.Column="1" Margin="10,0,0,0">
                        <TextBlock Text="{Binding Title}" Style="{ThemeResource BodyTextBlockStyle}" MaxHeight="40"/>
                        <TextBlock Text="{Binding Description}" Style="{ThemeResource CaptionTextBlockStyle}" TextWrapping="WrapWholeWords"/>
                    </StackPanel>
                </Grid>
            </DataTemplate>
            
            <DataTemplate x:Name="IconC1GridTreeView" >
                <Path Data="M19,39 L26,39 L26,41 L19,41 z M17,37 L17,43 L28.000002,43 L28.000002,37 z M17,35 L28,35 C29.104568,35 30,35.895432 30,37 L30,43 C30,44.104568 29.104568,45 28,45 L17,45 C15.895431,45 15,44.104568 15,43 L15,37 C15,35.895432 15.895431,35 17,35 z M34,26 L41,26 L41,28 L34,28 z M32.000004,24 L32.000004,30 L43,30 L43,24 z M32,22 L43,22 C44.104568,22 45,22.895432 45,24 L45,30 C45,31.104568 44.104568,32 43,32 L32,32 C30.895432,32 30,31.104568 30,30 L30,24 C30,22.895432 30.895432,22 32,22 z M21,22 L23,22 L23,23.174362 L23.000002,26 C23.000002,26.517769 23.393501,26.943628 23.897758,26.994839 L24.000002,27 L26.825636,27 L28,27 L29,27 L29,29 L24.000027,29 C22.343145,29 21,27.656855 21,26 z M6.000001,16 L8.000001,16 L8.000001,18 L6.000001,18 z M19,15 L26,15 L26,17 L19,17 z M5.0000019,15 L5.0000019,19 L9.000001,19 L9.000001,15 z M17,13 L17,19 L28.000002,19 L28.000002,13 z M17,11 L28,11 C29.104568,11 30,11.895431 30,13 L30,19 C30,20.104568 29.104568,21 28,21 L17,21 C15.895431,21 15,20.104568 15,19 L15,13 C15,11.895431 15.895431,11 17,11 z M6.0000005,11 L8,11 L8,14 L10,14 L10,16 L14,16 L14,18 L10,18 L10,20 L8,20 L8,30 L8,39 C8.000001,39.517769 8.3935003,39.943626 8.8977556,39.994835 L9,40 L11.825637,40 L14,40 L14,42 L9,42 C7.3431454,42 6,40.656853 6.0000005,39 L6.000001,38 L6.0000005,20 L3.9999998,20 L3.9999998,14 L6.0000005,14 z M4.0000005,3.9999998 L11,3.9999998 L11,6.0000005 L4.0000005,6.0000005 z M2.0000005,1.9999999 L2.0000005,7.999999 L13,7.999999 L13,1.9999999 z M1.9999999,0 L13,0 C14.104569,0 15,0.89542961 15,1.9999999 L15,8 C15,9.1045704 14.104569,10 13,10 L1.9999999,10 C0.89542961,10 0,9.1045704 0,8 L0,1.9999999 C0,0.89542961 0.89542961,0 1.9999999,0 z"
                       Fill="{StaticResource IconBrush}" Stretch="Uniform"/>
            </DataTemplate>

        </ResourceDictionary>
    </Application.Resources>
</Application>
