OSDN Git Service

WinGui:
[handbrake-jp/handbrake-jp-git.git] / win / C# / HandBrake.ApplicationServices / Services / QueueProcessor.cs
index ff865e2..130e1fc 100644 (file)
@@ -197,6 +197,12 @@ namespace HandBrake.ApplicationServices.Services
                 GrowlCommunicator.Notify("Encode Completed",\r
                                          "Put down that cocktail...\nyour Handbrake encode is done.");\r
 \r
+            if (!e.Successful)\r
+            {\r
+                this.Pause();\r
+                MessageBox.Show(e.Exception + e.ErrorInformation);\r
+            }\r
+\r
             // Handling Log Data \r
             this.EncodeService.ProcessLogs(this.QueueManager.LastProcessedJob.Destination);\r
 \r
@@ -209,9 +215,10 @@ namespace HandBrake.ApplicationServices.Services
         /// </summary>\r
         private void ProcessNextJob()\r
         {\r
-            if (this.EncodeService.IsEncoding)\r
+            if (this.EncodeService.IsEncoding || !this.IsProcessing)\r
             {\r
                 // We don't want to try start a second encode, so just return out. The event will trigger the next encode automatically.\r
+                // Also, we don't want to start a new encode if we are paused.\r
                 return;\r
             }\r
 \r