summaryrefslogtreecommitdiffstats
path: root/win/CS/HandBrake.ApplicationServices/Services/Encode.cs
diff options
context:
space:
mode:
Diffstat (limited to 'win/CS/HandBrake.ApplicationServices/Services/Encode.cs')
-rw-r--r--win/CS/HandBrake.ApplicationServices/Services/Encode.cs13
1 files changed, 8 insertions, 5 deletions
diff --git a/win/CS/HandBrake.ApplicationServices/Services/Encode.cs b/win/CS/HandBrake.ApplicationServices/Services/Encode.cs
index f0f1b656b..98827a6e3 100644
--- a/win/CS/HandBrake.ApplicationServices/Services/Encode.cs
+++ b/win/CS/HandBrake.ApplicationServices/Services/Encode.cs
@@ -15,8 +15,6 @@ namespace HandBrake.ApplicationServices.Services
using System.Threading;
using System.Windows.Forms;
- using Caliburn.Micro;
-
using HandBrake.ApplicationServices.EventArgs;
using HandBrake.ApplicationServices.Model;
using HandBrake.ApplicationServices.Services.Base;
@@ -35,7 +33,7 @@ namespace HandBrake.ApplicationServices.Services
/// <summary>
/// The User Setting Service
/// </summary>
- private IUserSettingService userSettingService = IoC.Get<IUserSettingService>();
+ private readonly IUserSettingService userSettingService;
/// <summary>
/// Gets The Process Handle
@@ -62,8 +60,13 @@ namespace HandBrake.ApplicationServices.Services
/// <summary>
/// Initializes a new instance of the <see cref="Encode"/> class.
/// </summary>
- public Encode()
+ /// <param name="userSettingService">
+ /// The user Setting Service.
+ /// </param>
+ public Encode(IUserSettingService userSettingService)
+ : base(userSettingService)
{
+ this.userSettingService = userSettingService;
this.EncodeStarted += this.EncodeEncodeStarted;
GrowlCommunicator.Register();
}
@@ -116,7 +119,7 @@ namespace HandBrake.ApplicationServices.Services
if (this.userSettingService.GetUserSetting<bool>(ASUserSettingConstants.PreventSleep))
{
- Win32.PreventSleep();
+ // Win32.PreventSleep();
}
// Make sure the path exists, attempt to create it if it doesn't