<Window x:Class="StyletIntegrationTests.ShellView"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:s="https://github.com/canton7/Stylet"
        Title="ShellView" Height="500" Width="500">
    <DockPanel LastChildFill="False">
        <GroupBox DockPanel.Dock="Top" Header="ShowDialog and DialogResult" Padding="10">
            <StackPanel Orientation="Horizontal">
                <Button Command="{s:Action ShowDialogAndDialogResult}">Show Dialog</Button>
                <TextBlock Margin="50,0,0,0">Result: </TextBlock>
                <TextBlock Margin="10,0,0,0" Text="{Binding ShowDialogAndDialogResultDialogResult}"/>
            </StackPanel>
        </GroupBox>
        
        <GroupBox DockPanel.Dock="Top" Header="Window Lifecycle" Padding="10">
            <Button Command="{s:Action ShowWindowLifecycle}">Show Window</Button>
        </GroupBox>

        <GroupBox DockPanel.Dock="Top" Header="OnUnhandledException" Padding="10">
            <DockPanel>
                <TextBlock DockPanel.Dock="Top" TextWrapping="WrapWithOverflow">Verify that pressing the button below shows a dialog, containing the message 'Unhandled Exception: Hello'.</TextBlock>
                <Button DockPanel.Dock="Top" Command="{s:Action ThrowException}">Throw Exception</Button>
            </DockPanel>
        </GroupBox>

        <GroupBox DockPanel.Dock="Top" Header="Dispatcher" Padding="10">
            <DockPanel>
                <TextBlock DockPanel.Dock="Top" TextWrapping="WrapWithOverflow">Verify that pressing the button shows a MessageBox saying 'Success'.</TextBlock>
                <Button DockPanel.Dock="Top" Command="{s:Action TestDispatcher}">Test Dispatcher</Button>
            </DockPanel>
        </GroupBox>
    </DockPanel>
</Window>
