summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsr55 <[email protected]>2009-05-13 20:16:32 +0000
committersr55 <[email protected]>2009-05-13 20:16:32 +0000
commitabee110b5dfb185bbaa2accec47235141f33a286 (patch)
tree8363e01fb4e51616cfee7e7252fa2df89add5f3f
parent8e57aaf22e7b27ea5c56b1a689a6226b858b8c2a (diff)
WinGui:
- Create a log file directory if one doesn't exist on start-up. - Always create presets.xml if the file doesn't exist. (not only if the HandBrake AppData folder doesn't exist) git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@2418 b64f7644-9d1e-0410-96f1-a4d463321fa5
-rw-r--r--win/C#/Program.cs8
1 files changed, 7 insertions, 1 deletions
diff --git a/win/C#/Program.cs b/win/C#/Program.cs
index ecc9c0281..f2bae9661 100644
--- a/win/C#/Program.cs
+++ b/win/C#/Program.cs
@@ -41,8 +41,14 @@ namespace Handbrake
{
string appDir = Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData) + "\\HandBrake";
if (!Directory.Exists(appDir))
+ Directory.CreateDirectory(appDir);
+
+ string logDir = Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData) + "\\HandBrake\\logs";
+ if (!Directory.Exists(logDir))
+ Directory.CreateDirectory(logDir);
+
+ if (!File.Exists(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData) + "\\HandBrake\\presets.xml"))
{
- Directory.CreateDirectory(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData) + "\\HandBrake");
PresetsHandler x = new PresetsHandler();
x.updateBuiltInPresets();
}