OSDN Git Service

WinGui:
authorsr55 <sr55@b64f7644-9d1e-0410-96f1-a4d463321fa5>
Thu, 6 Dec 2007 14:14:25 +0000 (14:14 +0000)
committersr55 <sr55@b64f7644-9d1e-0410-96f1-a4d463321fa5>
Thu, 6 Dec 2007 14:14:25 +0000 (14:14 +0000)
- Fixed bug in Query Parser in relation to Titles (Error when 1 was set to auto)
- Added Batch Script creation option on the Queue.
- Added Toolbar to the queue (similar to the MacGui) and removed some old style buttons that are now on the toolbar.

git-svn-id: svn://localhost/HandBrake/trunk@1100 b64f7644-9d1e-0410-96f1-a4d463321fa5

win/C#/Functions/QueryParser.cs
win/C#/HandBrakeCS.csproj
win/C#/Properties/Resources.Designer.cs
win/C#/Properties/Resources.resx
win/C#/Resources/ActivityWindow.png [new file with mode: 0644]
win/C#/Resources/Pause.png [new file with mode: 0644]
win/C#/Resources/Play.png [new file with mode: 0644]
win/C#/frmQueue.Designer.cs
win/C#/frmQueue.cs
win/C#/frmQueue.resx

index f49115a..174f922 100644 (file)
@@ -595,7 +595,13 @@ namespace Handbrake.Functions
                     actTitles = chapters.ToString().Replace("-c ", "").Split('-');\r
                     thisQuery.q_chaptersStart = int.Parse(actTitles[0]);\r
                     if (actTitles.Length > 1)\r
+                    {\r
+                        MessageBox.Show(actTitles[1]);\r
                         thisQuery.q_chaptersFinish = int.Parse(actTitles[1]);\r
+                    }\r
+\r
+                    if ((thisQuery.q_chaptersStart == 1) && (thisQuery.q_chaptersFinish == 0))\r
+                        thisQuery.q_chaptersFinish = thisQuery.q_chaptersStart;\r
                 }\r
 \r
                 if (format.Success != false)\r
index cd3ca22..52a9863 100644 (file)
@@ -37,7 +37,8 @@
     <WarningLevel>4</WarningLevel>\r
     <TreatWarningsAsErrors>false</TreatWarningsAsErrors>\r
     <UseVSHostingProcess>false</UseVSHostingProcess>\r
-    <DocumentationFile>bin\Release\Handbrake.XML</DocumentationFile>\r
+    <DocumentationFile>\r
+    </DocumentationFile>\r
   </PropertyGroup>\r
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">\r
     <PlatformTarget>x86</PlatformTarget>\r
     <Content Include="handbrakepineapple.ico" />\r
     <None Include="Resources\logo64.png" />\r
     <None Include="Resources\logo128.png" />\r
+    <None Include="Resources\folder.png" />\r
+    <None Include="Resources\ActivityWindow.png" />\r
     <Content Include="Resources\Output_Small.png" />\r
+    <None Include="Resources\Pause.png" />\r
+    <None Include="Resources\Play.png" />\r
     <Content Include="Resources\Pref_Small.png" />\r
     <Content Include="Resources\Queue.png" />\r
     <Content Include="Resources\Queue_Small.png" />\r
+    <None Include="Resources\Save.png" />\r
+    <None Include="Resources\Stop.png" />\r
     <None Include="Resources\SplashScreen.jpg" />\r
     <None Include="Resources\Remove.png" />\r
     <None Include="Resources\Movies.png" />\r
index f134afa..40e640b 100644 (file)
@@ -1,7 +1,7 @@
 //------------------------------------------------------------------------------\r
 // <auto-generated>\r
 //     This code was generated by a tool.\r
-//     Runtime Version:2.0.50727.1378\r
+//     Runtime Version:2.0.50727.1433\r
 //\r
 //     Changes to this file may cause incorrect behavior and will be lost if\r
 //     the code is regenerated.\r
@@ -60,6 +60,13 @@ namespace Handbrake.Properties {
             }\r
         }\r
         \r
