diff options
Diffstat (limited to 'win/CS/HandBrakeWPF/Views')
-rw-r--r-- | win/CS/HandBrakeWPF/Views/Controls/AudioView.xaml | 86 | ||||
-rw-r--r-- | win/CS/HandBrakeWPF/Views/Controls/SubtitlesView.xaml | 84 | ||||
-rw-r--r-- | win/CS/HandBrakeWPF/Views/MainView.xaml | 13 |
3 files changed, 173 insertions, 10 deletions
diff --git a/win/CS/HandBrakeWPF/Views/Controls/AudioView.xaml b/win/CS/HandBrakeWPF/Views/Controls/AudioView.xaml index 512a1b91d..161546a41 100644 --- a/win/CS/HandBrakeWPF/Views/Controls/AudioView.xaml +++ b/win/CS/HandBrakeWPF/Views/Controls/AudioView.xaml @@ -2,7 +2,10 @@ 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:d="http://schemas.microsoft.com/expression/blend/2008"
+ xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity"
+ xmlns:cal="http://www.caliburnproject.org"
+ xmlns:NumericUpDown="clr-namespace:EagleBoost.Wpf.Presentation.Controls.NumericUpDown;assembly=EagleBoost.Wpf.Presentation"
mc:Ignorable="d">
<Grid>
<Grid.RowDefinitions>
@@ -22,9 +25,86 @@ <Button Content="Remove" Click="Remove" Grid.Column="1" Width="75" />
</Grid>
- <DataGrid Grid.Row="2" Margin="10" ItemsSource="{Binding AudioTracks, RelativeSource={RelativeSource AncestorType=UserControl}}" VerticalAlignment="Stretch" HorizontalAlignment="Stretch">
+ <ListBox Grid.Row="2" ItemsSource="{Binding AudioTracks, RelativeSource={RelativeSource AncestorType=UserControl}}"
+ SelectionMode="Extended" Background="LightGray" Margin="10,10,10,10">
+ <ListBox.ItemContainerStyle>
+ <Style TargetType="ListBoxItem">
+ <Setter Property="HorizontalContentAlignment" Value="Stretch"></Setter>
+ </Style>
+ </ListBox.ItemContainerStyle>
- </DataGrid>
+ <ListBox.ItemTemplate>
+ <DataTemplate>
+
+ <Grid HorizontalAlignment="Stretch">
+ <Grid.ColumnDefinitions>
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="*" />
+ <ColumnDefinition Width="Auto" />
+ </Grid.ColumnDefinitions>
+
+ <!-- Marker -->
+ <Image Source="../Images/Movies.png" Width="16" Height="16" Grid.Column="0" Margin="10,0,10,0" />
+
+ <!-- Settings -->
+ <Grid Grid.Column="1" HorizontalAlignment="Stretch">
+ <Grid.ColumnDefinitions>
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ </Grid.ColumnDefinitions>
+
+ <Grid.RowDefinitions>
+ <RowDefinition Height="28" />
+ <RowDefinition Height="28" />
+ </Grid.RowDefinitions>
+
+ <!-- Row 1-->
+
+ <TextBlock Text="Source" FontWeight="Bold" Grid.Column="0" VerticalAlignment="Center" />
+ <ComboBox Width="100" Grid.Column="1" Margin="5,0,5,0" Height="22" />
+ <TextBlock Text="Codec" FontWeight="Bold" Grid.Column="2" VerticalAlignment="Center" />
+ <ComboBox Width="100" Grid.Column="3" Margin="5,0,5,0" Height="22" />
+ <TextBlock Text="Bitrate" FontWeight="Bold" Grid.Column="4" VerticalAlignment="Center" />
+ <ComboBox Width="70" Grid.Column="5" Margin="5,0,5,0" Height="22" />
+ <TextBlock Text="Samplerate" FontWeight="Bold" Grid.Column="6" VerticalAlignment="Center" />
+ <ComboBox Width="70" Grid.Column="7" Margin="5,0,5,0" Height="22" />
+
+ <!-- Row 2-->
+ <TextBlock Text="Mixdown" FontWeight="Bold" Grid.Column="0" Grid.Row="1" VerticalAlignment="Center"/>
+ <ComboBox Width="100" Grid.Column="1" Margin="5,0,5,0" Grid.Row="1" Height="22" />
+ <TextBlock Text="DRC" FontWeight="Bold" Grid.Column="2" Grid.Row="1" VerticalAlignment="Center"/>
+ <NumericUpDown:NumericUpDown Width="45" Grid.Row="1" Grid.Column="3" HorizontalAlignment="Left" Margin="5,0,5,0" />
+ <TextBlock Text="Gain" FontWeight="Bold" Grid.Column="4" Grid.Row="1" VerticalAlignment="Center"/>
+ <NumericUpDown:NumericUpDown Width="45" Grid.Row="1" Grid.Column="5" HorizontalAlignment="Left" Margin="5,0,5,0" />
+
+ </Grid>
+
+ <!-- Delete -->
+ <Image Source="../Images/delete.png" Width="16" Height="16" Grid.Column="2" Margin="10,0,10,0">
+ <i:Interaction.Triggers>
+ <i:EventTrigger EventName="MouseDown">
+ <cal:ActionMessage MethodName="RemoveJob">
+ <cal:Parameter Value="{Binding}" />
+ </cal:ActionMessage>
+ </i:EventTrigger>
+ </i:Interaction.Triggers>
+ </Image>
+
+ </Grid>
+
+
+ </DataTemplate>
+ </ListBox.ItemTemplate>
+ </ListBox>
</Grid>
</UserControl>
diff --git a/win/CS/HandBrakeWPF/Views/Controls/SubtitlesView.xaml b/win/CS/HandBrakeWPF/Views/Controls/SubtitlesView.xaml index 8ae5e48d1..19c195e5d 100644 --- a/win/CS/HandBrakeWPF/Views/Controls/SubtitlesView.xaml +++ b/win/CS/HandBrakeWPF/Views/Controls/SubtitlesView.xaml @@ -3,6 +3,8 @@ 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:cal="http://www.caliburnproject.org"
+ xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity"
+ xmlns:NumericUpDown="clr-namespace:EagleBoost.Wpf.Presentation.Controls.NumericUpDown;assembly=EagleBoost.Wpf.Presentation"
mc:Ignorable="d">
<Grid>
<Grid.RowDefinitions>
@@ -24,9 +26,87 @@ <Button Content="Import SRT" Click="ImportSrt" Grid.Column="2" Width="75" />
</Grid>
- <DataGrid Grid.Row="2" Margin="10" ItemsSource="{Binding SubtitleTracks, RelativeSource={RelativeSource AncestorType=UserControl}}" VerticalAlignment="Stretch" HorizontalAlignment="Stretch">
+ <ListBox Grid.Row="2" ItemsSource="{Binding SubtitleTracks, RelativeSource={RelativeSource AncestorType=UserControl}}"
+ SelectionMode="Extended" Background="LightGray" Margin="10,10,10,10">
+ <ListBox.ItemContainerStyle>
+ <Style TargetType="ListBoxItem">
+ <Setter Property="HorizontalContentAlignment" Value="Stretch"></Setter>
+ </Style>
+ </ListBox.ItemContainerStyle>
- </DataGrid>
+ <ListBox.ItemTemplate>
+ <DataTemplate>
+ <Grid HorizontalAlignment="Stretch">
+ <Grid.ColumnDefinitions>
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="*" />
+ <ColumnDefinition Width="Auto" />
+ </Grid.ColumnDefinitions>
+
+ <!-- Marker -->
+ <Image Source="../Images/Movies.png" Width="16" Height="16" Grid.Column="0" Margin="10,0,10,0" />
+
+ <!-- Settings -->
+ <Grid Grid.Column="1" HorizontalAlignment="Stretch">
+ <Grid.ColumnDefinitions>
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="Auto" />
+ </Grid.ColumnDefinitions>
+
+ <Grid.RowDefinitions>
+ <RowDefinition Height="28" />
+ <RowDefinition Height="28" />
+ </Grid.RowDefinitions>
+
+ <!-- Row 1-->
+
+ <TextBlock Text="Source" FontWeight="Bold" Grid.Column="0" VerticalAlignment="Center" />
+ <ComboBox Width="100" Grid.Column="1" Margin="5,0,5,0" Height="22" />
+ <TextBlock Text="Forced Only" FontWeight="Bold" Grid.Column="2" VerticalAlignment="Center" />
+ <CheckBox Grid.Column="3" VerticalAlignment="Center" Margin="5,0,5,0"/>
+ <TextBlock Text="Burn In" FontWeight="Bold" Grid.Column="4" VerticalAlignment="Center" />
+ <CheckBox Grid.Column="5" VerticalAlignment="Center" Margin="5,0,5,0"/>
+ <TextBlock Text="Default" FontWeight="Bold" Grid.Column="6" VerticalAlignment="Center" />
+ <CheckBox Grid.Column="7" VerticalAlignment="Center" Margin="5,0,5,0"/>
+
+ <!-- Row 2-->
+ <TextBlock Text="Language" FontWeight="Bold" Grid.Column="0" Grid.Row="1" VerticalAlignment="Center"/>
+ <ComboBox Width="100" Grid.Column="1" Margin="5,0,5,0" Grid.Row="1" Height="22" />
+ <TextBlock Text="Char Code" FontWeight="Bold" Grid.Column="2" Grid.Row="1" VerticalAlignment="Center"/>
+ <ComboBox Width="100" Grid.Column="3" Grid.Row="1" Margin="5,0,5,0" Height="22" />
+ <TextBlock Text="Offset" FontWeight="Bold" Grid.Column="4" Grid.Row="1" VerticalAlignment="Center"/>
+ <NumericUpDown:NumericUpDown Width="45" Grid.Row="1" Grid.Column="5" HorizontalAlignment="Left" Margin="5,0,5,0" />
+
+ </Grid>
+
+ <!-- Delete -->
+ <Image Source="../Images/delete.png" Width="16" Height="16" Grid.Column="2" Margin="10,0,10,0">
+ <i:Interaction.Triggers>
+ <i:EventTrigger EventName="MouseDown">
+ <cal:ActionMessage MethodName="RemoveJob">
+ <cal:Parameter Value="{Binding}" />
+ </cal:ActionMessage>
+ </i:EventTrigger>
+ </i:Interaction.Triggers>
+ </Image>
+
+ </Grid>
+
+
+ </DataTemplate>
+ </ListBox.ItemTemplate>
+ </ListBox>
+
+
</Grid>
</UserControl>
diff --git a/win/CS/HandBrakeWPF/Views/MainView.xaml b/win/CS/HandBrakeWPF/Views/MainView.xaml index cd4e5ccc4..4fb29ae7c 100644 --- a/win/CS/HandBrakeWPF/Views/MainView.xaml +++ b/win/CS/HandBrakeWPF/Views/MainView.xaml @@ -173,11 +173,14 @@ <Label Content="Output Settings (Preset: None)" FontWeight="Bold" />
<StackPanel Orientation="Horizontal">
<Label Content="Container" Margin="8,0,0,0" />
- <ComboBox Name="Container" Margin="8,0,0,0" MinWidth="100" SelectedItem="{Binding Path=CurrentTask.OutputFormat}" />
-
- <CheckBox Name="LargeFileMp4" Content="Large File Size" IsChecked="{Binding Path=CurrentTask.LargeFile}" VerticalAlignment="Center" Margin="8,0,0,0" />
- <CheckBox Name="WebOptimized" Content="Web Optimized" IsChecked="{Binding Path=CurrentTask.OptimizeMP4}" VerticalAlignment="Center" Margin="8,0,0,0" />
- <CheckBox Name="iPod5G" Content="iPod 5G Support" IsChecked="{Binding Path=CurrentTask.IPod5GSupport}" VerticalAlignment="Center" Margin="8,0,0,0" />
+ <ComboBox Name="Container" Margin="8,0,0,0" MinWidth="100" ItemsSource="{Binding OutputFormats}" SelectedItem="{Binding SelectedOutputFormat}" />
+
+ <CheckBox Name="LargeFileMp4" Content="Large File Size" IsChecked="{Binding Path=CurrentTask.LargeFile}"
+ Visibility="{Binding IsMkv, Converter={StaticResource boolToVisConverter}, ConverterParameter=true}" VerticalAlignment="Center" Margin="8,0,0,0" />
+ <CheckBox Name="WebOptimized" Content="Web Optimized" IsChecked="{Binding Path=CurrentTask.OptimizeMP4}"
+ Visibility="{Binding IsMkv, Converter={StaticResource boolToVisConverter}, ConverterParameter=true}" VerticalAlignment="Center" Margin="8,0,0,0" />
+ <CheckBox Name="iPod5G" Content="iPod 5G Support" IsChecked="{Binding Path=CurrentTask.IPod5GSupport}"
+ Visibility="{Binding IsMkv, Converter={StaticResource boolToVisConverter}, ConverterParameter=true}" VerticalAlignment="Center" Margin="8,0,0,0" />
</StackPanel>
</StackPanel>
|