<reactiveui:ReactiveUserControl x:Class="ImageSort.WPF.Views.FoldersView"
                                x:TypeArguments="vm:FoldersViewModel"
                                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"
                                xmlns:reactiveui="http://reactiveui.net"
                                xmlns:vm="clr-namespace:ImageSort.ViewModels;assembly=ImageSort"
                                xmlns:converters="clr-namespace:ImageSort.WPF.Converters"
                                xmlns:text="clr-namespace:ImageSort.Localization;assembly=ImageSort.Localization"
                                xmlns:views="clr-namespace:ImageSort.WPF.Views"
                                mc:Ignorable="d"
                                d:DesignHeight="450" d:DesignWidth="800">
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="auto" />
            <RowDefinition Height="*" />
        </Grid.RowDefinitions>

        <WrapPanel Orientation="Horizontal">
            <Button x:Name="Pin" Content="{x:Static text:Text.Pin}" />
            <Button x:Name="PinSelected" Content="{x:Static text:Text.PinSelected}" />
            <Button x:Name="Unpin" Content="{x:Static text:Text.Unpin}" />
            <Button x:Name="CreateFolder" Content="{x:Static text:Text.CreateFolder}" />
            <StackPanel Orientation="Horizontal">
                <Button x:Name="MoveSelectedPinnedFolderUp" Content="↑"
                        ToolTip="{x:Static text:Text.MoveSelectedPinnedFolderUp}" />
                <Button x:Name="MoveSelectedPinnedFolderDown" Content="↓"
                        ToolTip="{x:Static text:Text.MoveSelectedPinnedFolderDown}" />
            </StackPanel>
        </WrapPanel>

        <TreeView x:Name="Folders" Grid.Row="1">
            <TreeView.ItemTemplate>
                <HierarchicalDataTemplate DataType="{x:Type vm:FolderTreeItemViewModel}"
                                          ItemsSource="{Binding Children}">
                    <views:FolderTreeItemView ViewModel="{Binding}"/>
                </HierarchicalDataTemplate>
            </TreeView.ItemTemplate>
        </TreeView>
    </Grid>
</reactiveui:ReactiveUserControl>