]> granicus.if.org Git - handbrake/commitdiff
WinGui: Just some prototype code for safe keeping. Not currently used.
authorsr55 <sr55.hb@outlook.com>
Sun, 20 Jan 2013 14:21:58 +0000 (14:21 +0000)
committersr55 <sr55.hb@outlook.com>
Sun, 20 Jan 2013 14:21:58 +0000 (14:21 +0000)
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@5185 b64f7644-9d1e-0410-96f1-a4d463321fa5

12 files changed:
win/CS/HandBrake.ApplicationServices/Parsing/Title.cs
win/CS/HandBrake.Interop/HandBrakeInterop/SourceData/Title.cs
win/CS/HandBrakeWPF/HandBrakeWPF.csproj
win/CS/HandBrakeWPF/Model/SelectionTitle.cs [new file with mode: 0644]
win/CS/HandBrakeWPF/Startup/CastleBootstrapper.cs
win/CS/HandBrakeWPF/ViewModels/Interfaces/IQueueSelectionViewModel.cs [new file with mode: 0644]
win/CS/HandBrakeWPF/ViewModels/MainViewModel.cs
win/CS/HandBrakeWPF/ViewModels/QueueSelectionViewModel.cs [new file with mode: 0644]
win/CS/HandBrakeWPF/Views/AddPresetView.xaml.cs
win/CS/HandBrakeWPF/Views/MainView.xaml
win/CS/HandBrakeWPF/Views/QueueSelectionView.xaml [new file with mode: 0644]
win/CS/HandBrakeWPF/Views/QueueSelectionView.xaml.cs [new file with mode: 0644]

index 04d00c1f2fecaacd2e1dea7c15585b77e46bc04d..f834c4fa9c547cd43a8d71774d554ad004fb9138 100644 (file)
@@ -16,9 +16,6 @@ namespace HandBrake.ApplicationServices.Parsing
     using System.Linq;\r
     using System.Text.RegularExpressions;\r
 \r
-    using Caliburn.Micro;\r
-\r
-    using HandBrake.ApplicationServices.Services.Interfaces;\r
     using HandBrake.Interop.Model;\r
 \r
     using Size = System.Drawing.Size;\r
