aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/Tango.Explorer/Themes/Generic.xaml
blob: c920ce6bc84f94575e4c27cef3bd8f52fc366299 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch"
    xmlns:local="clr-namespace:Tango.Explorer">

    <Style TargetType="{x:Type local:ExplorerControl}">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type local:ExplorerControl}">
                    <Border Background="{TemplateBinding Background}"
                            BorderBrush="{TemplateBinding BorderBrush}"
                            BorderThickness="{TemplateBinding BorderThickness}">

                        <touch:TouchListBox SelectionMode="None" ItemsSource="{Binding RelativeSource={RelativeSource AncestorType=local:ExplorerControl},Path=CurrentFolder.Items}" SelectedItem="{Binding RelativeSource={RelativeSource AncestorType=local:ExplorerControl},Path=SelectedItem,Mode=TwoWay}">
                            <touch:TouchListBox.ItemTemplate>
                                <DataTemplate DataType="local:ExplorerItem">
                                    <Border Padding="8" BorderBrush="#E9E9E9" BorderThickness="0 0 0 1">
                                        <DockPanel>
                                            <Image DockPanel.Dock="Left" Source="{Binding Icon}" Width="50" Height="50" />
                                            <StackPanel VerticalAlignment="Center" Margin="20 0 0 0">
                                                <TextBlock FontSize="16" Text="{Binding Name}"></TextBlock>
                                                <TextBlock Opacity="0.5" FontSize="12" Margin="0 5 0 0" Text="{Binding Description}"></TextBlock>
                                            </StackPanel>
                                        </DockPanel>
                                    </Border>
                                </DataTemplate>
                            </touch:TouchListBox.ItemTemplate>
                        </touch:TouchListBox>

                    </Border>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>


</ResourceDictionary>