+        internal static System.Drawing.Bitmap ActivityWindow {\r
+            get {\r
+                object obj = ResourceManager.GetObject("ActivityWindow", resourceCulture);\r
+                return ((System.Drawing.Bitmap)(obj));\r
+            }\r
+        }\r
+        \r
         internal static System.Drawing.Bitmap Delete {\r
             get {\r
                 object obj = ResourceManager.GetObject("Delete", resourceCulture);\r
@@ -81,6 +88,13 @@ namespace Handbrake.Properties {
             }\r
         }\r
         \r
+        internal static System.Drawing.Bitmap folder {\r
+            get {\r
+                object obj = ResourceManager.GetObject("folder", resourceCulture);\r
+                return ((System.Drawing.Bitmap)(obj));\r
+            }\r
+        }\r
+        \r
         internal static System.Drawing.Bitmap General_Preferences {\r
             get {\r
                 object obj = ResourceManager.GetObject("General_Preferences", resourceCulture);\r
@@ -144,6 +158,20 @@ namespace Handbrake.Properties {
             }\r
         }\r
         \r
+        internal static System.Drawing.Bitmap Pause {\r
+            get {\r
+                object obj = ResourceManager.GetObject("Pause", resourceCulture);\r
+                return ((System.Drawing.Bitmap)(obj));\r
+            }\r
+        }\r
+        \r
+        internal static System.Drawing.Bitmap Play {\r
+            get {\r
+                object obj = ResourceManager.GetObject("Play", resourceCulture);\r
+                return ((System.Drawing.Bitmap)(obj));\r
+            }\r
+        }\r
+        \r
         internal static System.Drawing.Bitmap Pref_Small {\r
             get {\r
                 object obj = ResourceManager.GetObject("Pref_Small", resourceCulture);\r
index 8bdc2a8..c8e8c0e 100644 (file)
     <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>\r
   </resheader>\r
   <assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />\r
-  <data name="Pref_Small" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
-    <value>..\Resources\Pref_Small.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  <data name="folder" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\folder.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
   </data>\r
-  <data name="Movies_Small" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
-    <value>..\Resources\Movies_Small.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  <data name="General_Preferences" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\General Preferences.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
   </data>\r
-  <data name="info" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
-    <value>..\Resources\info.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  <data name="Queue" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\Queue.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
   </data>\r
-  <data name="logo64" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
-    <value>..\Resources\logo64.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  <data name="Play" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\Play.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  </data>\r
+  <data name="Disc" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\Disc.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
   </data>\r
   <data name="Emoticon" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
     <value>..\Resources\Emoticon.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
   </data>\r
-  <data name="Remove" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
-    <value>..\Resources\Remove.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  <data name="Help" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\Help.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
   </data>\r
-  <data name="Output_Small" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
-    <value>..\Resources\Output_Small.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  <data name="logo64" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\logo64.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
   </data>\r
-  <data name="SplashScreen" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
-    <value>..\Resources\SplashScreen.jpg;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  <data name="Pref_Small" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\Pref_Small.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
   </data>\r
-  <data name="Delete" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
-    <value>..\Resources\Delete.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  <data name="Stop" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\Stop.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
   </data>\r
-  <data name="Queue_Small" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
-    <value>..\Resources\Queue_Small.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  <data name="History" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\History.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
   </data>\r
-  <data name="General_Preferences" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
-    <value>..\Resources\General Preferences.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  <data name="logo128" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\logo128.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
   </data>\r
-  <data name="Queue" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
-    <value>..\Resources\Queue.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  <data name="Pause" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\Pause.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
   </data>\r
-  <data name="History" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
-    <value>..\Resources\History.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  <data name="SplashScreen" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\SplashScreen.jpg;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
   </data>\r
-  <data name="Help" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
-    <value>..\Resources\Help.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  <data name="Output_Small" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\Output_Small.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
   </data>\r
-  <data name="Disc" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
-    <value>..\Resources\Disc.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  <data name="info" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\info.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  </data>\r
+  <data name="Queue_Small" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\Queue_Small.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  </data>\r
+  <data name="Remove" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\Remove.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
   </data>\r
   <data name="Movies" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
     <value>..\Resources\Movies.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
   </data>\r
-  <data name="logo128" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
-    <value>..\Resources\logo128.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  <data name="Delete" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\Delete.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  </data>\r
+  <data name="Movies_Small" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\Movies_Small.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
+  </data>\r
+  <data name="ActivityWindow" type="System.Resources.ResXFileRef, System.Windows.Forms">\r
+    <value>..\Resources\ActivityWindow.png;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>\r
   </data>\r
 </root>
\ No newline at end of file
diff --git a/win/C#/Resources/ActivityWindow.png b/win/C#/Resources/ActivityWindow.png
new file mode 100644 (file)
index 0000000..315e0fa
Binary files /dev/null and b/win/C#/Resources/ActivityWindow.png differ
diff --git a/win/C#/Resources/Pause.png b/win/C#/Resources/Pause.png
new file mode 100644 (file)
index 0000000..a208339
Binary files /dev/null and b/win/C#/Resources/Pause.png differ
diff --git a/win/C#/Resources/Play.png b/win/C#/Resources/Play.png
new file mode 100644 (file)
index 0000000..23fce82
Binary files /dev/null and b/win/C#/Resources/Play.png differ
index 6098553..8e41603 100644 (file)
@@ -33,13 +33,11 @@ namespace Handbrake
             this.btn_down = new System.Windows.Forms.Button();\r
             this.btn_up = new System.Windows.Forms.Button();\r
             this.btn_delete = new System.Windows.Forms.Button();\r
-            this.btn_q_encoder = new System.Windows.Forms.Button();\r
             this.list_queue = new System.Windows.Forms.ListBox();\r
             this.btn_Close = new System.Windows.Forms.Button();\r
             this.progressBar = new System.Windows.Forms.ProgressBar();\r
             this.label2 = new System.Windows.Forms.Label();\r
             this.lbl_progressValue = new System.Windows.Forms.Label();\r
-            this.btn_cancel = new System.Windows.Forms.Button();\r
             this.lbl_status = new System.Windows.Forms.Label();\r
             this.toolTip1 = new System.Windows.Forms.ToolTip(this.components);\r
             this.text_edit = new System.Windows.Forms.TextBox();\r
@@ -53,7 +51,14 @@ namespace Handbrake
             this.lbl_source = new System.Windows.Forms.Label();\r
             this.label1 = new System.Windows.Forms.Label();\r
             this.label3 = new System.Windows.Forms.Label();\r
+            this.toolStrip1 = new System.Windows.Forms.ToolStrip();\r
+            this.btn_encode = new System.Windows.Forms.ToolStripButton();\r
+            this.btn_stop = new System.Windows.Forms.ToolStripButton();\r
+            this.toolStripSeparator1 = new System.Windows.Forms.ToolStripSeparator();\r
+            this.btn_batch = new System.Windows.Forms.ToolStripButton();\r
             this.pictureBox1 = new System.Windows.Forms.PictureBox();\r
+            this.SaveFile = new System.Windows.Forms.SaveFileDialog();\r
+            this.toolStrip1.SuspendLayout();\r
             ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();\r
             this.SuspendLayout();\r
             // \r
@@ -64,7 +69,7 @@ namespace Handbrake
             this.btn_down.FlatStyle = System.Windows.Forms.FlatStyle.Flat;\r
             this.btn_down.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
             this.btn_down.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0)))));\r