index 344759c1d9df8518fc30dcfb03f0757e9b261b8a..fbe8e8532966bee42e6c9086d481cc7c5c8bce02 100644 (file)
@@ -19,9 +19,20 @@ namespace HandBrake.Interop.SourceData
        /// </summary>\r
        public class Title\r
        {\r
-               private readonly List<AudioTrack> audioTracks;\r
-               private readonly List<Chapter> chapters;\r
-               private readonly List<Subtitle> subtitles;\r
+           /// <summary>\r
+           /// The audio tracks.\r
+           /// </summary>\r
+           private readonly List<AudioTrack> audioTracks;\r
+\r
+           /// <summary>\r
+           /// The chapters.\r
+           /// </summary>\r
+           private readonly List<Chapter> chapters;\r
+\r
+           /// <summary>\r
+           /// The subtitles.\r
+           /// </summary>\r
+           private readonly List<Subtitle> subtitles;\r
                \r
                /// <summary>\r
                /// Initializes a new instance of the Title class.\r
index a7076bf6e72c7536750bba9d8188ac2f4b64d461..e0d2e76960f05920016e7983e71c13de332a8af5 100644 (file)
     <Compile Include="Helpers\GrayscaleImage.cs" />\r
     <Compile Include="Helpers\GrowlCommunicator.cs" />\r
     <Compile Include="Model\OptionsTab.cs" />\r
+    <Compile Include="Model\SelectionTitle.cs" />\r
     <Compile Include="Services\DriveDetectService.cs" />\r
     <Compile Include="Services\EncodeServiceWrapper.cs" />\r
     <Compile Include="Services\Interfaces\IDriveDetectService.cs" />\r
     <Compile Include="Services\NotificationService.cs" />\r
     <Compile Include="Services\ScanServiceWrapper.cs" />\r
     <Compile Include="Services\UpdateService.cs" />\r
+    <Compile Include="ViewModels\Interfaces\IQueueSelectionViewModel.cs" />\r
+    <Compile Include="ViewModels\QueueSelectionViewModel.cs" />\r
+    <Compile Include="Views\QueueSelectionView.xaml.cs">\r
+      <DependentUpon>QueueSelectionView.xaml</DependentUpon>\r
+    </Compile>\r
     <Compile Include="Views\ShellView.xaml.cs">\r
       <DependentUpon>ShellView.xaml</DependentUpon>\r
     </Compile>\r
       <SubType>Designer</SubType>\r
       <Generator>MSBuild:Compile</Generator>\r
     </Page>\r
+    <Page Include="Views\QueueSelectionView.xaml">\r
+      <Generator>MSBuild:Compile</Generator>\r
+      <SubType>Designer</SubType>\r
+    </Page>\r
     <Page Include="Views\ShellView.xaml">\r
       <SubType>Designer</SubType>\r
       <Generator>MSBuild:Compile</Generator>\r
diff --git a/win/CS/HandBrakeWPF/Model/SelectionTitle.cs b/win/CS/HandBrakeWPF/Model/SelectionTitle.cs
new file mode 100644 (file)
index 0000000..63ad477
--- /dev/null
@@ -0,0 +1,88 @@
+// --------------------------------------------------------------------------------------------------------------------\r
+// <copyright file="SelectionTitle.cs" company="HandBrake Project (http://handbrake.fr)">\r
+//   This file is part of the HandBrake source code - It may be used under the terms of the GNU General Public License.\r
+// </copyright>\r
+// <summary>\r
+//   TODO: Update summary.\r
+// </summary>\r
+// --------------------------------------------------------------------------------------------------------------------\r
+\r
+namespace HandBrakeWPF.Model\r
+{\r
+    using Caliburn.Micro;\r
+\r
+    using HandBrake.ApplicationServices.Parsing;\r
+\r
+    /// <summary>\r
+    /// A model for the multiple selection window for adding to the queue.\r
+    /// </summary>\r
+    public class SelectionTitle : PropertyChangedBase\r
+    {\r
+        /// <summary>\r
+        /// The source name.\r
+        /// </summary>\r
+        private readonly string sourceName;\r
+\r
+        /// <summary>\r
+        /// The is selected.\r
+        /// </summary>\r
+        private bool isSelected;\r
+\r
+        /// <summary>\r
+        /// Initializes a new instance of the <see cref="SelectionTitle"/> class.\r
+        /// </summary>\r
+        /// <param name="title">\r
+        /// The title.\r
+        /// </param>\r
+        /// <param name="sourceName">\r
+        /// The source Name.\r
+        /// </param>\r
+        public SelectionTitle(Title title, string sourceName)\r
+        {\r
+            this.sourceName = sourceName;\r
+            this.Title = title;\r
+        }\r
+\r
+        /// <summary>\r
+        /// Gets the source name.\r
+        /// </summary>\r
+        public string SourceName\r
+        {\r
+            get\r
+            {\r
+                return !string.IsNullOrEmpty(Title.SourceName) ? Title.SourceName : sourceName;\r
+            }\r
+        }\r
+\r
+        /// <summary>\r
+        /// Gets or sets the end point.\r
+        /// </summary>\r
+        public int EndPoint { get; set; }\r
+\r
+        /// <summary>\r
+        /// Gets or sets a value indicating whether is selected.\r
+        /// </summary>\r
+        public bool IsSelected\r
+        {\r
+            get\r
+            {\r
+                return this.isSelected;\r
+            }\r
+            set\r
+            {\r
+                this.isSelected = value;\r
+                this.NotifyOfPropertyChange(() => this.IsSelected);\r
+            }\r
+        }\r
+\r
+        /// <summary>\r
+        /// Gets or sets the start point.\r
+        /// </summary>\r
+        public int StartPoint { get; set; }\r
+\r
+        /// <summary>\r
+        /// Gets or sets the title.\r
+        /// </summary>\r
+        public Title Title { get; set; }\r
+    }\r
+}
\ No newline at end of file
index 5b06c97ba8893aab5b918413a3419071200ae3c2..97930ba4d1e38c2da162b9d164e07fcbddd82ed2 100644 (file)
@@ -78,6 +78,8 @@ namespace HandBrakeWPF.Startup
             this.windsorContainer.Register(Component.For<IOptionsViewModel>().ImplementedBy<OptionsViewModel>().LifeStyle.Is(LifestyleType.Singleton));\r
             this.windsorContainer.Register(Component.For<IUpdateVersionService>().ImplementedBy<UpdateVersionService>().LifeStyle.Is(LifestyleType.Singleton));\r
             this.windsorContainer.Register(Component.For<ITitleSpecificViewModel>().ImplementedBy<TitleSpecificViewModel>().LifeStyle.Is(LifestyleType.Singleton));\r
+            this.windsorContainer.Register(Component.For<IQueueSelectionViewModel>().ImplementedBy<QueueSelectionViewModel>().LifeStyle.Is(LifestyleType.Singleton));\r
+            \r
 \r
             // Tab Components\r
             this.windsorContainer.Register(Component.For<IAudioViewModel>().ImplementedBy<AudioViewModel>().LifeStyle.Is(LifestyleType.Singleton));\r
diff --git a/win/CS/HandBrakeWPF/ViewModels/Interfaces/IQueueSelectionViewModel.cs b/win/CS/HandBrakeWPF/ViewModels/Interfaces/IQueueSelectionViewModel.cs
new file mode 100644 (file)
index 0000000..36a6484
--- /dev/null
@@ -0,0 +1,40 @@
+// --------------------------------------------------------------------------------------------------------------------\r
+// <copyright file="IQueueSelectionViewModel.cs" company="HandBrake Project (http://handbrake.fr)">\r
+//   This file is part of the HandBrake source code - It may be used under the terms of the GNU General Public License.\r
+// </copyright>\r
+// <summary>\r
+//   The Queue Selection View Model Interface\r
+// </summary>\r
+// --------------------------------------------------------------------------------------------------------------------\r
+\r
+namespace HandBrakeWPF.ViewModels.Interfaces\r
+{\r
+    using System.Collections.Generic;\r
+    using System.ComponentModel;\r
+\r
+    using HandBrake.ApplicationServices.Parsing;\r
+\r
+    using HandBrakeWPF.Model;\r
+\r
+    /// <summary>\r
+    /// The Add Preset View Model\r
+    /// </summary>\r
+    public interface IQueueSelectionViewModel\r
+    {\r
+        /// <summary>\r
+        /// Gets the selected titles.\r
+        /// </summary>\r
+        BindingList<SelectionTitle> TitleList { get; }\r
+\r
+        /// <summary>\r
+        /// The setup.\r
+        /// </summary>\r
+        /// <param name="scannedSource">\r
+        /// The scanned source.\r
+        /// </param>\r
+        /// <param name="sourceName">\r
+        /// The source Name.\r
+        /// </param>\r
+        void Setup(Source scannedSource, string sourceName);\r
+    }\r
+}\r
index 2db2c66c7290319f2a54cc905739a16a84a4b2e5..1d4d0e7edb4ef2d8187d1b199c514c2fbbd455d6 100644 (file)
@@ -1033,6 +1033,38 @@ namespace HandBrakeWPF.ViewModels
             }\r
         }\r
 \r
