summaryrefslogtreecommitdiffstats
path: root/win/CS/HandBrake.ApplicationServices/Services
diff options
context:
space:
mode:
authorsr55 <[email protected]>2011-09-11 13:32:33 +0000
committersr55 <[email protected]>2011-09-11 13:32:33 +0000
commit609dbfdcf8cda1035b1af3af6b2a2598d72d602d (patch)
tree9470ac002bbffa54c49aba8b72c475873ee203a7 /win/CS/HandBrake.ApplicationServices/Services
parent44ba40eb45932d432fd51aec058b4b7d08957857 (diff)
WinGui: Some further work removing duplicate models, updating the libscan/encode services, fixes to the EnumHelper
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4215 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/CS/HandBrake.ApplicationServices/Services')
-rw-r--r--win/CS/HandBrake.ApplicationServices/Services/LibEncode.cs6
-rw-r--r--win/CS/HandBrake.ApplicationServices/Services/LibScan.cs2
-rw-r--r--win/CS/HandBrake.ApplicationServices/Services/QueueProcessor.cs3
3 files changed, 4 insertions, 7 deletions
diff --git a/win/CS/HandBrake.ApplicationServices/Services/LibEncode.cs b/win/CS/HandBrake.ApplicationServices/Services/LibEncode.cs
index 57f4b18fd..99e8be748 100644
--- a/win/CS/HandBrake.ApplicationServices/Services/LibEncode.cs
+++ b/win/CS/HandBrake.ApplicationServices/Services/LibEncode.cs
@@ -7,8 +7,6 @@ namespace HandBrake.ApplicationServices.Services
{
using System;
using System.Diagnostics;
- using System.Text;
- using System.Threading;
using HandBrake.ApplicationServices.Functions;
using HandBrake.ApplicationServices.Model;
@@ -60,7 +58,7 @@ namespace HandBrake.ApplicationServices.Services
public LibEncode()
{
// Setup the HandBrake Instance
- this.instance = new HandBrakeInstance();
+ this.instance = ServiceManager.HandBrakeInstance;
this.instance.EncodeCompleted += this.InstanceEncodeCompleted;
this.instance.EncodeProgress += this.InstanceEncodeProgress;
@@ -81,8 +79,6 @@ namespace HandBrake.ApplicationServices.Services
/// </param>
public void Start(QueueTask job, bool enableLogging)
{
- throw new NotImplementedException("This Method has not been completed yet");
-
this.startTime = DateTime.Now;
this.loggingEnabled = enableLogging;
diff --git a/win/CS/HandBrake.ApplicationServices/Services/LibScan.cs b/win/CS/HandBrake.ApplicationServices/Services/LibScan.cs
index 33459a0dd..3e2e166ce 100644
--- a/win/CS/HandBrake.ApplicationServices/Services/LibScan.cs
+++ b/win/CS/HandBrake.ApplicationServices/Services/LibScan.cs
@@ -59,7 +59,7 @@ namespace HandBrake.ApplicationServices.Services
{
logging = new StringBuilder();
- instance = new HandBrakeInstance();
+ instance = ServiceManager.HandBrakeInstance;
instance.Initialize(1);
instance.ScanProgress += this.InstanceScanProgress;
instance.ScanCompleted += this.InstanceScanCompleted;
diff --git a/win/CS/HandBrake.ApplicationServices/Services/QueueProcessor.cs b/win/CS/HandBrake.ApplicationServices/Services/QueueProcessor.cs
index 91667debe..e9342ca4e 100644
--- a/win/CS/HandBrake.ApplicationServices/Services/QueueProcessor.cs
+++ b/win/CS/HandBrake.ApplicationServices/Services/QueueProcessor.cs
@@ -7,6 +7,7 @@ namespace HandBrake.ApplicationServices.Services
{
using System;
using System.Diagnostics;
+ using System.IO;
using System.Windows.Forms;
using HandBrake.ApplicationServices.EventArgs;
@@ -62,7 +63,7 @@ namespace HandBrake.ApplicationServices.Services
/// </param>
public QueueProcessor(int instanceId)
{
- this.EncodeService = new Encode();
+ this.EncodeService = File.Exists("hb.dll") ? (IEncode)new LibEncode() : new Encode();
this.QueueManager = new QueueManager(instanceId);
}