-            this.btn_down.Location = new System.Drawing.Point(74, 274);\r
+            this.btn_down.Location = new System.Drawing.Point(74, 327);\r
             this.btn_down.Name = "btn_down";\r
             this.btn_down.Size = new System.Drawing.Size(64, 22);\r
             this.btn_down.TabIndex = 33;\r
@@ -80,7 +85,7 @@ namespace Handbrake
             this.btn_up.FlatStyle = System.Windows.Forms.FlatStyle.Flat;\r
             this.btn_up.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
             this.btn_up.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0)))));\r
-            this.btn_up.Location = new System.Drawing.Point(13, 274);\r
+            this.btn_up.Location = new System.Drawing.Point(13, 327);\r
             this.btn_up.Name = "btn_up";\r
             this.btn_up.Size = new System.Drawing.Size(55, 22);\r
             this.btn_up.TabIndex = 32;\r
@@ -96,7 +101,7 @@ namespace Handbrake
             this.btn_delete.FlatStyle = System.Windows.Forms.FlatStyle.Flat;\r
             this.btn_delete.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
             this.btn_delete.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0)))));\r
-            this.btn_delete.Location = new System.Drawing.Point(144, 274);\r
+            this.btn_delete.Location = new System.Drawing.Point(144, 327);\r
             this.btn_delete.Name = "btn_delete";\r
             this.btn_delete.Size = new System.Drawing.Size(64, 22);\r
             this.btn_delete.TabIndex = 31;\r
@@ -105,30 +110,14 @@ namespace Handbrake
             this.btn_delete.UseVisualStyleBackColor = false;\r
             this.btn_delete.Click += new System.EventHandler(this.btn_delete_Click);\r
             // \r