+        /// <summary>\r
+        /// The add selection to queue.\r
+        /// </summary>\r
+        public void AddSelectionToQueue()\r
+        {\r
+            if (this.ScannedSource == null || this.ScannedSource.Titles == null || this.ScannedSource.Titles.Count == 0)\r
+            {\r
+                this.errorService.ShowMessageBox("You must first scan a source and setup your job before adding to the queue.", "Error", MessageBoxButton.OK, MessageBoxImage.Error);\r
+                return;\r
+            }\r
+\r
+            if (!AutoNameHelper.IsAutonamingEnabled())\r
+            {\r
+                this.errorService.ShowMessageBox("You must turn on automatic file naming in preferences before you can add to the queue.", "Error", MessageBoxButton.OK, MessageBoxImage.Error);\r
+                return;\r
+            }\r
+\r
+            Window window = Application.Current.Windows.Cast<Window>().FirstOrDefault(x => x.GetType() == typeof(QueueSelectionViewModel));\r
+            IQueueSelectionViewModel viewModel = IoC.Get<IQueueSelectionViewModel>();\r
+\r
+            viewModel.Setup(this.ScannedSource, this.SourceName);\r
+\r
+            if (window != null)\r
+            {\r
+                window.Activate();\r
+            }\r
+            else\r
+            {\r
+                this.WindowManager.ShowWindow(viewModel);\r
+            }\r
+        }\r
+\r
         /// <summary>\r
         /// Folder Scan\r
         /// </summary>\r
