summaryrefslogtreecommitdiffstats
path: root/win/CS/HandBrakeWPF/Views
diff options
context:
space:
mode:
Diffstat (limited to 'win/CS/HandBrakeWPF/Views')
-rw-r--r--win/CS/HandBrakeWPF/Views/Queue/QueueTwoContent.xaml67
-rw-r--r--win/CS/HandBrakeWPF/Views/Queue/QueueTwoContent.xaml.cs13
-rw-r--r--win/CS/HandBrakeWPF/Views/QueueView.xaml2
3 files changed, 70 insertions, 12 deletions
diff --git a/win/CS/HandBrakeWPF/Views/Queue/QueueTwoContent.xaml b/win/CS/HandBrakeWPF/Views/Queue/QueueTwoContent.xaml
index 930533987..66e8d3ab4 100644
--- a/win/CS/HandBrakeWPF/Views/Queue/QueueTwoContent.xaml
+++ b/win/CS/HandBrakeWPF/Views/Queue/QueueTwoContent.xaml
@@ -52,15 +52,9 @@
</Grid.ColumnDefinitions>
<TextBlock Text="{x:Static Properties:Resources.MainView_ShowQueue}" FontSize="28" VerticalAlignment="Center" FontFamily="Segoe UI Light" Margin="10,0,0,0" />
-
</Grid>
- <StackPanel Grid.Row="1" Margin="20,5,10,0" Visibility="{Binding IsNewQueueVisible, Converter={StaticResource boolToVisConverter}}">
- <TextBlock Text="{Binding JobsPending}" TextWrapping="WrapWithOverflow" TextTrimming="CharacterEllipsis" />
- <TextBlock Text="{Binding JobStatus}" TextWrapping="WrapWithOverflow" TextTrimming="CharacterEllipsis"/>
- </StackPanel>
-
- <Grid Grid.Row="2" Margin="0,10,0,0">
+ <Grid Grid.Row="2" Margin="0,0,0,0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="3*" MaxWidth="600" x:Name="leftTabPanel" />
<ColumnDefinition Width="5*" x:Name="rightTabPanel" />
@@ -69,11 +63,32 @@
<Border>
<Grid>
<Grid.RowDefinitions>
+ <RowDefinition Height="Auto" />
<RowDefinition Height="*" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
- <ListBox Tag="{Binding}" x:Name="queueJobs" Grid.Row="0" Margin="10,0,5,0"
+ <Grid Grid.Row="0" HorizontalAlignment="Stretch" Margin="15,0,5,5">
+
+ <Grid.RowDefinitions>
+ <RowDefinition Height="Auto" />
+ <RowDefinition Height="Auto" />
+ </Grid.RowDefinitions>
+
+ <Grid.ColumnDefinitions>
+ <ColumnDefinition Width="*" />
+ <ColumnDefinition Width="Auto" />
+ </Grid.ColumnDefinitions>
+
+ <TextBlock Text="{Binding JobsPending}" Grid.Row="1" Grid.Column="0" TextWrapping="WrapWithOverflow" TextTrimming="CharacterEllipsis"/>
+
+ <StackPanel Grid.Row="1" Grid.Column="1" Orientation="Horizontal">
+ <Button Content="^" Width="20" Height="20" Margin="0" cal:Message.Attach="[Event Click] = [Action MoveUp]" />
+ <Button Content="v" Width="20" Height="20" Margin="5,0,0,0" cal:Message.Attach="[Event Click] = [Action MoveDown]" />
+ </StackPanel>
+ </Grid>
+
+ <ListBox Tag="{Binding}" x:Name="queueJobs" Grid.Row="1" Margin="10,0,5,0"
dd:DragDrop.DropHandler="{Binding}"
dd:DragDrop.IsDragSource="True"
@@ -212,7 +227,7 @@
</ListBox.ItemTemplate>
</ListBox>
- <Border BorderThickness="1,0,1,1" BorderBrush="DarkGray" Grid.Row="1" Margin="10,0,5,10" SnapsToDevicePixels="True" >
+ <Border BorderThickness="1,0,1,1" BorderBrush="DarkGray" Grid.Row="2" Margin="10,0,5,10" SnapsToDevicePixels="True" >
<Menu HorizontalAlignment="Center" VerticalAlignment="Center" Background="Transparent"
AutomationProperties.Name="{x:Static Properties:Resources.QueueView_WhenDone}">
<MenuItem>
@@ -326,9 +341,41 @@
</i:EventTrigger>
</i:Interaction.Triggers>
</Button>
+
+
+ <Button x:Name="queueOptionsDropButton" Margin="10,0,0,0" Click="QueueOptionsDropButton_OnClick"
+ AutomationProperties.Name="{x:Static Properties:Resources.QueueView_Options}" IsEnabled="{Binding CanPerformActionOnSource}">
+ <Button.Content>
+ <StackPanel Orientation="Horizontal">
+ <Image Width="20" Height="20" VerticalAlignment="Center" Margin="0,0,5,0"
+ Source="../Images/Advanced.png">
+ </Image>
+
+ <TextBlock Margin="0,0,5,0" Padding="0"
+ VerticalAlignment="Center"
+ Text="{x:Static Properties:Resources.QueueView_Options}" />
+
+ <Path Height="5" Margin="2,2,0,0" VerticalAlignment="Center" HorizontalAlignment="Center"
+ Data="M 0 0 L 4 4 L 8 0 Z"
+ Fill="{DynamicResource GlyphBrush}" x:Name="dropdownArrowPreset" />
+ </StackPanel>
+ </Button.Content>
+
+ <Button.ContextMenu>
+ <ContextMenu cal:Action.TargetWithoutContext="{Binding DataContext, RelativeSource={RelativeSource Self}}">
+ <MenuItem Header="{x:Static Properties:Resources.QueueView_PlayMediaFile}" cal:Message.Attach="[Event Click] = [Action PlayFile]" />
+ <Separator />
+ <MenuItem Header="{x:Static Properties:Resources.QueueView_OpenSourceDir}" cal:Message.Attach="[Event Click] = [Action OpenSourceDir]" />
+ <MenuItem Header="{x:Static Properties:Resources.QueueView_OpenDestDir}" cal:Message.Attach="[Event Click] = [Action OpenDestDir]" />
+ </ContextMenu>
+ </Button.ContextMenu>
+ </Button>
</StackPanel>
- <Grid Style="{StaticResource LongToolTipHolder}" Margin="0,5,0,0" >
+ <TextBlock Text="{Binding JobStatus}" Visibility="{Binding IsJobStatusVisible, Converter={StaticResource boolToVisConverter}}"
+ Margin="0,15,10,5" TextWrapping="WrapWithOverflow" TextTrimming="CharacterEllipsis" />
+
+ <Grid Style="{StaticResource LongToolTipHolder}" Margin="0,10,0,0" >
<Grid.Resources>
<Style TargetType="TextBlock" BasedOn="{StaticResource {x:Type TextBlock}}">
<Setter Property="Margin" Value="0,5,0,5" />
diff --git a/win/CS/HandBrakeWPF/Views/Queue/QueueTwoContent.xaml.cs b/win/CS/HandBrakeWPF/Views/Queue/QueueTwoContent.xaml.cs
index 691854b74..e6fe29971 100644
--- a/win/CS/HandBrakeWPF/Views/Queue/QueueTwoContent.xaml.cs
+++ b/win/CS/HandBrakeWPF/Views/Queue/QueueTwoContent.xaml.cs
@@ -25,7 +25,7 @@ namespace HandBrakeWPF.Views.Queue
private QueueTask mouseActiveQueueTask;
/// <summary>
- /// Initializes a new instance of the <see cref="Queue2View"/> class.
+ /// Initializes a new instance of the <see cref="QueueTwoContent"/> class.
/// </summary>
public QueueTwoContent()
{
@@ -93,5 +93,16 @@ namespace HandBrakeWPF.Views.Queue
{
((QueueViewModel)this.DataContext).OpenDestinationDirectory(this.mouseActiveQueueTask);
}
+
+ private void QueueOptionsDropButton_OnClick(object sender, RoutedEventArgs e)
+ {
+ var button = sender as FrameworkElement;
+ if (button != null && button.ContextMenu != null)
+ {
+ button.ContextMenu.PlacementTarget = button;
+ button.ContextMenu.Placement = System.Windows.Controls.Primitives.PlacementMode.Bottom;
+ button.ContextMenu.IsOpen = true;
+ }
+ }
}
}
diff --git a/win/CS/HandBrakeWPF/Views/QueueView.xaml b/win/CS/HandBrakeWPF/Views/QueueView.xaml
index 39a81a760..33710d000 100644
--- a/win/CS/HandBrakeWPF/Views/QueueView.xaml
+++ b/win/CS/HandBrakeWPF/Views/QueueView.xaml
@@ -176,7 +176,7 @@
<StackPanel Grid.Row="1" Margin="10,20,10,0">
<TextBlock Text="{Binding JobsPending}" TextWrapping="WrapWithOverflow" TextTrimming="CharacterEllipsis" />
- <TextBlock Text="{Binding JobStatus}" TextWrapping="WrapWithOverflow" TextTrimming="CharacterEllipsis"/>
+ <TextBlock Text="{Binding JobStatus}" Visibility="{Binding IsJobStatusVisible, Converter={StaticResource boolToVisConverter}}" TextWrapping="WrapWithOverflow" TextTrimming="CharacterEllipsis"/>
</StackPanel>
<ListBox Grid.Row="2" Tag="{Binding}" x:Name="queueJobs"