-            // btn_q_encoder\r
-            // \r
-            this.btn_q_encoder.BackColor = System.Drawing.SystemColors.ControlLight;\r
-            this.btn_q_encoder.FlatAppearance.BorderColor = System.Drawing.Color.Black;\r
-            this.btn_q_encoder.FlatStyle = System.Windows.Forms.FlatStyle.Flat;\r
-            this.btn_q_encoder.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
-            this.btn_q_encoder.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0)))));\r
-            this.btn_q_encoder.Location = new System.Drawing.Point(12, 345);\r
-            this.btn_q_encoder.Name = "btn_q_encoder";\r
-            this.btn_q_encoder.Size = new System.Drawing.Size(124, 22);\r
-            this.btn_q_encoder.TabIndex = 29;\r
-            this.btn_q_encoder.TabStop = false;\r
-            this.btn_q_encoder.Text = "Encode Video(s)";\r
-            this.btn_q_encoder.UseVisualStyleBackColor = false;\r
-            this.btn_q_encoder.Click += new System.EventHandler(this.btn_q_encoder_Click);\r
-            // \r
             // list_queue\r
             // \r
             this.list_queue.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;\r
             this.list_queue.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
             this.list_queue.HorizontalScrollbar = true;\r
-            this.list_queue.Location = new System.Drawing.Point(12, 110);\r
+            this.list_queue.Location = new System.Drawing.Point(12, 176);\r
             this.list_queue.Name = "list_queue";\r
-            this.list_queue.Size = new System.Drawing.Size(701, 158);\r
+            this.list_queue.Size = new System.Drawing.Size(701, 145);\r
             this.list_queue.TabIndex = 28;\r
             this.list_queue.SelectedIndexChanged += new System.EventHandler(this.list_queue_SelectedIndexChanged);\r
             // \r
@@ -139,7 +128,7 @@ namespace Handbrake
             this.btn_Close.FlatStyle = System.Windows.Forms.FlatStyle.Flat;\r
             this.btn_Close.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
             this.btn_Close.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0)))));\r
-            this.btn_Close.Location = new System.Drawing.Point(606, 345);\r
+            this.btn_Close.Location = new System.Drawing.Point(605, 12);\r
             this.btn_Close.Name = "btn_Close";\r
             this.btn_Close.Size = new System.Drawing.Size(108, 22);\r
             this.btn_Close.TabIndex = 27;\r
@@ -151,16 +140,16 @@ namespace Handbrake
             // progressBar\r
             // \r
             this.progressBar.BackColor = System.Drawing.SystemColors.ControlLight;\r
-            this.progressBar.Location = new System.Drawing.Point(67, 307);\r
+            this.progressBar.Location = new System.Drawing.Point(67, 360);\r
             this.progressBar.Name = "progressBar";\r
-            this.progressBar.Size = new System.Drawing.Size(608, 23);\r
+            this.progressBar.Size = new System.Drawing.Size(647, 23);\r
             this.progressBar.Style = System.Windows.Forms.ProgressBarStyle.Continuous;\r
             this.progressBar.TabIndex = 34;\r
             // \r
             // label2\r
             // \r
             this.label2.AutoSize = true;\r
-            this.label2.Location = new System.Drawing.Point(10, 313);\r
+            this.label2.Location = new System.Drawing.Point(10, 366);\r
             this.label2.Name = "label2";\r
             this.label2.Size = new System.Drawing.Size(51, 13);\r
             this.label2.TabIndex = 35;\r
@@ -169,36 +158,17 @@ namespace Handbrake
             // lbl_progressValue\r
             // \r
             this.lbl_progressValue.AutoSize = true;\r
-            this.lbl_progressValue.Location = new System.Drawing.Point(690, 313);\r
+            this.lbl_progressValue.Location = new System.Drawing.Point(690, 331);\r
             this.lbl_progressValue.Name = "lbl_progressValue";\r
             this.lbl_progressValue.Size = new System.Drawing.Size(24, 13);\r
             this.lbl_progressValue.TabIndex = 36;\r
             this.lbl_progressValue.Text = "0 %";\r
             // \r
-            // btn_cancel\r
-            // \r
-            this.btn_cancel.BackColor = System.Drawing.SystemColors.ControlLight;\r
-            this.btn_cancel.FlatAppearance.BorderColor = System.Drawing.Color.Black;\r
-            this.btn_cancel.FlatStyle = System.Windows.Forms.FlatStyle.Flat;\r
-            this.btn_cancel.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
-            this.btn_cancel.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0)))));\r
-            this.btn_cancel.Location = new System.Drawing.Point(143, 345);\r
-            this.btn_cancel.Name = "btn_cancel";\r
-            this.btn_cancel.Size = new System.Drawing.Size(91, 22);\r
-            this.btn_cancel.TabIndex = 41;\r
-            this.btn_cancel.TabStop = false;\r
-            this.btn_cancel.Text = "Stop Queue";\r
-            this.toolTip1.SetToolTip(this.btn_cancel, "This will prevent any more encode processes from starting. It will not stop the c" +\r
-                    "urrent process!");\r
-            this.btn_cancel.UseVisualStyleBackColor = false;\r
-            this.btn_cancel.Visible = false;\r
-            this.btn_cancel.Click += new System.EventHandler(this.btn_cancel_Click);\r
-            // \r
             // lbl_status\r
             // \r
             this.lbl_status.AutoSize = true;\r
             this.lbl_status.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
