<Window x:Class=" Valg.EVA.Skanning.UserInterfaceElements.DatabaseVerifier.SplashWindow"
             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:animatedGif="clr-namespace:Valg.EVA.Skanning.UserInterfaceElements.AnimatedGif"
             xmlns:local="clr-namespace:Valg.EVA.Skanning.UserInterfaceElements.DatabaseVerifier"
             mc:Ignorable="d" 
                MinWidth="530"
                MinHeight="252"
                Icon="/Valg.EVA.Skanning.Assets;component/Images/Icons/EvaScan.ico"
            WindowStartupLocation="CenterScreen"
            ShowInTaskbar="False"
            Style="{DynamicResource PopUpWindowInformation}"      
            d:DesignHeight="300" d:DesignWidth="300"
        d:DataContext="{d:DesignInstance d:Type=local:SplashWindowViewModel}">
    <Window.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <ResourceDictionary Source="/Valg.EVA.Skanning.Assets;component/ResourceDictionaries/ResourceLibrary.xaml"/>
            </ResourceDictionary.MergedDictionaries>
        </ResourceDictionary>
    </Window.Resources>
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="*"/>
            <RowDefinition Height="*"/>
            <RowDefinition Height="*"/>
            <RowDefinition Height="*"/>
            <RowDefinition Height="*"/>
        </Grid.RowDefinitions>
        <Image Grid.Row="0" Stretch="None" Source="/Valg.EVA.Skanning.Assets;component/Images/ElectionLogo.png" HorizontalAlignment="Center">
        </Image>
        <TextBlock Grid.Row="1" VerticalAlignment="Center" 
                   HorizontalAlignment="Center" TextWrapping="Wrap" Style="{StaticResource TextBlockMediumHeader}"  
                   Text="{Binding DescriptionText}" Margin="0,25,0,25" />
        <TextBlock Grid.Row="2" VerticalAlignment="Center" 
                   HorizontalAlignment="Center" TextWrapping="Wrap" Style="{StaticResource TextBlockMediumHeader}"  
                   Text="{Binding SubDescriptionText}" Margin="0,25,0,25" />
        <Image Grid.Row="3" Stretch="None" animatedGif:ImageBehavior.AnimatedSource="/Valg.EVA.Skanning.Assets;component/Images/transferring2.gif" Visibility="{Binding ShowProgressIndicator, Converter={StaticResource BooleanToVisibilityConverter}}"/>
        <ScrollViewer Grid.Row="3" Visibility="{Binding ShowErrorDetails, Converter={StaticResource BooleanToVisibilityConverter}}">
            <TextBox Text="{Binding ErrorDetailsText}" Height="200" Width="500" IsReadOnly="True" ScrollViewer.HorizontalScrollBarVisibility="Auto" ScrollViewer.VerticalScrollBarVisibility="Auto"/>
        </ScrollViewer>
        <Button Grid.Row="4" Style="{StaticResource RedButtonCancel}" Content="{Binding ExitApplicationText}" Height="49" Width="200" Visibility="{Binding ShowExitButton, Converter={StaticResource BooleanToVisibilityConverter}}" Click="ExitApplication"/>
        </Grid>
</Window>

