summaryrefslogtreecommitdiffstats
path: root/win/C#
diff options
context:
space:
mode:
Diffstat (limited to 'win/C#')
-rw-r--r--win/C#/Functions/Main.cs10
-rw-r--r--win/C#/Properties/Settings.Designer.cs11
-rw-r--r--win/C#/Properties/Settings.settings3
-rw-r--r--win/C#/app.config3
4 files changed, 27 insertions, 0 deletions
diff --git a/win/C#/Functions/Main.cs b/win/C#/Functions/Main.cs
index 022a025ba..dd618cb52 100644
--- a/win/C#/Functions/Main.cs
+++ b/win/C#/Functions/Main.cs
@@ -197,6 +197,15 @@ namespace Handbrake.Functions
// 0 = SVN Build / Version
// 1 = Build Date
+
+ DateTime lastModified = File.GetLastWriteTime("HandBrakeCLI.exe");
+
+
+ if (Properties.Settings.Default.cliLastModified == lastModified && Properties.Settings.Default.hb_build != 0)
+ return;
+
+ Properties.Settings.Default.cliLastModified = lastModified;
+
Process cliProcess = new Process();
ProcessStartInfo handBrakeCLI = new ProcessStartInfo("HandBrakeCLI.exe", " -u")
{
@@ -237,6 +246,7 @@ namespace Handbrake.Functions
cli.Kill();
}
}
+ Properties.Settings.Default.Save();
}
catch (Exception e)
{
diff --git a/win/C#/Properties/Settings.Designer.cs b/win/C#/Properties/Settings.Designer.cs
index be86c49b4..e3309843e 100644
--- a/win/C#/Properties/Settings.Designer.cs
+++ b/win/C#/Properties/Settings.Designer.cs
@@ -465,5 +465,16 @@ namespace Handbrake.Properties {
this["growlEncode"] = value;
}
}
+
+ [global::System.Configuration.UserScopedSettingAttribute()]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ public global::System.DateTime cliLastModified {
+ get {
+ return ((global::System.DateTime)(this["cliLastModified"]));
+ }
+ set {
+ this["cliLastModified"] = value;
+ }
+ }
}
}
diff --git a/win/C#/Properties/Settings.settings b/win/C#/Properties/Settings.settings
index b52c8c706..7d6568600 100644
--- a/win/C#/Properties/Settings.settings
+++ b/win/C#/Properties/Settings.settings
@@ -113,5 +113,8 @@
<Setting Name="growlEncode" Type="System.Boolean" Scope="User">
<Value Profile="(Default)">False</Value>
</Setting>
+ <Setting Name="cliLastModified" Type="System.DateTime" Scope="User">
+ <Value Profile="(Default)" />
+ </Setting>
</Settings>
</SettingsFile> \ No newline at end of file
diff --git a/win/C#/app.config b/win/C#/app.config
index d213f5063..bf7dfd93e 100644
--- a/win/C#/app.config
+++ b/win/C#/app.config
@@ -118,6 +118,9 @@
<setting name="growlEncode" serializeAs="String">
<value>False</value>
</setting>
+ <setting name="cliLastModified" serializeAs="String">
+ <value />
+ </setting>
</Handbrake.Properties.Settings>
</userSettings>
<startup><supportedRuntime version="v2.0.50727"/></startup></configuration>