-            this.lbl_status.Location = new System.Drawing.Point(274, 313);\r
+            this.lbl_status.Location = new System.Drawing.Point(274, 366);\r
             this.lbl_status.Name = "lbl_status";\r
             this.lbl_status.Size = new System.Drawing.Size(176, 13);\r
             this.lbl_status.TabIndex = 42;\r
@@ -208,7 +178,7 @@ namespace Handbrake
             // text_edit\r
             // \r
             this.text_edit.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;\r
-            this.text_edit.Location = new System.Drawing.Point(214, 275);\r
+            this.text_edit.Location = new System.Drawing.Point(214, 328);\r
             this.text_edit.Name = "text_edit";\r
             this.text_edit.Size = new System.Drawing.Size(430, 20);\r
             this.text_edit.TabIndex = 43;\r
@@ -222,7 +192,7 @@ namespace Handbrake
             this.btn_updateQuery.FlatStyle = System.Windows.Forms.FlatStyle.Flat;\r
             this.btn_updateQuery.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
             this.btn_updateQuery.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0)))));\r
-            this.btn_updateQuery.Location = new System.Drawing.Point(650, 274);\r
+            this.btn_updateQuery.Location = new System.Drawing.Point(650, 327);\r
             this.btn_updateQuery.Name = "btn_updateQuery";\r
             this.btn_updateQuery.Size = new System.Drawing.Size(64, 23);\r
             this.btn_updateQuery.TabIndex = 46;\r
@@ -235,7 +205,7 @@ namespace Handbrake
             // \r
             this.label4.AutoSize = true;\r
             this.label4.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
-            this.label4.Location = new System.Drawing.Point(232, 72);\r
+            this.label4.Location = new System.Drawing.Point(232, 125);\r
             this.label4.Name = "label4";\r
             this.label4.Size = new System.Drawing.Size(47, 26);\r
             this.label4.TabIndex = 70;\r
@@ -244,7 +214,7 @@ namespace Handbrake
             // lbl_chapt\r
             // \r
             this.lbl_chapt.AutoSize = true;\r
-            this.lbl_chapt.Location = new System.Drawing.Point(175, 84);\r
+            this.lbl_chapt.Location = new System.Drawing.Point(175, 137);\r
             this.lbl_chapt.Name = "lbl_chapt";\r
             this.lbl_chapt.Size = new System.Drawing.Size(10, 13);\r
             this.lbl_chapt.TabIndex = 69;\r
@@ -254,7 +224,7 @@ namespace Handbrake
             // \r
             this.lbl_title.AccessibleRole = System.Windows.Forms.AccessibleRole.None;\r
             this.lbl_title.AutoSize = true;\r
-            this.lbl_title.Location = new System.Drawing.Point(175, 71);\r
+            this.lbl_title.Location = new System.Drawing.Point(175, 124);\r
             this.lbl_title.Name = "lbl_title";\r
             this.lbl_title.Size = new System.Drawing.Size(10, 13);\r
             this.lbl_title.TabIndex = 68;\r
@@ -263,7 +233,7 @@ namespace Handbrake
             // lbl_aEnc\r
             // \r
             this.lbl_aEnc.AutoSize = true;\r
-            this.lbl_aEnc.Location = new System.Drawing.Point(285, 85);\r
+            this.lbl_aEnc.Location = new System.Drawing.Point(285, 138);\r
             this.lbl_aEnc.Name = "lbl_aEnc";\r
             this.lbl_aEnc.Size = new System.Drawing.Size(10, 13);\r
             this.lbl_aEnc.TabIndex = 67;\r
@@ -272,7 +242,7 @@ namespace Handbrake
             // lbl_vEnc\r
             // \r
             this.lbl_vEnc.AutoSize = true;\r
-            this.lbl_vEnc.Location = new System.Drawing.Point(285, 72);\r
+            this.lbl_vEnc.Location = new System.Drawing.Point(285, 125);\r
             this.lbl_vEnc.Name = "lbl_vEnc";\r
             this.lbl_vEnc.Size = new System.Drawing.Size(10, 13);\r
             this.lbl_vEnc.TabIndex = 66;\r
@@ -281,7 +251,7 @@ namespace Handbrake
             // lbl_dest\r
             // \r
             this.lbl_dest.AutoSize = true;\r
