summaryrefslogtreecommitdiffstats
path: root/win/CS/HandBrake.ApplicationServices
diff options
context:
space:
mode:
authorsr55 <[email protected]>2012-07-20 17:06:08 +0000
committersr55 <[email protected]>2012-07-20 17:06:08 +0000
commit7f7055ee54f9dfb0cdad5c73841452fd8491f51e (patch)
tree88bb4b64e1a2ef82b11bbb8c2a89d41aaabac30e /win/CS/HandBrake.ApplicationServices
parent1aadfe267e451acfbc900590a53cd9df87fe50ff (diff)
WinGui: Move some stuff around in the services library and refactor out some legacy code.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4868 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/CS/HandBrake.ApplicationServices')
-rw-r--r--win/CS/HandBrake.ApplicationServices/Converters/EnumToDescConverter.cs2
-rw-r--r--win/CS/HandBrake.ApplicationServices/HandBrake.ApplicationServices.csproj17
-rw-r--r--win/CS/HandBrake.ApplicationServices/Model/Encoding/AudioTrack.cs2
-rw-r--r--win/CS/HandBrake.ApplicationServices/Parsing/Subtitle.cs2
-rw-r--r--win/CS/HandBrake.ApplicationServices/Parsing/Title.cs4
-rw-r--r--win/CS/HandBrake.ApplicationServices/ServiceManager.cs49
-rw-r--r--win/CS/HandBrake.ApplicationServices/Services/Base/EncodeBase.cs5
-rw-r--r--win/CS/HandBrake.ApplicationServices/Services/Encode.cs8
-rw-r--r--win/CS/HandBrake.ApplicationServices/Services/LibEncode.cs11
-rw-r--r--win/CS/HandBrake.ApplicationServices/Services/LibScan.cs7
-rw-r--r--win/CS/HandBrake.ApplicationServices/Services/PresetService.cs4
-rw-r--r--win/CS/HandBrake.ApplicationServices/Services/QueueProcessor.cs2
-rw-r--r--win/CS/HandBrake.ApplicationServices/Services/ScanService.cs6
-rw-r--r--win/CS/HandBrake.ApplicationServices/Utilities/Converters.cs (renamed from win/CS/HandBrake.ApplicationServices/Functions/Converters.cs)5
-rw-r--r--win/CS/HandBrake.ApplicationServices/Utilities/EnumHelper.cs (renamed from win/CS/HandBrake.ApplicationServices/Functions/EnumHelper.cs)2
-rw-r--r--win/CS/HandBrake.ApplicationServices/Utilities/GeneralUtilities.cs1
-rw-r--r--win/CS/HandBrake.ApplicationServices/Utilities/GrowlCommunicator.cs (renamed from win/CS/HandBrake.ApplicationServices/Functions/GrowlCommunicator.cs)2
-rw-r--r--win/CS/HandBrake.ApplicationServices/Utilities/InteropModelCreator.cs (renamed from win/CS/HandBrake.ApplicationServices/Functions/InteropModelCreator.cs)4
-rw-r--r--win/CS/HandBrake.ApplicationServices/Utilities/PlistHelper.cs (renamed from win/CS/HandBrake.ApplicationServices/Functions/PlistHelper.cs)2
-rw-r--r--win/CS/HandBrake.ApplicationServices/Utilities/PlistUtility.cs5
-rw-r--r--win/CS/HandBrake.ApplicationServices/Utilities/QueryGeneratorUtility.cs5
-rw-r--r--win/CS/HandBrake.ApplicationServices/Utilities/QueryParserUtility.cs1
-rw-r--r--win/CS/HandBrake.ApplicationServices/Utilities/SystemInfo.cs (renamed from win/CS/HandBrake.ApplicationServices/Functions/SystemInfo.cs)2
-rw-r--r--win/CS/HandBrake.ApplicationServices/Utilities/Win32.cs (renamed from win/CS/HandBrake.ApplicationServices/Functions/Win32.cs)4
-rw-r--r--win/CS/HandBrake.ApplicationServices/Utilities/Win7.cs (renamed from win/CS/HandBrake.ApplicationServices/Functions/Win7.cs)2
25 files changed, 59 insertions, 95 deletions
diff --git a/win/CS/HandBrake.ApplicationServices/Converters/EnumToDescConverter.cs b/win/CS/HandBrake.ApplicationServices/Converters/EnumToDescConverter.cs
index a9cc5410b..d53905361 100644
--- a/win/CS/HandBrake.ApplicationServices/Converters/EnumToDescConverter.cs
+++ b/win/CS/HandBrake.ApplicationServices/Converters/EnumToDescConverter.cs
@@ -12,7 +12,7 @@ namespace HandBrake.ApplicationServices.Converters
using System;
using System.ComponentModel;
- using HandBrake.ApplicationServices.Functions;
+ using HandBrake.ApplicationServices.Utilities;
/// <summary>
/// Enum to Description Converter
diff --git a/win/CS/HandBrake.ApplicationServices/HandBrake.ApplicationServices.csproj b/win/CS/HandBrake.ApplicationServices/HandBrake.ApplicationServices.csproj
index 7fa820e4c..705911f4a 100644
--- a/win/CS/HandBrake.ApplicationServices/HandBrake.ApplicationServices.csproj
+++ b/win/CS/HandBrake.ApplicationServices/HandBrake.ApplicationServices.csproj
@@ -100,14 +100,14 @@
<Compile Include="EventArgs\ScanCompletedEventArgs.cs" />
<Compile Include="EventArgs\ScanProgressEventArgs.cs" />
<Compile Include="Extensions\StringExtensions.cs" />
- <Compile Include="Functions\Converters.cs" />
- <Compile Include="Functions\EnumHelper.cs" />
- <Compile Include="Functions\GrowlCommunicator.cs" />
- <Compile Include="Functions\InteropModelCreator.cs" />
- <Compile Include="Functions\PlistHelper.cs" />
- <Compile Include="Functions\SystemInfo.cs" />
- <Compile Include="Functions\Win32.cs" />
- <Compile Include="Functions\Win7.cs" />
+ <Compile Include="Utilities\Converters.cs" />
+ <Compile Include="Utilities\EnumHelper.cs" />
+ <Compile Include="Utilities\GrowlCommunicator.cs" />
+ <Compile Include="Utilities\InteropModelCreator.cs" />
+ <Compile Include="Utilities\PlistHelper.cs" />
+ <Compile Include="Utilities\SystemInfo.cs" />
+ <Compile Include="Utilities\Win32.cs" />
+ <Compile Include="Utilities\Win7.cs" />
<Compile Include="Model\DriveInformation.cs" />
<Compile Include="Model\Encoding\AllowedPassthru.cs" />
<Compile Include="Model\Encoding\AudioTrack.cs" />
@@ -134,7 +134,6 @@
<DesignTime>True</DesignTime>
<DependentUpon>Resources.resx</DependentUpon>
</Compile>
- <Compile Include="ServiceManager.cs" />
<Compile Include="ServicesWindsorInstaller.cs" />
<Compile Include="Services\Base\EncodeBase.cs" />
<Compile Include="Services\Encode.cs" />
diff --git a/win/CS/HandBrake.ApplicationServices/Model/Encoding/AudioTrack.cs b/win/CS/HandBrake.ApplicationServices/Model/Encoding/AudioTrack.cs
index 828fc6a70..7af4806f7 100644
--- a/win/CS/HandBrake.ApplicationServices/Model/Encoding/AudioTrack.cs
+++ b/win/CS/HandBrake.ApplicationServices/Model/Encoding/AudioTrack.cs
@@ -15,8 +15,8 @@ namespace HandBrake.ApplicationServices.Model.Encoding
using Caliburn.Micro;
- using HandBrake.ApplicationServices.Functions;
using HandBrake.ApplicationServices.Parsing;
+ using HandBrake.ApplicationServices.Utilities;
using HandBrake.Interop.Model.Encoding;
/// <summary>
diff --git a/win/CS/HandBrake.ApplicationServices/Parsing/Subtitle.cs b/win/CS/HandBrake.ApplicationServices/Parsing/Subtitle.cs
index 20deeae1b..34a919908 100644
--- a/win/CS/HandBrake.ApplicationServices/Parsing/Subtitle.cs
+++ b/win/CS/HandBrake.ApplicationServices/Parsing/Subtitle.cs
@@ -14,8 +14,8 @@ namespace HandBrake.ApplicationServices.Parsing
using System.IO;
using System.Text.RegularExpressions;
- using HandBrake.ApplicationServices.Functions;
using HandBrake.ApplicationServices.Model.Encoding;
+ using HandBrake.ApplicationServices.Utilities;
/// <summary>
/// An object that represents a subtitle associated with a Title, in a DVD
diff --git a/win/CS/HandBrake.ApplicationServices/Parsing/Title.cs b/win/CS/HandBrake.ApplicationServices/Parsing/Title.cs
index 8b3667271..454627fa9 100644
--- a/win/CS/HandBrake.ApplicationServices/Parsing/Title.cs
+++ b/win/CS/HandBrake.ApplicationServices/Parsing/Title.cs
@@ -16,6 +16,8 @@ namespace HandBrake.ApplicationServices.Parsing
using System.Linq;
using System.Text.RegularExpressions;
+ using Caliburn.Micro;
+
using HandBrake.ApplicationServices.Services.Interfaces;
using HandBrake.Interop.Model;
@@ -29,7 +31,7 @@ namespace HandBrake.ApplicationServices.Parsing
/// <summary>
/// The User Setting Service
/// </summary>
- private static IUserSettingService userSettingService = ServiceManager.UserSettingService;
+ private static IUserSettingService userSettingService = IoC.Get<IUserSettingService>();
/// <summary>
/// Initializes a new instance of the <see cref="Title"/> class.
diff --git a/win/CS/HandBrake.ApplicationServices/ServiceManager.cs b/win/CS/HandBrake.ApplicationServices/ServiceManager.cs
deleted file mode 100644
index 41775a287..000000000
--- a/win/CS/HandBrake.ApplicationServices/ServiceManager.cs
+++ /dev/null
@@ -1,49 +0,0 @@
-// --------------------------------------------------------------------------------------------------------------------
-// <copyright file="ServiceManager.cs" company="HandBrake Project (http://handbrake.fr)">
-// This file is part of the HandBrake source code - It may be used under the terms of the GNU General Public License.
-// </copyright>
-// <summary>
-// Tempory Class which manages services until Windosor is added back into the project to handle it for us.
-// </summary>
-// --------------------------------------------------------------------------------------------------------------------
-
-namespace HandBrake.ApplicationServices
-{
- using Caliburn.Micro;
-
- using HandBrake.ApplicationServices.Services.Interfaces;
- using HandBrake.Interop;
-
- /// <summary>
- /// Tempory Class which manages services until Windosor is added back into the project to handle it for us.
- /// </summary>
- public class ServiceManager
- {
- /// <summary>
- /// The Backing field for HandBrake Instance.
- /// </summary>
- private static HandBrakeInstance handBrakeInstance;
-
- /// <summary>
- /// Gets UserSettingService.
- /// </summary>
- public static IUserSettingService UserSettingService
- {
- get
- {
- return IoC.Get<IUserSettingService>();
- }
- }
-
- /// <summary>
- /// Gets HandBrakeInstance.
- /// </summary>
- public static HandBrakeInstance HandBrakeInstance
- {
- get
- {
- return handBrakeInstance ?? (handBrakeInstance = new HandBrakeInstance());
- }
- }
- }
-}
diff --git a/win/CS/HandBrake.ApplicationServices/Services/Base/EncodeBase.cs b/win/CS/HandBrake.ApplicationServices/Services/Base/EncodeBase.cs
index e04c4e830..e20215bcf 100644
--- a/win/CS/HandBrake.ApplicationServices/Services/Base/EncodeBase.cs
+++ b/win/CS/HandBrake.ApplicationServices/Services/Base/EncodeBase.cs
@@ -13,9 +13,10 @@ namespace HandBrake.ApplicationServices.Services.Base
using System.IO;
using System.Text;
+ using Caliburn.Micro;
+
using HandBrake.ApplicationServices.EventArgs;
using HandBrake.ApplicationServices.Exceptions;
- using HandBrake.ApplicationServices.Functions;
using HandBrake.ApplicationServices.Model;
using HandBrake.ApplicationServices.Services.Interfaces;
using HandBrake.ApplicationServices.Utilities;
@@ -35,7 +36,7 @@ namespace HandBrake.ApplicationServices.Services.Base
/// <summary>
/// The User Setting Service
/// </summary>
- private IUserSettingService userSettingService = ServiceManager.UserSettingService;
+ private IUserSettingService userSettingService = IoC.Get<IUserSettingService>();
/// <summary>
/// Windows 7 API Pack wrapper
diff --git a/win/CS/HandBrake.ApplicationServices/Services/Encode.cs b/win/CS/HandBrake.ApplicationServices/Services/Encode.cs
index 7553456d5..f0f1b656b 100644
--- a/win/CS/HandBrake.ApplicationServices/Services/Encode.cs
+++ b/win/CS/HandBrake.ApplicationServices/Services/Encode.cs
@@ -15,14 +15,16 @@ namespace HandBrake.ApplicationServices.Services
using System.Threading;
using System.Windows.Forms;
+ using Caliburn.Micro;
+
using HandBrake.ApplicationServices.EventArgs;
- using HandBrake.ApplicationServices.Functions;
using HandBrake.ApplicationServices.Model;
- using HandBrake.ApplicationServices.Parsing;
using HandBrake.ApplicationServices.Services.Base;
using HandBrake.ApplicationServices.Services.Interfaces;
using HandBrake.ApplicationServices.Utilities;
+ using Parser = HandBrake.ApplicationServices.Parsing.Parser;
+
/// <summary>
/// Class which handles the CLI
/// </summary>
@@ -33,7 +35,7 @@ namespace HandBrake.ApplicationServices.Services
/// <summary>
/// The User Setting Service
/// </summary>
- private IUserSettingService userSettingService = ServiceManager.UserSettingService;
+ private IUserSettingService userSettingService = IoC.Get<IUserSettingService>();
/// <summary>
/// Gets The Process Handle
diff --git a/win/CS/HandBrake.ApplicationServices/Services/LibEncode.cs b/win/CS/HandBrake.ApplicationServices/Services/LibEncode.cs
index 1fe1845ad..086305f4e 100644
--- a/win/CS/HandBrake.ApplicationServices/Services/LibEncode.cs
+++ b/win/CS/HandBrake.ApplicationServices/Services/LibEncode.cs
@@ -12,11 +12,14 @@ namespace HandBrake.ApplicationServices.Services
using System;
using System.Diagnostics;
- using HandBrake.ApplicationServices.Functions;
+ using Caliburn.Micro;
+
using HandBrake.ApplicationServices.Model;
using HandBrake.ApplicationServices.Services.Base;
using HandBrake.ApplicationServices.Services.Interfaces;
+ using HandBrake.ApplicationServices.Utilities;
using HandBrake.Interop;
+ using HandBrake.Interop.Interfaces;
using HandBrake.Interop.Model;
using EncodeCompletedEventArgs = HandBrake.ApplicationServices.EventArgs.EncodeCompletedEventArgs;
@@ -37,7 +40,7 @@ namespace HandBrake.ApplicationServices.Services
/// <summary>
/// The User Setting Service
/// </summary>
- private IUserSettingService userSettingService = ServiceManager.UserSettingService;
+ private IUserSettingService userSettingService = IoC.Get<IUserSettingService>();
/// <summary>
/// The Start time of the current Encode;
@@ -47,7 +50,7 @@ namespace HandBrake.ApplicationServices.Services
/// <summary>
/// An Instance of the HandBrake Interop Library
/// </summary>
- private HandBrakeInstance instance;
+ private IHandBrakeInstance instance;
/// <summary>
/// A flag to indicate if logging is enabled or not.
@@ -62,7 +65,7 @@ namespace HandBrake.ApplicationServices.Services
public LibEncode()
{
// Setup the HandBrake Instance
- this.instance = ServiceManager.HandBrakeInstance;
+ this.instance = IoC.Get<IHandBrakeInstance>();
this.instance.EncodeCompleted += this.InstanceEncodeCompleted;
this.instance.EncodeProgress += this.InstanceEncodeProgress;
diff --git a/win/CS/HandBrake.ApplicationServices/Services/LibScan.cs b/win/CS/HandBrake.ApplicationServices/Services/LibScan.cs
index 4957a62bb..a25f3a2a6 100644
--- a/win/CS/HandBrake.ApplicationServices/Services/LibScan.cs
+++ b/win/CS/HandBrake.ApplicationServices/Services/LibScan.cs
@@ -14,12 +14,15 @@ namespace HandBrake.ApplicationServices.Services
using System.Text;
using System.Threading;
+ using Caliburn.Micro;
+
using HandBrake.ApplicationServices.EventArgs;
using HandBrake.ApplicationServices.Model.Encoding;
using HandBrake.ApplicationServices.Parsing;
using HandBrake.ApplicationServices.Services.Interfaces;
using HandBrake.ApplicationServices.Utilities;
using HandBrake.Interop;
+ using HandBrake.Interop.Interfaces;
using AudioTrack = HandBrake.ApplicationServices.Parsing.Audio;
using ScanProgressEventArgs = HandBrake.Interop.ScanProgressEventArgs;
@@ -47,7 +50,7 @@ namespace HandBrake.ApplicationServices.Services
/// <summary>
/// LibHB Instance
/// </summary>
- private readonly HandBrakeInstance instance;
+ private readonly IHandBrakeInstance instance;
/// <summary>
/// Log data from HandBrakeInstance
@@ -68,7 +71,7 @@ namespace HandBrake.ApplicationServices.Services
{
logging = new StringBuilder();
- instance = ServiceManager.HandBrakeInstance;
+ instance = IoC.Get<IHandBrakeInstance>();
instance.Initialize(1);
instance.ScanProgress += this.InstanceScanProgress;
instance.ScanCompleted += this.InstanceScanCompleted;
diff --git a/win/CS/HandBrake.ApplicationServices/Services/PresetService.cs b/win/CS/HandBrake.ApplicationServices/Services/PresetService.cs
index 8337ddd56..2ddd775aa 100644
--- a/win/CS/HandBrake.ApplicationServices/Services/PresetService.cs
+++ b/win/CS/HandBrake.ApplicationServices/Services/PresetService.cs
@@ -19,6 +19,8 @@ namespace HandBrake.ApplicationServices.Services
using System.Text.RegularExpressions;
using System.Xml.Serialization;
+ using Caliburn.Micro;
+
using HandBrake.ApplicationServices.Exceptions;
using HandBrake.ApplicationServices.Model;
using HandBrake.ApplicationServices.Services.Interfaces;
@@ -67,7 +69,7 @@ namespace HandBrake.ApplicationServices.Services
/// <summary>
/// The User Setting Service
/// </summary>
- private IUserSettingService userSettingService = ServiceManager.UserSettingService;
+ private IUserSettingService userSettingService = IoC.Get<IUserSettingService>();
#endregion
diff --git a/win/CS/HandBrake.ApplicationServices/Services/QueueProcessor.cs b/win/CS/HandBrake.ApplicationServices/Services/QueueProcessor.cs
index effe9f9b5..cd1ff226d 100644
--- a/win/CS/HandBrake.ApplicationServices/Services/QueueProcessor.cs
+++ b/win/CS/HandBrake.ApplicationServices/Services/QueueProcessor.cs
@@ -17,9 +17,9 @@ namespace HandBrake.ApplicationServices.Services
using Caliburn.Micro;
using HandBrake.ApplicationServices.EventArgs;
- using HandBrake.ApplicationServices.Functions;
using HandBrake.ApplicationServices.Model;
using HandBrake.ApplicationServices.Services.Interfaces;
+ using HandBrake.ApplicationServices.Utilities;
/// <summary>
/// The HandBrake Queue
diff --git a/win/CS/HandBrake.ApplicationServices/Services/ScanService.cs b/win/CS/HandBrake.ApplicationServices/Services/ScanService.cs
index 5eb1f0a37..7edbdb320 100644
--- a/win/CS/HandBrake.ApplicationServices/Services/ScanService.cs
+++ b/win/CS/HandBrake.ApplicationServices/Services/ScanService.cs
@@ -16,12 +16,16 @@ namespace HandBrake.ApplicationServices.Services
using System.Threading;
using System.Windows.Forms;
+ using Caliburn.Micro;
+
using HandBrake.ApplicationServices.EventArgs;
using HandBrake.ApplicationServices.Exceptions;
using HandBrake.ApplicationServices.Parsing;
using HandBrake.ApplicationServices.Services.Interfaces;
using HandBrake.ApplicationServices.Utilities;
+ using Parser = HandBrake.ApplicationServices.Parsing.Parser;
+
/// <summary>
/// Scan a Source
/// </summary>
@@ -52,7 +56,7 @@ namespace HandBrake.ApplicationServices.Services
/// <summary>
/// The User Setting Service
/// </summary>
- private IUserSettingService userSettingService = ServiceManager.UserSettingService;
+ private IUserSettingService userSettingService = IoC.Get<IUserSettingService>();
#endregion
diff --git a/win/CS/HandBrake.ApplicationServices/Functions/Converters.cs b/win/CS/HandBrake.ApplicationServices/Utilities/Converters.cs
index 2f930f30f..e2b11d4b8 100644
--- a/win/CS/HandBrake.ApplicationServices/Functions/Converters.cs
+++ b/win/CS/HandBrake.ApplicationServices/Utilities/Converters.cs
@@ -7,16 +7,15 @@
// </summary>
// --------------------------------------------------------------------------------------------------------------------
-namespace HandBrake.ApplicationServices.Functions
+namespace HandBrake.ApplicationServices.Utilities
{
using System;
using System.Text.RegularExpressions;
+ using HandBrake.ApplicationServices.Model.Encoding;
using HandBrake.Interop.Model.Encoding;
using HandBrake.Interop.Model.Encoding.x264;
- using OutputFormat = HandBrake.ApplicationServices.Model.Encoding.OutputFormat;
-
/// <summary>
/// A class to convert various things to native C# objects
/// </summary>
diff --git a/win/CS/HandBrake.ApplicationServices/Functions/EnumHelper.cs b/win/CS/HandBrake.ApplicationServices/Utilities/EnumHelper.cs
index fa1a8df3e..d6c972b5e 100644
--- a/win/CS/HandBrake.ApplicationServices/Functions/EnumHelper.cs
+++ b/win/CS/HandBrake.ApplicationServices/Utilities/EnumHelper.cs
@@ -7,7 +7,7 @@
// </summary>
// --------------------------------------------------------------------------------------------------------------------
-namespace HandBrake.ApplicationServices.Functions
+namespace HandBrake.ApplicationServices.Utilities
{
using System;
using System.Collections.Generic;
diff --git a/win/CS/HandBrake.ApplicationServices/Utilities/GeneralUtilities.cs b/win/CS/HandBrake.ApplicationServices/Utilities/GeneralUtilities.cs
index 773de5bfc..83ea717e0 100644
--- a/win/CS/HandBrake.ApplicationServices/Utilities/GeneralUtilities.cs
+++ b/win/CS/HandBrake.ApplicationServices/Utilities/GeneralUtilities.cs
@@ -19,7 +19,6 @@ namespace HandBrake.ApplicationServices.Utilities
using Caliburn.Micro;
- using HandBrake.ApplicationServices.Functions;
using HandBrake.ApplicationServices.Model;
using HandBrake.ApplicationServices.Services.Interfaces;
diff --git a/win/CS/HandBrake.ApplicationServices/Functions/GrowlCommunicator.cs b/win/CS/HandBrake.ApplicationServices/Utilities/GrowlCommunicator.cs
index ca195c000..d49924ed0 100644
--- a/win/CS/HandBrake.ApplicationServices/Functions/GrowlCommunicator.cs
+++ b/win/CS/HandBrake.ApplicationServices/Utilities/GrowlCommunicator.cs
@@ -7,7 +7,7 @@
// </summary>
// --------------------------------------------------------------------------------------------------------------------
-namespace HandBrake.ApplicationServices.Functions
+namespace HandBrake.ApplicationServices.Utilities
{
using System;
diff --git a/win/CS/HandBrake.ApplicationServices/Functions/InteropModelCreator.cs b/win/CS/HandBrake.ApplicationServices/Utilities/InteropModelCreator.cs
index e58e1a5fe..6a5be06cb 100644
--- a/win/CS/HandBrake.ApplicationServices/Functions/InteropModelCreator.cs
+++ b/win/CS/HandBrake.ApplicationServices/Utilities/InteropModelCreator.cs
@@ -7,7 +7,7 @@
// </summary>
// --------------------------------------------------------------------------------------------------------------------
-namespace HandBrake.ApplicationServices.Functions
+namespace HandBrake.ApplicationServices.Utilities
{
using System;
using System.Collections.Generic;
@@ -18,8 +18,6 @@ namespace HandBrake.ApplicationServices.Functions
using HandBrake.Interop.Model;
using HandBrake.Interop.Model.Encoding;
- using OutputFormat = HandBrake.ApplicationServices.Model.Encoding.OutputFormat;
-
/// <summary>
/// A Utility Class to Convert a
/// </summary>
diff --git a/win/CS/HandBrake.ApplicationServices/Functions/PlistHelper.cs b/win/CS/HandBrake.ApplicationServices/Utilities/PlistHelper.cs
index 478e21b83..f5e810771 100644
--- a/win/CS/HandBrake.ApplicationServices/Functions/PlistHelper.cs
+++ b/win/CS/HandBrake.ApplicationServices/Utilities/PlistHelper.cs
@@ -7,7 +7,7 @@
// </summary>
// --------------------------------------------------------------------------------------------------------------------
-namespace HandBrake.ApplicationServices.Functions
+namespace HandBrake.ApplicationServices.Utilities
{
using System;
using System.Collections.Generic;
diff --git a/win/CS/HandBrake.ApplicationServices/Utilities/PlistUtility.cs b/win/CS/HandBrake.ApplicationServices/Utilities/PlistUtility.cs
index 6cf009285..dcedefad9 100644
--- a/win/CS/HandBrake.ApplicationServices/Utilities/PlistUtility.cs
+++ b/win/CS/HandBrake.ApplicationServices/Utilities/PlistUtility.cs
@@ -16,7 +16,8 @@ namespace HandBrake.ApplicationServices.Utilities
using System.Windows.Forms;
using System.Xml;
- using HandBrake.ApplicationServices.Functions;
+ using Caliburn.Micro;
+
using HandBrake.ApplicationServices.Model;
using HandBrake.ApplicationServices.Model.Encoding;
using HandBrake.ApplicationServices.Services;
@@ -31,7 +32,7 @@ namespace HandBrake.ApplicationServices.Utilities
/// <summary>
/// The User Setting Service
/// </summary>
- private static IUserSettingService userSettingService = ServiceManager.UserSettingService;
+ private static IUserSettingService userSettingService = IoC.Get<IUserSettingService>();
#region Import
diff --git a/win/CS/HandBrake.ApplicationServices/Utilities/QueryGeneratorUtility.cs b/win/CS/HandBrake.ApplicationServices/Utilities/QueryGeneratorUtility.cs
index 7e1c0bf41..4b5071984 100644
--- a/win/CS/HandBrake.ApplicationServices/Utilities/QueryGeneratorUtility.cs
+++ b/win/CS/HandBrake.ApplicationServices/Utilities/QueryGeneratorUtility.cs
@@ -15,7 +15,8 @@ namespace HandBrake.ApplicationServices.Utilities
using System.Globalization;
using System.IO;
- using HandBrake.ApplicationServices.Functions;
+ using Caliburn.Micro;
+
using HandBrake.ApplicationServices.Model;
using HandBrake.ApplicationServices.Model.Encoding;
using HandBrake.ApplicationServices.Services.Interfaces;
@@ -30,7 +31,7 @@ namespace HandBrake.ApplicationServices.Utilities
/// <summary>
/// Backing field for the user settings service.
/// </summary>
- private static readonly IUserSettingService UserSettingService = ServiceManager.UserSettingService;
+ private static readonly IUserSettingService UserSettingService = IoC.Get<IUserSettingService>();
/// <summary>
/// Generate a CLI Query for an EncodeTask Model object
diff --git a/win/CS/HandBrake.ApplicationServices/Utilities/QueryParserUtility.cs b/win/CS/HandBrake.ApplicationServices/Utilities/QueryParserUtility.cs
index 9824ec44f..e16274fe6 100644
--- a/win/CS/HandBrake.ApplicationServices/Utilities/QueryParserUtility.cs
+++ b/win/CS/HandBrake.ApplicationServices/Utilities/QueryParserUtility.cs
@@ -16,7 +16,6 @@ namespace HandBrake.ApplicationServices.Utilities
using System.Linq;
using System.Text.RegularExpressions;
- using HandBrake.ApplicationServices.Functions;
using HandBrake.ApplicationServices.Model;
using HandBrake.ApplicationServices.Model.Encoding;
using HandBrake.Interop.Model;
diff --git a/win/CS/HandBrake.ApplicationServices/Functions/SystemInfo.cs b/win/CS/HandBrake.ApplicationServices/Utilities/SystemInfo.cs
index 86a97ca11..32328ab47 100644
--- a/win/CS/HandBrake.ApplicationServices/Functions/SystemInfo.cs
+++ b/win/CS/HandBrake.ApplicationServices/Utilities/SystemInfo.cs
@@ -7,7 +7,7 @@
// </summary>
// --------------------------------------------------------------------------------------------------------------------
-namespace HandBrake.ApplicationServices.Functions
+namespace HandBrake.ApplicationServices.Utilities
{
using System.Windows.Forms;
diff --git a/win/CS/HandBrake.ApplicationServices/Functions/Win32.cs b/win/CS/HandBrake.ApplicationServices/Utilities/Win32.cs
index f9d031d5c..892c4bcad 100644
--- a/win/CS/HandBrake.ApplicationServices/Functions/Win32.cs
+++ b/win/CS/HandBrake.ApplicationServices/Utilities/Win32.cs
@@ -7,7 +7,7 @@
// </summary>
// --------------------------------------------------------------------------------------------------------------------
-namespace HandBrake.ApplicationServices.Functions
+namespace HandBrake.ApplicationServices.Utilities
{
using System;
using System.Runtime.InteropServices;
@@ -134,7 +134,7 @@ namespace HandBrake.ApplicationServices.Functions
/// <summary>
/// Execution State
/// </summary>
- [FlagsAttribute]
+ [Flags]
public enum EXECUTION_STATE : uint
{
ES_SYSTEM_REQUIRED = 0x00000001,
diff --git a/win/CS/HandBrake.ApplicationServices/Functions/Win7.cs b/win/CS/HandBrake.ApplicationServices/Utilities/Win7.cs
index c12ac56e4..5c5b78049 100644
--- a/win/CS/HandBrake.ApplicationServices/Functions/Win7.cs
+++ b/win/CS/HandBrake.ApplicationServices/Utilities/Win7.cs
@@ -7,7 +7,7 @@
// </summary>
// --------------------------------------------------------------------------------------------------------------------
-namespace HandBrake.ApplicationServices.Functions
+namespace HandBrake.ApplicationServices.Utilities
{
using Microsoft.WindowsAPICodePack.Taskbar;