diff --git a/win/CS/HandBrakeWPF/ViewModels/QueueSelectionViewModel.cs b/win/CS/HandBrakeWPF/ViewModels/QueueSelectionViewModel.cs
new file mode 100644 (file)
index 0000000..c5b6072
--- /dev/null
@@ -0,0 +1,198 @@
+// --------------------------------------------------------------------------------------------------------------------\r
+// <copyright file="QueueSelectionViewModel.cs" company="HandBrake Project (http://handbrake.fr)">\r
+//   This file is part of the HandBrake source code - It may be used under the terms of the GNU General Public License.\r
+// </copyright>\r
+// <summary>\r
+//   The Queue Selection View Model\r
+// </summary>\r
+// --------------------------------------------------------------------------------------------------------------------\r
+\r
+namespace HandBrakeWPF.ViewModels\r
+{\r
+    using System;\r
+    using System.Collections.Generic;\r
+    using System.ComponentModel;\r
+    using System.Linq;\r
+\r
+    using HandBrake.ApplicationServices.Parsing;\r
+\r
+    using HandBrakeWPF.Model;\r
+    using HandBrakeWPF.Services.Interfaces;\r
+    using HandBrakeWPF.ViewModels.Interfaces;\r
+\r
+    /// <summary>\r
+    /// The Queue Selection View Model\r
+    /// </summary>\r
+    public class QueueSelectionViewModel : ViewModelBase, IQueueSelectionViewModel\r
+    {\r
+        /// <summary>\r
+        /// The error service.\r
+        /// </summary>\r
+        private readonly IErrorService errorService;\r
+\r
+        /// <summary>\r
+        /// The ordered by duration.\r
+        /// </summary>\r
+        private bool orderedByDuration;\r
+\r
+        /// <summary>\r
+        /// The ordered by title.\r
+        /// </summary>\r
+        private bool orderedByTitle;\r
+\r
+        /// <summary>\r
+        /// Initializes a new instance of the <see cref="QueueSelectionViewModel"/> class. \r
+        /// </summary>\r
+        /// <param name="errorService">\r
+        /// The Error Service\r
+        /// </param>\r
+        public QueueSelectionViewModel(IErrorService errorService)\r
+        {\r
+            this.errorService = errorService;\r
+            this.Title = "Add to Queue";\r
+            this.TitleList = new BindingList<SelectionTitle>();\r
+            this.OrderedByTitle = true;\r
+        }\r
+\r
+        /// <summary>\r
+        /// Gets or sets the source.\r
+        /// </summary>\r
+        public string Source { get; set; }\r
+\r
+        /// <summary>\r
+        /// Gets or sets the selected titles.\r
+        /// </summary>\r
+        public BindingList<SelectionTitle> TitleList { get; set; }\r
+\r
+        /// <summary>\r
+        /// Gets or sets a value indicating whether ordered by title.\r
+        /// </summary>\r
+        public bool OrderedByTitle\r
+        {\r
+            get\r
+            {\r
+                return this.orderedByTitle;\r
+            }\r
+\r
+            set\r
+            {\r
+                this.orderedByTitle = value;\r
+                this.NotifyOfPropertyChange(() => OrderedByTitle);\r
+            }\r
+        }\r
+\r
+        /// <summary>\r
+        /// Gets or sets a value indicating whether ordered by duration.\r
+        /// </summary>\r
+        public bool OrderedByDuration\r
+        {\r
+            get\r
+            {\r
+                return this.orderedByDuration;\r
+            }\r
+\r
+            set\r
+            {\r
+                this.orderedByDuration = value;\r
+                this.NotifyOfPropertyChange(() => OrderedByDuration);\r
+            }\r
+        }\r
+\r
+        /// <summary>\r
+        /// The order by title.\r
+        /// </summary>\r
+        public void OrderByTitle()\r
+        {\r
+            TitleList = new BindingList<SelectionTitle>(TitleList.OrderBy(o => o.Title.TitleNumber).ToList());\r
+            this.NotifyOfPropertyChange(() => TitleList);\r
+            this.OrderedByTitle = true;\r
+            this.OrderedByDuration = false;\r
+        }\r
+\r
+        /// <summary>\r
+        /// The order by duration.\r
+        /// </summary>\r
+        public void OrderByDuration()\r
+        {\r
+            TitleList = new BindingList<SelectionTitle>(TitleList.OrderByDescending(o => o.Title.Duration).ToList());\r
+            this.NotifyOfPropertyChange(() => TitleList);\r
+            this.OrderedByTitle = false;\r
+            this.OrderedByDuration = true;\r
+        }\r
+\r
+        /// <summary>\r
+        /// The select all.\r
+        /// </summary>\r
+        public void SelectAll()\r
+        {\r
+            foreach (var item in TitleList)\r
+            {\r
+                item.IsSelected = true;\r
+            }\r
+        }\r
+\r
+        /// <summary>\r
+        /// The select all.\r
+        /// </summary>\r
+        public void UnSelectAll()\r
+        {\r
+            foreach (var item in TitleList)\r
+            {\r
+                item.IsSelected = false;\r
+            }\r
+        }\r
+\r
+        /// <summary>\r
+        /// Add a Preset\r
+        /// </summary>\r
+        public void Add()\r
+        {\r
+            this.Close();\r
+        }\r
+\r
+        /// <summary>\r
+        /// Cancel adding a preset\r
+        /// </summary>\r
+        public void Cancel()\r
+        {\r
+            this.TitleList.Clear();\r
+            this.Close();\r
+        }\r
+\r
+        /// <summary>\r
+        /// Close this window.\r
+        /// </summary>\r
+        public void Close()\r
+        {\r
+            this.TryClose();\r
+        }\r
+\r
+        /// <summary>\r
+        /// The setup.\r
+        /// </summary>\r
+        /// <param name="scannedSource">\r
+        /// The scanned source.\r
+        /// </param>\r
+        /// <param name="srcName">\r
+        /// The src Name.\r
+        /// </param>\r
+        public void Setup(Source scannedSource, string srcName)\r
+        {\r
+            this.TitleList.Clear();\r
+\r
+            if (scannedSource != null)\r
+            {\r
+\r
+                IEnumerable<Title> titles = orderedByTitle\r
+                                         ? scannedSource.Titles\r
+                                         : scannedSource.Titles.OrderByDescending(o => o.Duration).ToList();\r
+\r
+                foreach (Title item in titles)\r
+                {\r
+                    SelectionTitle title = new SelectionTitle(item, srcName);\r
+                    TitleList.Add(title);\r
+                }\r
+            }\r
+        }\r
+    }\r
+}\r
index 91968fdc054ed402b9f060d7a917d15ddc98df46..d3485d2c02bc72019e1eaec9d3c863bed5299bee 100644 (file)
@@ -3,7 +3,7 @@
 //   This file is part of the HandBrake source code - It may be used under the terms of the GNU General Public License.\r
 // </copyright>\r
 // <summary>\r
