summaryrefslogtreecommitdiffstats
path: root/win/CS/HandBrakeWPF/Views
diff options
context:
space:
mode:
authorsr55 <[email protected]>2012-06-26 20:46:19 +0000
committersr55 <[email protected]>2012-06-26 20:46:19 +0000
commita47da7b31e9150888bcd8a495841be00f97b1114 (patch)
treefdb3ef05132ce0c34891641a2ce498d70ed9da4f /win/CS/HandBrakeWPF/Views
parentbe14d23c567b88a857df6f91f5c8a95c8c8e17fa (diff)
WinGui: Another set of assorted fixes and UI tweaks.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4781 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/CS/HandBrakeWPF/Views')
-rw-r--r--win/CS/HandBrakeWPF/Views/QueueView.xaml11
-rw-r--r--win/CS/HandBrakeWPF/Views/ShellView.xaml.cs19
2 files changed, 22 insertions, 8 deletions
diff --git a/win/CS/HandBrakeWPF/Views/QueueView.xaml b/win/CS/HandBrakeWPF/Views/QueueView.xaml
index e505800fc..7ef652b29 100644
--- a/win/CS/HandBrakeWPF/Views/QueueView.xaml
+++ b/win/CS/HandBrakeWPF/Views/QueueView.xaml
@@ -146,11 +146,11 @@
<ListBox.ContextMenu>
<ContextMenu>
- <MenuItem cal:Message.Attach="[Event Click] = [Action Import]" Header="Import Queue" />
- <MenuItem cal:Message.Attach="[Event Click] = [Action Export]" Header="Export Queue" />
- <Separator />
<MenuItem cal:Message.Attach="[Event Click] = [Action Clear]" Header="Clear" />
<MenuItem cal:Message.Attach="[Event Click] = [Action ClearCompleted]" Header="Clear Completed" />
+ <Separator />
+ <MenuItem cal:Message.Attach="[Event Click] = [Action Import]" Header="Import Queue" />
+ <MenuItem cal:Message.Attach="[Event Click] = [Action Export]" Header="Export Queue" />
</ContextMenu>
</ListBox.ContextMenu>
@@ -245,11 +245,6 @@
<TextBlock FontWeight="Bold" Text="Destination: " />
<TextBlock Text="{Binding Task.Destination, Converter={StaticResource filePathToFilenameConverter}}" />
</StackPanel>
-
- <StackPanel Orientation="Horizontal">
- <TextBlock FontWeight="Bold" Text="Status: " />
- <TextBlock Text="{Binding Status, Converter={StaticResource enumComboConverter}}" />
- </StackPanel>
</StackPanel>
<!-- Delete -->
diff --git a/win/CS/HandBrakeWPF/Views/ShellView.xaml.cs b/win/CS/HandBrakeWPF/Views/ShellView.xaml.cs
index cc6b381de..6b291702d 100644
--- a/win/CS/HandBrakeWPF/Views/ShellView.xaml.cs
+++ b/win/CS/HandBrakeWPF/Views/ShellView.xaml.cs
@@ -11,6 +11,8 @@ namespace HandBrakeWPF.Views
{
using System.Windows;
+ using HandBrakeWPF.ViewModels.Interfaces;
+
/// <summary>
/// Interaction logic for ShellView.xaml
/// </summary>
@@ -23,5 +25,22 @@ namespace HandBrakeWPF.Views
{
this.InitializeComponent();
}
+
+ /// <summary>
+ /// Check with the user before closing.
+ /// </summary>
+ /// <param name="e">
+ /// The CancelEventArgs.
+ /// </param>
+ protected override void OnClosing(System.ComponentModel.CancelEventArgs e)
+ {
+ bool canClose = ((IShellViewModel)this.DataContext).CanClose();
+ if (!canClose)
+ {
+ e.Cancel = true;
+ }
+
+ base.OnClosing(e);
+ }
}
}