summaryrefslogtreecommitdiffstats
path: root/win/CS
diff options
context:
space:
mode:
authorScott <[email protected]>2015-09-18 21:51:45 +0100
committerScott <[email protected]>2015-09-18 21:51:45 +0100
commit5b446548672626c960b8c72db72d8e6f82b7e955 (patch)
treeb9b68a36081d272df15de4f6584d024ff800cb5c /win/CS
parent7e266c63e5241289d6fb9645ea932a35de07bb18 (diff)
WinGui: Strip out some old unused code.
Diffstat (limited to 'win/CS')
-rw-r--r--win/CS/HandBrake.ApplicationServices/Interop/Factories/AnamorphicFactory.cs11
-rw-r--r--win/CS/HandBrakeWPF/AppArguments.cs18
-rw-r--r--win/CS/HandBrakeWPF/HandBrakeWPF.csproj3
-rw-r--r--win/CS/HandBrakeWPF/Services/Interfaces/INotificationService.cs18
-rw-r--r--win/CS/HandBrakeWPF/Services/NotificationService.cs82
-rw-r--r--win/CS/HandBrakeWPF/Services/UpdateService.cs10
-rw-r--r--win/CS/HandBrakeWPF/Startup/AppBootstrapper.cs1
-rw-r--r--win/CS/HandBrakeWPF/UserSettingConstants.cs15
-rw-r--r--win/CS/HandBrakeWPF/Utilities/HandBrakeApp.cs4
-rw-r--r--win/CS/HandBrakeWPF/ViewModels/MainViewModel.cs7
-rw-r--r--win/CS/HandBrakeWPF/ViewModels/OptionsViewModel.cs48
-rw-r--r--win/CS/HandBrakeWPF/Views/OptionsView.xaml5
12 files changed, 2 insertions, 220 deletions
diff --git a/win/CS/HandBrake.ApplicationServices/Interop/Factories/AnamorphicFactory.cs b/win/CS/HandBrake.ApplicationServices/Interop/Factories/AnamorphicFactory.cs
index 35ec20ba9..5d095cc2c 100644
--- a/win/CS/HandBrake.ApplicationServices/Interop/Factories/AnamorphicFactory.cs
+++ b/win/CS/HandBrake.ApplicationServices/Interop/Factories/AnamorphicFactory.cs
@@ -27,19 +27,8 @@ namespace HandBrake.ApplicationServices.Interop.Factories
/// </summary>
public enum KeepSetting
{
- /// <summary>
- /// The h b_ kee p_ width.
- /// </summary>
HB_KEEP_WIDTH = 0x01,
-
- /// <summary>
- /// The h b_ kee p_ height.
- /// </summary>
HB_KEEP_HEIGHT = 0x02,
-
- /// <summary>
- /// The h b_ kee p_ displa y_ aspect.
- /// </summary>
HB_KEEP_DISPLAY_ASPECT = 0x04
}
diff --git a/win/CS/HandBrakeWPF/AppArguments.cs b/win/CS/HandBrakeWPF/AppArguments.cs
deleted file mode 100644
index c673a8fa1..000000000
--- a/win/CS/HandBrakeWPF/AppArguments.cs
+++ /dev/null
@@ -1,18 +0,0 @@
-// --------------------------------------------------------------------------------------------------------------------
-// <copyright file="AppArguments.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>
-// Defines the AppArguments type.
-// </summary>
-// --------------------------------------------------------------------------------------------------------------------
-
-namespace HandBrakeWPF
-{
- /// <summary>
- /// The app arguments.
- /// </summary>
- public class AppArguments
- {
- }
-}
diff --git a/win/CS/HandBrakeWPF/HandBrakeWPF.csproj b/win/CS/HandBrakeWPF/HandBrakeWPF.csproj
index b0a55aacf..bd638e860 100644
--- a/win/CS/HandBrakeWPF/HandBrakeWPF.csproj
+++ b/win/CS/HandBrakeWPF/HandBrakeWPF.csproj
@@ -126,7 +126,6 @@
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</ApplicationDefinition>
- <Compile Include="AppArguments.cs" />
<Compile Include="AttachedProperties\MenuItemExtensions.cs" />
<Compile Include="Collections\SerializableDictionary.cs" />
<Compile Include="Commands\InputBindingTrigger.cs" />
@@ -237,10 +236,8 @@
<Compile Include="Model\SourceMenuItem.cs" />
<Compile Include="Model\UpdateCheckInformation.cs" />
<Compile Include="Model\DownloadStatus.cs" />
- <Compile Include="Services\Interfaces\INotificationService.cs" />
<Compile Include="Services\Interfaces\IUpdateService.cs" />
<Compile Include="Services\Interfaces\IPrePostActionService.cs" />
- <Compile Include="Services\NotificationService.cs" />
<Compile Include="Services\UpdateService.cs" />
<Compile Include="Services\PrePostActionService.cs" />
<Compile Include="ViewModels\AdvancedViewModel.cs" />
diff --git a/win/CS/HandBrakeWPF/Services/Interfaces/INotificationService.cs b/win/CS/HandBrakeWPF/Services/Interfaces/INotificationService.cs
deleted file mode 100644
index 8a20c274e..000000000
--- a/win/CS/HandBrakeWPF/Services/Interfaces/INotificationService.cs
+++ /dev/null
@@ -1,18 +0,0 @@
-// --------------------------------------------------------------------------------------------------------------------
-// <copyright file="INotificationService.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>
-// Defines the INotificationService type.
-// </summary>
-// --------------------------------------------------------------------------------------------------------------------
-
-namespace HandBrakeWPF.Services.Interfaces
-{
- /// <summary>
- /// The NotificationService interface.
- /// </summary>
- public interface INotificationService
- {
- }
-} \ No newline at end of file
diff --git a/win/CS/HandBrakeWPF/Services/NotificationService.cs b/win/CS/HandBrakeWPF/Services/NotificationService.cs
deleted file mode 100644
index 33870fe14..000000000
--- a/win/CS/HandBrakeWPF/Services/NotificationService.cs
+++ /dev/null
@@ -1,82 +0,0 @@
-// --------------------------------------------------------------------------------------------------------------------
-// <copyright file="NotificationService.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>
-// The Notification Service (Growl Connector)
-// </summary>
-// --------------------------------------------------------------------------------------------------------------------
-
-namespace HandBrakeWPF.Services
-{
- using HandBrake.ApplicationServices.Services.Encode.EventArgs;
- using HandBrake.ApplicationServices.Services.Encode.Interfaces;
-
- using HandBrakeWPF.Services.Interfaces;
-
- using IQueueProcessor = HandBrakeWPF.Services.Queue.Interfaces.IQueueProcessor;
-
- /// <summary>
- /// The Notification Service (Growl Connector)
- /// </summary>
- public class NotificationService : INotificationService
- {
- /// <summary>
- /// The user setting service.
- /// </summary>
- private readonly IUserSettingService userSettingService;
-
- /// <summary>
- /// Initializes a new instance of the <see cref="NotificationService"/> class.
- /// </summary>
- /// <param name="encodeService">
- /// The encode Service.
- /// </param>
- /// <param name="queueProcessor">
- /// The queue Processor.
- /// </param>
- /// <param name="userSettingService">
- /// The user Setting Service.
- /// </param>
- public NotificationService(IEncode encodeService, IQueueProcessor queueProcessor, IUserSettingService userSettingService)
- {
- this.userSettingService = userSettingService;
- // encodeService.EncodeCompleted += this.EncodeServiceEncodeCompleted;
- // queueProcessor.QueueCompleted += this.QueueProcessorQueueCompleted;
- }
-
- /// <summary>
- /// The queue processor_ queue completed.
- /// </summary>
- /// <param name="sender">
- /// The sender.
- /// </param>
- /// <param name="e">
- /// The EventArgs.
- /// </param>
- private void QueueProcessorQueueCompleted(object sender, System.EventArgs e)
- {
- if (userSettingService.GetUserSetting<bool>(UserSettingConstants.GrowlQueue))
- {
- // GrowlCommunicator.Notify("Queue Completed", "Put down that cocktail...\nyour Handbrake queue is done.");
- }
- }
-
- /// <summary>
- /// The encode service_ encode completed.
- /// </summary>
- /// <param name="sender">
- /// The sender.
- /// </param>
- /// <param name="e">
- /// The EncodeCompletedEventArgs.
- /// </param>
- private void EncodeServiceEncodeCompleted(object sender, EncodeCompletedEventArgs e)
- {
- if (userSettingService.GetUserSetting<bool>(UserSettingConstants.GrowlEncode))
- {
- // GrowlCommunicator.Notify("Encode Completed", "Put down that cocktail...\nyour Handbrake encode is done.");
- }
- }
- }
-}
diff --git a/win/CS/HandBrakeWPF/Services/UpdateService.cs b/win/CS/HandBrakeWPF/Services/UpdateService.cs
index d31d3b60f..f49836b6a 100644
--- a/win/CS/HandBrakeWPF/Services/UpdateService.cs
+++ b/win/CS/HandBrakeWPF/Services/UpdateService.cs
@@ -103,7 +103,6 @@ namespace HandBrakeWPF.Services
}
var currentBuild = HandBrakeUtils.Build;
- var skipBuild = this.userSettingService.GetUserSetting<int>(UserSettingConstants.Skipversion);
// Initialize variables
WebRequest request = WebRequest.Create(url);
@@ -118,15 +117,6 @@ namespace HandBrakeWPF.Services
int latest = int.Parse(build);
int current = currentBuild;
- int skip = skipBuild;
-
- // If the user wanted to skip this version, don't report the update
- if (latest == skip)
- {
- var info = new UpdateCheckInformation { NewVersionAvailable = false };
- callback(info);
- return;
- }
var info2 = new UpdateCheckInformation
{
diff --git a/win/CS/HandBrakeWPF/Startup/AppBootstrapper.cs b/win/CS/HandBrakeWPF/Startup/AppBootstrapper.cs
index 53225c235..c2ca7b3ad 100644
--- a/win/CS/HandBrakeWPF/Startup/AppBootstrapper.cs
+++ b/win/CS/HandBrakeWPF/Startup/AppBootstrapper.cs
@@ -60,7 +60,6 @@ namespace HandBrakeWPF.Startup
this.container.Singleton<IUpdateService, UpdateService>();
this.container.Singleton<IScan, LibScan>();
this.container.Singleton<IEncode, LibEncode>();
- this.container.Singleton<INotificationService, NotificationService>();
this.container.Singleton<IPrePostActionService, PrePostActionService>();
this.container.Singleton<IUserSettingService, UserSettingService>();
this.container.Singleton<IPresetService, PresetService>();
diff --git a/win/CS/HandBrakeWPF/UserSettingConstants.cs b/win/CS/HandBrakeWPF/UserSettingConstants.cs
index 9154b678f..f41b0d9e7 100644
--- a/win/CS/HandBrakeWPF/UserSettingConstants.cs
+++ b/win/CS/HandBrakeWPF/UserSettingConstants.cs
@@ -72,11 +72,6 @@ namespace HandBrakeWPF
public const string MinTitleLength = "MinTitleLength";
/// <summary>
- /// Skip Version
- /// </summary>
- public const string Skipversion = "skipversion";
-
- /// <summary>
/// Update Status
/// </summary>
public const string UpdateStatus = "updateStatus";
@@ -92,16 +87,6 @@ namespace HandBrakeWPF
public const string VLCPath = "VLC_Path";
/// <summary>
- /// Growl Encodes
- /// </summary>
- public const string GrowlEncode = "GrowlEncode";
-
- /// <summary>
- /// Growl Queues
- /// </summary>
- public const string GrowlQueue = "GrowlQueue";
-
- /// <summary>
/// The Instance Id
/// </summary>
public const string InstanceId = "InstanceId";
diff --git a/win/CS/HandBrakeWPF/Utilities/HandBrakeApp.cs b/win/CS/HandBrakeWPF/Utilities/HandBrakeApp.cs
index bcdbfb430..5dccba552 100644
--- a/win/CS/HandBrakeWPF/Utilities/HandBrakeApp.cs
+++ b/win/CS/HandBrakeWPF/Utilities/HandBrakeApp.cs
@@ -47,16 +47,14 @@ namespace HandBrakeWPF.Utilities
{
try
{
- Console.WriteLine("Trying to deleting File: {0}", file);
if (File.Exists(file))
{
File.Delete(file);
- Console.WriteLine("File was deleted successfully");
}
}
catch (Exception exc)
{
- Console.WriteLine("Unable to Delete File: {0} {1} {2}", file, Environment.NewLine, exc);
+ throw;
}
}
}
diff --git a/win/CS/HandBrakeWPF/ViewModels/MainViewModel.cs b/win/CS/HandBrakeWPF/ViewModels/MainViewModel.cs
index 919f82389..9e04cf396 100644
--- a/win/CS/HandBrakeWPF/ViewModels/MainViewModel.cs
+++ b/win/CS/HandBrakeWPF/ViewModels/MainViewModel.cs
@@ -228,10 +228,6 @@ namespace HandBrakeWPF.ViewModels
/// <param name="updateService">
/// The update Service.
/// </param>
- /// <param name="notificationService">
- /// The notification Service.
- /// *** Leave in Constructor. ***
- /// </param>
/// <param name="whenDoneService">
/// The when Done Service.
/// *** Leave in Constructor. ***
@@ -264,7 +260,7 @@ namespace HandBrakeWPF.ViewModels
/// The static Preview View Model.
/// </param>
public MainViewModel(IUserSettingService userSettingService, IScan scanService, IEncode encodeService, IPresetService presetService,
- IErrorService errorService, IUpdateService updateService, INotificationService notificationService,
+ IErrorService errorService, IUpdateService updateService,
IPrePostActionService whenDoneService, IWindowManager windowManager, IPictureSettingsViewModel pictureSettingsViewModel, IVideoViewModel videoViewModel,
IFiltersViewModel filtersViewModel, IAudioViewModel audioViewModel, ISubtitlesViewModel subtitlesViewModel,
IAdvancedViewModel advancedViewModel, IChaptersViewModel chaptersViewModel, IStaticPreviewViewModel staticPreviewViewModel)
@@ -273,7 +269,6 @@ namespace HandBrakeWPF.ViewModels
this.encodeService = encodeService;
this.presetService = presetService;
this.errorService = errorService;
- // this.shellViewModel = shellViewModel; IShellViewModel shellViewModel,
this.updateService = updateService;
this.windowManager = windowManager;
this.userSettingService = userSettingService;
diff --git a/win/CS/HandBrakeWPF/ViewModels/OptionsViewModel.cs b/win/CS/HandBrakeWPF/ViewModels/OptionsViewModel.cs
index 331c9bf5c..04c2df797 100644
--- a/win/CS/HandBrakeWPF/ViewModels/OptionsViewModel.cs
+++ b/win/CS/HandBrakeWPF/ViewModels/OptionsViewModel.cs
@@ -114,16 +114,6 @@ namespace HandBrakeWPF.ViewModels
private bool disableLibdvdNav;
/// <summary>
- /// The growl after encode.
- /// </summary>
- private bool growlAfterEncode;
-
- /// <summary>
- /// The growl after queue.
- /// </summary>
- private bool growlAfterQueue;
-
- /// <summary>
/// The log directory.
/// </summary>
private string logDirectory;
@@ -434,40 +424,6 @@ namespace HandBrakeWPF.ViewModels
}
/// <summary>
- /// Gets or sets a value indicating whether GrowlAfterEncode.
- /// </summary>
- public bool GrowlAfterEncode
- {
- get
- {
- return this.growlAfterEncode;
- }
-
- set
- {
- this.growlAfterEncode = value;
- this.NotifyOfPropertyChange("GrowlAfterEncode");
- }
- }
-
- /// <summary>
- /// Gets or sets a value indicating whether GrowlAfterQueue.
- /// </summary>
- public bool GrowlAfterQueue
- {
- get
- {
- return this.growlAfterQueue;
- }
-
- set
- {
- this.growlAfterQueue = value;
- this.NotifyOfPropertyChange("GrowlAfterQueue");
- }
- }
-
- /// <summary>
/// Gets or sets a value indicating whether SendFileAfterEncode.
/// </summary>
public bool SendFileAfterEncode
@@ -1349,8 +1305,6 @@ namespace HandBrakeWPF.ViewModels
this.userSettingService.SetUserSetting(UserSettingConstants.WhenCompleteAction, "Do nothing");
}
- this.GrowlAfterEncode = userSettingService.GetUserSetting<bool>(UserSettingConstants.GrowlEncode);
- this.GrowlAfterQueue = userSettingService.GetUserSetting<bool>(UserSettingConstants.GrowlQueue);
this.SendFileAfterEncode = this.userSettingService.GetUserSetting<bool>(UserSettingConstants.SendFile);
this.SendFileTo = Path.GetFileNameWithoutExtension(this.userSettingService.GetUserSetting<string>(UserSettingConstants.SendFileTo)) ?? string.Empty;
this.SendFileToPath = this.userSettingService.GetUserSetting<string>(UserSettingConstants.SendFileTo) ?? string.Empty;
@@ -1478,8 +1432,6 @@ namespace HandBrakeWPF.ViewModels
this.userSettingService.SetUserSetting(UserSettingConstants.UpdateStatus, this.CheckForUpdates);
this.userSettingService.SetUserSetting(UserSettingConstants.DaysBetweenUpdateCheck, this.CheckForUpdatesFrequency);
this.userSettingService.SetUserSetting(UserSettingConstants.WhenCompleteAction, this.WhenDone);
- this.userSettingService.SetUserSetting(UserSettingConstants.GrowlQueue, this.GrowlAfterQueue);
- this.userSettingService.SetUserSetting(UserSettingConstants.GrowlEncode, this.GrowlAfterEncode);
this.userSettingService.SetUserSetting(UserSettingConstants.SendFileTo, this.SendFileToPath);
this.userSettingService.SetUserSetting(UserSettingConstants.SendFile, this.SendFileAfterEncode);
this.userSettingService.SetUserSetting(UserSettingConstants.SendFileToArgs, this.Arguments);
diff --git a/win/CS/HandBrakeWPF/Views/OptionsView.xaml b/win/CS/HandBrakeWPF/Views/OptionsView.xaml
index 956c3d602..d8c6ee802 100644
--- a/win/CS/HandBrakeWPF/Views/OptionsView.xaml
+++ b/win/CS/HandBrakeWPF/Views/OptionsView.xaml
@@ -109,11 +109,6 @@
<CheckBox Content="{x:Static Properties:ResourcesUI.Options_ResetDoNothing}" VerticalAlignment="Center" IsChecked="{Binding ResetWhenDoneAction}" />
</StackPanel>
- <StackPanel Orientation="Horizontal" Margin="0,5,0,0" Visibility="Collapsed">
- <CheckBox Content="Growl after Queue Completes" IsChecked="{Binding GrowlAfterEncode}" Margin="0,0,5,0"/>
- <CheckBox Content="Growl after Encode Completes" IsChecked="{Binding GrowlAfterQueue}" />
- </StackPanel>
-
<StackPanel Orientation="Horizontal" Margin="0,5,0,0">
<CheckBox Content="{x:Static Properties:ResourcesUI.Options_SendFileTo}" VerticalAlignment="Center" IsChecked="{Binding SendFileAfterEncode}" />
<TextBlock Margin="5,0,5,5" VerticalAlignment="Center" Text="{Binding SendFileTo}" />