<mah:MetroWindow x:Class="ZuneModdingHelper.AbstractUIGroupDialog"
        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:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
        xmlns:local="clr-namespace:ZuneModdingHelper"
        xmlns:absui="clr-namespace:OwlCore.Wpf.AbstractUI.Controls;assembly=OwlCore.Wpf"
        xmlns:mah="clr-namespace:MahApps.Metro.Controls;assembly=MahApps.Metro"
        mc:Ignorable="d"
        Title="Options" Height="450" Width="800"
        WindowStyle="ToolWindow">
    <Window.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <ResourceDictionary Source="pack://application:,,,/OwlCore.Wpf;component/AbstractUI/Themes/AbstractUIGroupPresenterStyle.xaml" />
            </ResourceDictionary.MergedDictionaries>
        </ResourceDictionary>
    </Window.Resources>

    <Grid x:Name="OptionsUIGrid" Grid.RowSpan="2">
        <Grid.RowDefinitions>
            <RowDefinition Height="*"/>
            <RowDefinition Height="Auto"/>
        </Grid.RowDefinitions>
        
        <ScrollViewer>
            <absui:AbstractUIGroupPresenter x:Name="OptionsUIPresenter" ViewModel="{Binding}"
                                        TemplateSelector="{StaticResource GroupTemplateSelector}"/>
        </ScrollViewer>
        
        <Border Grid.Row="1" BorderThickness="0,1,0,0" BorderBrush="{StaticResource MahApps.Brushes.Control.Border}">
            <Grid>
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="*"/>
                    <ColumnDefinition Width="Auto"/>
                    <ColumnDefinition Width="Auto"/>
                </Grid.ColumnDefinitions>

                <Grid.Resources>
                    <Style x:Key="PrimaryButton" TargetType="Button" BasedOn="{StaticResource MahApps.Styles.Button.Dialogs.Accent}">
                        <Setter Property="Margin" Value="8"/>
                        <Setter Property="Padding" Value="2"/>
                        <Setter Property="MinWidth" Value="75"/>
                        <Setter Property="HorizontalAlignment" Value="Right"/>
                    </Style>
                    <Style x:Key="SecondaryButton" TargetType="Button" BasedOn="{StaticResource MahApps.Styles.Button.Dialogs}">
                        <Setter Property="Margin" Value="8"/>
                        <Setter Property="Padding" Value="2"/>
                        <Setter Property="MinWidth" Value="75"/>
                        <Setter Property="HorizontalAlignment" Value="Right"/>
                    </Style>
                </Grid.Resources>
                
                <Button x:Name="OptionsUICancelButton" Content="Cancel" Click="OptionsUICancelButton_Click"
                        Grid.Column="1" Style="{StaticResource SecondaryButton}"/>
                
                <Button x:Name="OptionsUINextButton" Content="Next" Click="OptionsUINextButton_Click"
                        Grid.Column="2" Style="{StaticResource PrimaryButton}"/>
            </Grid>
        </Border>
    </Grid>
</mah:MetroWindow>