-            this.lbl_dest.Location = new System.Drawing.Point(175, 59);\r
+            this.lbl_dest.Location = new System.Drawing.Point(175, 112);\r
             this.lbl_dest.Name = "lbl_dest";\r
             this.lbl_dest.Size = new System.Drawing.Size(10, 13);\r
             this.lbl_dest.TabIndex = 65;\r
@@ -291,7 +261,7 @@ namespace Handbrake
             // lbl_source\r
             // \r
             this.lbl_source.AutoSize = true;\r
-            this.lbl_source.Location = new System.Drawing.Point(175, 46);\r
+            this.lbl_source.Location = new System.Drawing.Point(175, 99);\r
             this.lbl_source.Name = "lbl_source";\r
             this.lbl_source.Size = new System.Drawing.Size(10, 13);\r
             this.lbl_source.TabIndex = 64;\r
@@ -301,7 +271,7 @@ namespace Handbrake
             // \r
             this.label1.AutoSize = true;\r
             this.label1.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
-            this.label1.Location = new System.Drawing.Point(50, 46);\r
+            this.label1.Location = new System.Drawing.Point(50, 99);\r
             this.label1.Name = "label1";\r
             this.label1.Size = new System.Drawing.Size(99, 52);\r
             this.label1.TabIndex = 63;\r
@@ -311,27 +281,85 @@ namespace Handbrake
             // \r
             this.label3.AutoSize = true;\r
             this.label3.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
-            this.label3.Location = new System.Drawing.Point(50, 24);\r
+            this.label3.Location = new System.Drawing.Point(50, 77);\r
             this.label3.Name = "label3";\r
             this.label3.Size = new System.Drawing.Size(82, 13);\r
             this.label3.TabIndex = 62;\r
             this.label3.Text = "Current Job";\r
             // \r
+            // toolStrip1\r
+            // \r
+            this.toolStrip1.GripStyle = System.Windows.Forms.ToolStripGripStyle.Hidden;\r
+            this.toolStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {\r
+            this.btn_encode,\r
+            this.btn_stop,\r
+            this.toolStripSeparator1,\r
+            this.btn_batch});\r
+            this.toolStrip1.LayoutStyle = System.Windows.Forms.ToolStripLayoutStyle.HorizontalStackWithOverflow;\r
+            this.toolStrip1.Location = new System.Drawing.Point(0, 0);\r
+            this.toolStrip1.Name = "toolStrip1";\r
+            this.toolStrip1.RenderMode = System.Windows.Forms.ToolStripRenderMode.System;\r
+            this.toolStrip1.Size = new System.Drawing.Size(729, 49);\r
+            this.toolStrip1.TabIndex = 71;\r
+            this.toolStrip1.Text = "toolStrip1";\r
+            // \r
+            // btn_encode\r
+            // \r
+            this.btn_encode.Image = global::Handbrake.Properties.Resources.Play;\r
+            this.btn_encode.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;\r
+            this.btn_encode.ImageTransparentColor = System.Drawing.Color.Magenta;\r
+            this.btn_encode.Name = "btn_encode";\r
+            this.btn_encode.Padding = new System.Windows.Forms.Padding(5);\r
+            this.btn_encode.Size = new System.Drawing.Size(88, 46);\r
+            this.btn_encode.Text = "Encode";\r
+            this.btn_encode.Click += new System.EventHandler(this.btn_encode_Click);\r
+            // \r
+            // btn_stop\r
+            // \r
+            this.btn_stop.Image = global::Handbrake.Properties.Resources.Pause;\r
+            this.btn_stop.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;\r
+            this.btn_stop.ImageTransparentColor = System.Drawing.Color.Magenta;\r
+            this.btn_stop.Name = "btn_stop";\r
+            this.btn_stop.Size = new System.Drawing.Size(72, 46);\r
+            this.btn_stop.Text = "Pause";\r
+            this.btn_stop.Visible = false;\r
+            this.btn_stop.Click += new System.EventHandler(this.btn_stop_Click);\r
+            // \r
+            // toolStripSeparator1\r
+            // \r
+            this.toolStripSeparator1.Name = "toolStripSeparator1";\r
+            this.toolStripSeparator1.Size = new System.Drawing.Size(6, 49);\r
+            // \r
+            // btn_batch\r
+            // \r
+            this.btn_batch.Image = global::Handbrake.Properties.Resources.ActivityWindow;\r
+            this.btn_batch.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;\r
+            this.btn_batch.ImageTransparentColor = System.Drawing.Color.Magenta;\r
+            this.btn_batch.Name = "btn_batch";\r
+            this.btn_batch.Size = new System.Drawing.Size(100, 46);\r
+            this.btn_batch.Text = "Batch Script";\r
+            this.btn_batch.Click += new System.EventHandler(this.btn_batch_Click);\r
+            // \r
             // pictureBox1\r
             // \r
             this.pictureBox1.Image = global::Handbrake.Properties.Resources.Queue;\r
