<Window x:Class="UCP.MainWindow"
        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:UCP"
        mc:Ignorable="d"
        Title="Unofficial Patcher" Height="400" Width="500" ResizeMode="NoResize" WindowStyle="None">
    <Window.Background>
        <ImageBrush ImageSource="Graphics/background.jpg"
        Viewport="0,0,200,200"
        ViewportUnits="Absolute"
        TileMode="Tile"
        Stretch="None"/>
    </Window.Background>
    <Grid>
        <DockPanel VerticalAlignment="Top" Panel.ZIndex="100" x:Name="TitleBar" DockPanel.Dock="Top" Height="25" Background="{DynamicResource {x:Static SystemColors.WindowBrushKey}}">
            <Button x:Name="CloseButton" Content="X"
                    Click="CloseButton_Click"                 
                    DockPanel.Dock="Right"
                    Width="25" Background="White" BorderBrush="White"/>
            <Button x:Name="HelpButton" Content="?" 
                    Click="HelpButton_Click"
                    DockPanel.Dock="Right"
                    Width="25" Background="White" BorderBrush="White"/>
            <Button x:Name="MinButton" Content="-"
                    Click="MinimizeButton_Click"
                    DockPanel.Dock="Right" 
                    Width="25" BorderBrush="White" Background="White"/>
            <Image x:Name="Icon" Source="icon6.ico"
                    DockPanel.Dock="Left" 
                    Width="25" Height="20"/>

            <TextBlock VerticalAlignment="Center">Unofficial Crusader Patch 2.15b</TextBlock>
        </DockPanel>
        <Image Source="Graphics/frame.jpg" Margin="0,22.5,0,0" Stretch="UniformToFill" HorizontalAlignment="Center" VerticalAlignment="Top" Height="50" RenderTransformOrigin="0.5,0.5">
            <Image.RenderTransform>
                <ScaleTransform ScaleX="-1" ScaleY="-1"/>
            </Image.RenderTransform>
        </Image>
        <Image Source="Graphics/frame.jpg" Margin="0,25,0,0" Stretch="UniformToFill" HorizontalAlignment="Center" VerticalAlignment="Bottom" Height="50"/>
        <Grid x:Name="pathGrid" Visibility="Visible" HorizontalAlignment="Left" VerticalAlignment="Top" 
            Width="{Binding ActualWidth, RelativeSource = {RelativeSource AncestorType = {x:Type Grid}}}"
            Height="{Binding ActualHeight, RelativeSource ={RelativeSource AncestorType = {x:Type Grid}}}">

            <ScrollViewer Height="180" Margin="0,81,0,0" HorizontalAlignment="Center" VerticalAlignment="Top" Width="470">
                <TextBlock x:Name="linkLabel" ScrollViewer.VerticalScrollBarVisibility="Auto" TextAlignment="Center" TextWrapping="Wrap" FontSize="14" Background="#CCFFFFFF"/>
            </ScrollViewer>
            <TextBlock x:Name="pathBox" Background="#A5FFFFFF" HorizontalAlignment="Center" Height="60" Margin="10,279,13.6,0" VerticalAlignment="Top" Width="470" FontSize="12"/>
            <TextBox x:Name="pTextBoxPath" HorizontalAlignment="Left" Height="28" Margin="12,297,0,0" VerticalAlignment="Top" Width="400" MaxLines="1" Background="#99FFFFFF" FontSize="14"/>
            <Button x:Name="pButtonSearch" Content="Suchen" HorizontalAlignment="Right" Height="28" Margin="0,297,16.6,0" VerticalAlignment="Top" Width="54" Click="bPathSearch_Click"/>
            <Button x:Name="pButtonContinue" Content="Weiter" HorizontalAlignment="Right" Height="30" Margin="0,0,8,14" VerticalAlignment="Bottom" Width="120" Click="pButtonContinue_Click"/>
            <Button x:Name="pButtonCancel" Content="Abbrechen" HorizontalAlignment="Left" Height="30" Margin="8,0,0,14" VerticalAlignment="Bottom" Width="120" Click="pButtonCancel_Click"/>
            <Button x:Name="pButtonUninstall" Content="Deinstallieren" HorizontalAlignment="Center" Height="30" Margin="0,0,0,14" VerticalAlignment="Bottom" Width="120" Click="pButtonUninstall_Click"/>
        </Grid>
        <Grid x:Name="installGrid" Visibility="Hidden" HorizontalAlignment="Left" VerticalAlignment="Top" 
            Width="{Binding ActualWidth, RelativeSource = {RelativeSource AncestorType = {x:Type Grid}}}"
            Height="{Binding ActualHeight, RelativeSource ={RelativeSource AncestorType = {x:Type Grid}}}">

            <TabControl x:Name="tabControl" HorizontalAlignment="Center" Height="250" Margin="0,81,0,0" VerticalAlignment="Top" Width="470" Background="#CCFFFFFF" Focusable="true" SelectionChanged="tabControl_SelectionChanged"/>
            <ProgressBar x:Name="pbSetup" HorizontalAlignment="Center" Height="19" Margin="0,0,0,53" VerticalAlignment="Bottom" Width="468" Background="#99FFFFFF" Foreground="#FF832708"/>
            <Button x:Name="iButtonBack" Content="Zurück" HorizontalAlignment="Left" Height="30" Margin="8,0,0,13" VerticalAlignment="Bottom" Width="120" Click="iButtonBack_Click"/>
            <Button x:Name="iButtonInstall" Content="Installieren" HorizontalAlignment="Right" Height="30" Margin="0,0,8,13" VerticalAlignment="Bottom" Width="120" Click="iButtonInstall_Click"/>
            <Label x:Name="pbLabel" HorizontalAlignment="Center" Height="40" Margin="0,0,0,43" VerticalAlignment="Bottom" Width="468" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" FontWeight="Bold" FontSize="16"/>
            <TextBlock x:Name="changeHint" HorizontalAlignment="Center" Height="19" Margin="0,0,0,53" VerticalAlignment="Bottom" Width="468" Background="#99FFFFFF" Foreground="#FF832708" TextAlignment="Center"/>
        </Grid>
    </Grid>
</Window>