-//   Interaction logic for VideoView.xaml\r
+//   Interaction logic for AddPresetView.xaml\r
 // </summary>\r
 // --------------------------------------------------------------------------------------------------------------------\r
 \r
@@ -12,7 +12,7 @@ namespace HandBrakeWPF.Views
     using System.Windows;\r
 \r
     /// <summary>\r
-    /// Interaction logic for VideoView.xaml\r
+    /// Interaction logic for AddPresetView.xaml\r
     /// </summary>\r
     public partial class AddPresetView : Window\r
     {\r
index 76dbf78726b93233f76f4e0db97bbadef034a5f8..1131e5bdd1bde4cec81c13a0116ccaebd20d01dd 100644 (file)
                             </StackPanel>\r
                         </MenuItem.Header>\r
                         <MenuItem Header="Add All" Micro:Message.Attach="[Event Click] = [Action AddAllToQueue]" />\r
+                        <!--<MenuItem Header="Add Selection" Micro:Message.Attach="[Event Click] = [Action AddSelectionToQueue]" />-->\r
                     </MenuItem>\r
                 </Menu>\r
 \r
diff --git a/win/CS/HandBrakeWPF/Views/QueueSelectionView.xaml b/win/CS/HandBrakeWPF/Views/QueueSelectionView.xaml
new file mode 100644 (file)
index 0000000..b46b07f
--- /dev/null
@@ -0,0 +1,140 @@
+<Window x:Class="HandBrakeWPF.Views.QueueSelectionView"\r
+        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"\r
+        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"\r
+        xmlns:cal="http://www.caliburnproject.org"\r
+        xmlns:d="http://schemas.microsoft.com/expression/blend/2008"\r
+        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"\r
+        Title="{Binding Title}"\r
+        Width="450"\r
+        MaxHeight="450"\r
+        SizeToContent="Height"\r
+        WindowStartupLocation="CenterScreen"\r
+        TextOptions.TextFormattingMode="Display"\r
+        mc:Ignorable="d">\r
+\r
+    <Window.Resources>\r
+\r
+        <Style x:Key="LongToolTipHolder" TargetType="FrameworkElement">\r
+            <Setter Property="ToolTipService.ShowDuration" Value="20000" />\r
+            <Setter Property="Margin" Value="0,2,0,2" />\r
+        </Style>\r
+    </Window.Resources>\r
+\r
+    <Grid HorizontalAlignment="Stretch"\r
+          VerticalAlignment="Stretch"\r
+          Background="#FFF1F0EF">\r
+        <Grid.RowDefinitions>\r
+            <RowDefinition Height="Auto" />\r
+            <RowDefinition Height="Auto" />\r
+            <RowDefinition Height="*" />\r
+            <RowDefinition Height="Auto" />\r
+            <RowDefinition Height="Auto" />\r
+        </Grid.RowDefinitions>\r
+\r
+        <!--  Header  -->\r
+        <StackPanel Grid.Row="0"\r
+                    Height="30"\r
+                    Margin="0,0,0,10"\r
+                    Background="White"\r
+                    Orientation="Horizontal">\r
+            <Image Width="24"\r
+                   Height="24"\r
+                   Margin="10,0,5,0"\r
+                   VerticalAlignment="Center"\r
+                   Source="Images/AddToQueue_small.png" />\r
+            <StackPanel VerticalAlignment="Center" Orientation="Vertical">\r
+                <TextBlock FontWeight="Bold" Text="Queue Multiple Items" />\r
+            </StackPanel>\r
+        </StackPanel>\r
+\r
+        <!-- Text -->\r
+        <StackPanel Orientation="Vertical" Grid.Row="1" Margin="10,10,10,0">\r
+            <TextBlock Text="Select multiple titles to add: " />\r
+        </StackPanel>\r
+\r
+        <!-- Selection -->\r
+        <ListBox Grid.Row="2"\r
+                 Margin="10,10,10,10"\r
+                 VerticalAlignment="Stretch"\r
+                 Background="LightGray"\r
+                 ItemsSource="{Binding TitleList}"\r
+                 SelectionMode="Single">\r
+            <ListBox.ItemContainerStyle>\r
+                <Style TargetType="ListBoxItem">\r
+                    <Setter Property="HorizontalContentAlignment" Value="Stretch" />\r
+                    <Setter Property="Background" Value="WhiteSmoke" />\r
+                    <Setter Property="Margin" Value="0,0,0,1" />\r
+                </Style>\r
+            </ListBox.ItemContainerStyle>\r
+\r
+            <ListBox.ContextMenu>\r
+                <ContextMenu>\r
+                    <MenuItem Header="Select All" cal:Message.Attach="[Event Click] = [Action SelectAll]" />\r
+                    <MenuItem Header="Select All" cal:Message.Attach="[Event Click] = [Action UnSelectAll]" />\r
+                    <Separator />\r
+                    <MenuItem Header="Order by Title" IsChecked="{Binding OrderedByTitle}" cal:Message.Attach="[Event Click] = [Action OrderByTitle]" />\r
+                    <MenuItem Header="Order by Duration" IsChecked="{Binding OrderedByDuration}" cal:Message.Attach="[Event Click] = [Action OrderByDuration]" />\r
+                </ContextMenu>\r
+            </ListBox.ContextMenu>\r
+\r
+            <ListBox.ItemTemplate>\r
+                <DataTemplate>\r
+                    <Grid HorizontalAlignment="Stretch" MinHeight="28">\r
+                        <Grid.RowDefinitions>\r
+                            <RowDefinition Height="Auto" />\r
+                            <RowDefinition Height="Auto" />\r
+                        </Grid.RowDefinitions>\r
+                        <Grid.ColumnDefinitions>\r
+                            <ColumnDefinition Width="Auto" />\r
+                            <ColumnDefinition Width="*" />\r
+                            <ColumnDefinition Width="Auto" />\r
+                        </Grid.ColumnDefinitions>\r
+                        \r
+                        <CheckBox IsChecked="{Binding IsSelected}" Grid.RowSpan="2" Grid.Row="0" Grid.Column="0" VerticalAlignment="Center" />\r
+\r
+                        <StackPanel Grid.Row="0" Grid.Column="1" Orientation="Horizontal" Margin="10,0,0,0" >                           \r
+                            <TextBlock Text="Title:" Margin="0,0,5,0" FontWeight="Bold" />\r
+                            <TextBlock Text="{Binding Title}" Margin="5,0,5,0" />\r
+                        </StackPanel>\r
+\r
+                        <StackPanel Grid.Row="1" Grid.Column="1" Orientation="Horizontal" Margin="10,0,0,0" >\r
+                            <TextBlock Text="Source:" Margin="0,0,5,0" FontWeight="Bold" />\r
+                            <TextBlock Text="{Binding SourceName}" Margin="5,0,5,0" />\r
+                        </StackPanel>\r
+                    </Grid>\r
+\r
+                </DataTemplate>\r
+            </ListBox.ItemTemplate>\r
+        </ListBox>\r
+\r
+        <!-- Checlist -->\r
+        <StackPanel Orientation="Vertical" Grid.Row="3" Margin="10,10,10,0">\r
+            <TextBlock Text="Checklist " />\r
+        </StackPanel>\r
+\r
+        <!--  Controls  -->\r
+        <Grid Grid.Row="4"\r
+              Margin="0,20,0,0"\r
+              Background="LightGray">\r
+            <Grid.ColumnDefinitions>\r
+                <ColumnDefinition Width="*" />\r
+                <ColumnDefinition Width="Auto" />\r
+                <ColumnDefinition Width="Auto" />\r
+            </Grid.ColumnDefinitions>\r
+\r
+            <Button Grid.Column="1"\r
+                    Margin="0,5,10,5"\r
+                    cal:Message.Attach="[Event Click] = [Action Cancel]"\r
+                    Content="Cancel"\r
+                    IsCancel="True"\r
+                    Padding="8,2" />\r
+            <Button Grid.Column="2"\r
+                    Margin="0,5,10,5"\r
+                    cal:Message.Attach="[Event Click] = [Action Add]"\r
+                    Content="Add"\r
+                    IsDefault="True"\r
+                    Padding="8,2" />\r
+        </Grid>\r
+\r
+    </Grid>\r
+</Window>\r
diff --git a/win/CS/HandBrakeWPF/Views/QueueSelectionView.xaml.cs b/win/CS/HandBrakeWPF/Views/QueueSelectionView.xaml.cs
new file mode 100644 (file)
index 0000000..553c720
--- /dev/null
@@ -0,0 +1,27 @@
+// --------------------------------------------------------------------------------------------------------------------\r
+// <copyright file="QueueSelectionView.xaml.cs" company="HandBrake Project (http://handbrake.fr)">\r
+//   This file is part of the HandBrake source code - It may be used under the terms of the GNU General Public License.\r
+// </copyright>\r
+// <summary>\r
+//   Interaction logic for QueueSelectionView.xaml\r
+// </summary>\r
+// --------------------------------------------------------------------------------------------------------------------\r
+\r
+namespace HandBrakeWPF.Views\r
+{\r
+    using System.Windows;\r
+\r
+    /// <summary>\r
+    /// Interaction logic for QueueSelectionView.xaml\r
+    /// </summary>\r
+    public partial class QueueSelectionView : Window\r
+    {\r
+        /// <summary>\r
+        /// Initializes a new instance of the <see cref="QueueSelectionView"/> class.\r
+        /// </summary>\r
+        public QueueSelectionView()\r
+        {\r
+            InitializeComponent();\r
+        }\r
+    }\r
+}\r