-            this.pictureBox1.Location = new System.Drawing.Point(12, 12);\r
+            this.pictureBox1.Location = new System.Drawing.Point(12, 65);\r
             this.pictureBox1.Name = "pictureBox1";\r
             this.pictureBox1.Size = new System.Drawing.Size(32, 32);\r
             this.pictureBox1.TabIndex = 61;\r
             this.pictureBox1.TabStop = false;\r
             // \r
+            // SaveFile\r
+            // \r
+            this.SaveFile.Filter = "Batch|.bat";\r
+            // \r
             // frmQueue\r
             // \r
             this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);\r
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;\r
             this.BackColor = System.Drawing.SystemColors.ControlLight;\r
-            this.ClientSize = new System.Drawing.Size(729, 377);\r
+            this.ClientSize = new System.Drawing.Size(729, 400);\r
+            this.Controls.Add(this.toolStrip1);\r
             this.Controls.Add(this.label4);\r
             this.Controls.Add(this.lbl_chapt);\r
             this.Controls.Add(this.lbl_title);\r
@@ -346,20 +374,20 @@ namespace Handbrake
             this.Controls.Add(this.btn_updateQuery);\r
             this.Controls.Add(this.btn_delete);\r
             this.Controls.Add(this.lbl_status);\r
-            this.Controls.Add(this.btn_cancel);\r
             this.Controls.Add(this.btn_up);\r
             this.Controls.Add(this.text_edit);\r
             this.Controls.Add(this.btn_down);\r
             this.Controls.Add(this.lbl_progressValue);\r
             this.Controls.Add(this.label2);\r
             this.Controls.Add(this.progressBar);\r
-            this.Controls.Add(this.btn_q_encoder);\r
             this.Controls.Add(this.btn_Close);\r
             this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));\r
             this.MaximizeBox = false;\r
             this.Name = "frmQueue";\r
             this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;\r
             this.Text = "Encode Queue";\r
+            this.toolStrip1.ResumeLayout(false);\r
+            this.toolStrip1.PerformLayout();\r
             ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();\r
             this.ResumeLayout(false);\r
             this.PerformLayout();\r
@@ -371,12 +399,10 @@ namespace Handbrake
         internal System.Windows.Forms.Button btn_down;\r
         internal System.Windows.Forms.Button btn_up;\r
         internal System.Windows.Forms.Button btn_delete;\r
-        internal System.Windows.Forms.Button btn_q_encoder;\r
         internal System.Windows.Forms.Button btn_Close;\r
         private System.Windows.Forms.ProgressBar progressBar;\r
         private System.Windows.Forms.Label label2;\r
         private System.Windows.Forms.Label lbl_progressValue;\r
-        internal System.Windows.Forms.Button btn_cancel;\r
         private System.Windows.Forms.Label lbl_status;\r
         private System.Windows.Forms.ToolTip toolTip1;\r
         public System.Windows.Forms.ListBox list_queue;\r
@@ -392,5 +418,11 @@ namespace Handbrake
         private System.Windows.Forms.Label label1;\r
         private System.Windows.Forms.Label label3;\r
         private System.Windows.Forms.PictureBox pictureBox1;\r
+        private System.Windows.Forms.ToolStrip toolStrip1;\r
+        private System.Windows.Forms.ToolStripButton btn_encode;\r
+        private System.Windows.Forms.ToolStripSeparator toolStripSeparator1;\r
+        private System.Windows.Forms.ToolStripButton btn_stop;\r
+        private System.Windows.Forms.ToolStripButton btn_batch;\r
+        private System.Windows.Forms.SaveFileDialog SaveFile;\r
     }\r
 }
\ No newline at end of file
index ae53558..0fa625f 100644 (file)
@@ -8,6 +8,7 @@ using System.Windows.Forms;
 using System.Threading;\r
 using System.Diagnostics;\r
 using System.Runtime.InteropServices;\r
