diff options
Diffstat (limited to 'win/CS')
-rw-r--r-- | win/CS/HandBrake.ApplicationServices/Services/PresetService.cs | 9 | ||||
-rw-r--r-- | win/CS/Program.cs | 6 |
2 files changed, 7 insertions, 8 deletions
diff --git a/win/CS/HandBrake.ApplicationServices/Services/PresetService.cs b/win/CS/HandBrake.ApplicationServices/Services/PresetService.cs index bd125c084..227a6eef6 100644 --- a/win/CS/HandBrake.ApplicationServices/Services/PresetService.cs +++ b/win/CS/HandBrake.ApplicationServices/Services/PresetService.cs @@ -60,7 +60,12 @@ namespace HandBrake.ApplicationServices.Services /// </summary>
public PresetService()
{
- // this.Presets = CollectionViewSource.GetDefaultView(this.presets);
+ // If the preset file doesn't exist. Create it.
+ if (!File.Exists(this.builtInPresetFile))
+ {
+ this.UpdateBuiltInPresets(string.Empty);
+ }
+
this.LoadPresets();
}
@@ -371,7 +376,7 @@ namespace HandBrake.ApplicationServices.Services }
reader.Close();
- }
+ }
}
catch (Exception exc)
{
diff --git a/win/CS/Program.cs b/win/CS/Program.cs index 132624b28..a04c45e12 100644 --- a/win/CS/Program.cs +++ b/win/CS/Program.cs @@ -92,12 +92,6 @@ namespace Handbrake if (!Directory.Exists(logDir))
Directory.CreateDirectory(logDir);
- if (!File.Exists(Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), @"HandBrake\presets.xml")))
- {
- PresetService x = new PresetService();
- x.UpdateBuiltInPresets(string.Empty);
- }
-
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
Application.Run(new frmMain(args));
|