74 lines
3.4 KiB
XML
74 lines
3.4 KiB
XML
<Window x:Class="GifResizer.Views.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:gif="http://wpfanimatedgif.codeplex.com"
|
|
mc:Ignorable="d"
|
|
Title="Gif resizer" Height="480" Width="640"
|
|
ResizeMode="NoResize">
|
|
|
|
<Grid>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="3*"/>
|
|
<RowDefinition Height="1*"/>
|
|
</Grid.RowDefinitions>
|
|
|
|
<Border Grid.Row="0" BorderBrush="Gray"
|
|
BorderThickness="1"
|
|
CornerRadius="5"
|
|
Margin="10 10 10 5">
|
|
<Grid Style="{StaticResource DarkGrid}">
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="3*"/>
|
|
<RowDefinition Height="1*"/>
|
|
</Grid.RowDefinitions>
|
|
|
|
<Image gif:ImageBehavior.AnimatedSource="{Binding FilePath}"
|
|
Stretch="Uniform"
|
|
Visibility="{Binding FilePath}"/>
|
|
|
|
<Button Grid.Row="0"
|
|
Style="{StaticResource LinkButtonStyle}"
|
|
Click="BrowseButton_Click"
|
|
HorizontalAlignment="Center"
|
|
VerticalAlignment="Center">
|
|
<TextBlock Text="Browse files"
|
|
Width="Auto"
|
|
Height="Auto"
|
|
TextDecorations="Underline"/>
|
|
</Button>
|
|
<TextBlock Grid.Row="1"
|
|
Margin="0,0,0,5"
|
|
Text="{Binding FilePath,
|
|
TargetNullValue=No file selected,
|
|
FallbackValue=Gif filepath...}"
|
|
Width="Auto"
|
|
Height="Auto"
|
|
HorizontalAlignment="Left"
|
|
VerticalAlignment="Center"/>
|
|
</Grid>
|
|
</Border>
|
|
|
|
<Border Grid.Row="1" BorderBrush="Gray"
|
|
BorderThickness="1"
|
|
CornerRadius="5"
|
|
Padding="5"
|
|
Margin="10 5 10 10">
|
|
<StackPanel Orientation="Vertical" HorizontalAlignment="Center" VerticalAlignment="Center">
|
|
<StackPanel Orientation="Horizontal">
|
|
<CheckBox Content="112x112" IsChecked="True" Margin="10"/>
|
|
<CheckBox Content="500x500" IsChecked="True" Margin="10"/>
|
|
<CheckBox Content="1000x1000" IsChecked="True" Margin="10"/>
|
|
</StackPanel>
|
|
<Button
|
|
Style="{StaticResource ButtonStyle}"
|
|
Content="Resize"
|
|
Click="ResizeButton_Click"
|
|
HorizontalAlignment="Center"
|
|
VerticalAlignment="Center"/>
|
|
</StackPanel>
|
|
</Border>
|
|
</Grid>
|
|
</Window>
|