+using System.IO;\r
 \r
 namespace Handbrake\r
 {\r
@@ -23,10 +24,11 @@ namespace Handbrake
 \r
         #region Queue Handling\r
         Boolean cancel = false;\r
-        private void btn_q_encoder_Click(object sender, EventArgs e)\r
+\r
+        private void btn_encode_Click(object sender, EventArgs e)\r
         {\r
             // Reset some values\r
-            \r
+\r
             lbl_status.Visible = false;\r
             cancel = false;\r
 \r
@@ -36,7 +38,7 @@ namespace Handbrake
                 if (list_queue.Items.Count != 0)\r
                 {\r
                     // Setup or reset some values\r
-                    btn_cancel.Visible = true;\r
+                    btn_stop.Visible = true;\r
                     progressBar.Value = 0;\r
                     lbl_progressValue.Text = "0 %";\r
                     progressBar.Step = 100 / list_queue.Items.Count;\r
@@ -45,18 +47,18 @@ namespace Handbrake
                     // Testing a new way of launching a thread. Hopefully will fix a random freeze up of the main thread.\r
                     Thread theQ = new Thread(startProc);\r
                     theQ.Start();\r
-                 }\r
+                }\r
             }\r
             catch (Exception exc)\r
             {\r
                 MessageBox.Show(exc.ToString());\r
             }\r
-             \r
         }\r
-        private void btn_cancel_Click(object sender, EventArgs e)\r
+\r
+        private void btn_stop_Click(object sender, EventArgs e)\r
         {\r
             cancel = true;\r
-            btn_cancel.Visible = false;\r
+            btn_stop.Visible = false;\r
             MessageBox.Show("No further items on the queue will start. The current encode process will continue until it is finished. \nClick 'Encode Video' when you wish to continue encoding the queue.", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning);\r
         }\r
 \r
@@ -167,7 +169,7 @@ namespace Handbrake
                     lbl_status.Text = "Encode Queue Completed!";\r
                     text_edit.Text = "";\r
                 }\r
-                btn_cancel.Visible = false;\r
+                btn_stop.Visible = false;\r
 \r
                 lbl_progressValue.Text = "0 %";\r
                 progressBar.Value = 0;\r
@@ -307,6 +309,61 @@ namespace Handbrake
 \r
         #endregion\r
 \r
+        #region Queue Save & Batch Script\r
+        private void btn_save_Click(object sender, EventArgs e)\r
+        {\r
+\r
+        }\r
+\r
+        private void btn_open_Click(object sender, EventArgs e)\r
+        {\r
+\r
+        }\r
+\r
+        private void btn_batch_Click(object sender, EventArgs e)\r
+        {\r
+            string queries = "";\r
+            for (int i = 0; i < list_queue.Items.Count; i++)\r
+            {\r
+                string query = list_queue.Items[i].ToString();\r
+                string fullQuery = '"' + Application.StartupPath.ToString()+ "\\HandBrakeCLI.exe"+ '"' + query;\r
+\r
+                if (queries == "")\r
+                    queries = queries + fullQuery;\r
+                else\r
+                    queries = queries + " && " + fullQuery;\r
+            }\r
+            string strCmdLine = queries;\r
+\r
+            SaveFile.ShowDialog();\r
+            string filename = SaveFile.FileName;\r
+\r
+            if (filename != "")\r
+            {\r
+                try\r
+                {\r
+                    // Create a StreamWriter and open the file\r
+                    StreamWriter line = new StreamWriter(filename);\r
+\r
+                    // Write the batch file query to the file\r
+                    line.WriteLine(strCmdLine);\r
+\r
+                    // close the stream\r
+                    line.Close();\r
+\r
+                    MessageBox.Show("Your batch script has been sucessfully saved.", "Status", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);\r
+                }\r
+                catch (Exception)\r
+                {\r
+                    MessageBox.Show("Unable to write to the file. Please make sure that the location has the correct permissions for file writing.", "Error", MessageBoxButtons.OK, MessageBoxIcon.Hand);\r
+                }\r
+\r
+            }\r
+        }\r
+\r
+        #endregion\r
+\r
+        #region other\r
         private void btn_Close_Click(object sender, EventArgs e)\r
         {\r
             this.Hide();\r
@@ -318,6 +375,6 @@ namespace Handbrake
             this.Hide();\r
             base.OnClosing(e);\r
         }\r
-\r
+        #endregion\r
     }\r
 }
\ No newline at end of file
index 2ddcb69..11e5d9b 100644 (file)
   <metadata name="toolTip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">\r
     <value>17, 17</value>\r
   </metadata>\r
+  <metadata name="toolStrip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">\r
+    <value>109, 17</value>\r
+  </metadata>\r
+  <metadata name="SaveFile.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">\r
+    <value>208, 17</value>\r
+  </metadata>\r
   <assembly alias="System.Drawing" name="System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />\r
   <data name="$this.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">\r
     <value>\r