summaryrefslogtreecommitdiffstats
path: root/win
diff options
context:
space:
mode:
authorScott <[email protected]>2015-08-29 14:51:45 +0100
committerScott <[email protected]>2015-08-29 14:51:45 +0100
commit32f442e8da91b8766333abc9ba6b69946701d8db (patch)
tree74094a9b0c32d30b2e3292c4084e8aae95fff31b /win
parent4fb5fbdced7faceaf4b24bd1b1f08cc127200ed8 (diff)
WinGui: Update the GUI to handle the version information correctly after the git move.
Diffstat (limited to 'win')
-rw-r--r--win/CS/HandBrake.ApplicationServices/Interop/Interfaces/IHandBrakeInstance.cs10
-rw-r--r--win/CS/HandBrake.ApplicationServices/Utilities/VersionHelper.cs8
-rw-r--r--win/CS/HandBrakeWPF/Installer/MakeNightly.nsi2
-rw-r--r--win/CS/HandBrakeWPF/Installer/MakeNightly64.nsi2
4 files changed, 19 insertions, 3 deletions
diff --git a/win/CS/HandBrake.ApplicationServices/Interop/Interfaces/IHandBrakeInstance.cs b/win/CS/HandBrake.ApplicationServices/Interop/Interfaces/IHandBrakeInstance.cs
index 8230e6620..0c231cbac 100644
--- a/win/CS/HandBrake.ApplicationServices/Interop/Interfaces/IHandBrakeInstance.cs
+++ b/win/CS/HandBrake.ApplicationServices/Interop/Interfaces/IHandBrakeInstance.cs
@@ -58,6 +58,16 @@ namespace HandBrake.ApplicationServices.Interop.Interfaces
/// </summary>
JsonScanObject Titles { get; }
+ /// <summary>
+ /// Gets the HandBrake version string.
+ /// </summary>
+ string Version { get; }
+
+ /// <summary>
+ /// Gets the HandBrake build number.
+ /// </summary>
+ int Build { get; }
+
#endregion
#region Public Methods
diff --git a/win/CS/HandBrake.ApplicationServices/Utilities/VersionHelper.cs b/win/CS/HandBrake.ApplicationServices/Utilities/VersionHelper.cs
index b1a90d3e0..47673c112 100644
--- a/win/CS/HandBrake.ApplicationServices/Utilities/VersionHelper.cs
+++ b/win/CS/HandBrake.ApplicationServices/Utilities/VersionHelper.cs
@@ -12,6 +12,9 @@ namespace HandBrake.ApplicationServices.Utilities
using System;
using System.Reflection;
+ using HandBrake.ApplicationServices.Interop;
+ using HandBrake.ApplicationServices.Interop.Interfaces;
+
/// <summary>
/// Version Utility
/// </summary>
@@ -26,7 +29,10 @@ namespace HandBrake.ApplicationServices.Utilities
public static string GetVersion()
{
Version version = Assembly.GetEntryAssembly().GetName().Version;
- return IsNightly() ? string.Format("svn{0} (Nightly Build)", version.Revision) : string.Format("{0}.{1}.{2}.{3}", version.Major, version.Minor, version.Build, version.Revision);
+
+ IHandBrakeInstance instance = HandBrakeInstanceManager.GetScanInstance(1);
+
+ return IsNightly() ? string.Format("Nightly {0} ({1})", instance.Version, instance.Build) : string.Format("{0}.{1}.{2}.{3}", version.Major, version.Minor, version.Build, version.Revision);
}
/// <summary>
diff --git a/win/CS/HandBrakeWPF/Installer/MakeNightly.nsi b/win/CS/HandBrakeWPF/Installer/MakeNightly.nsi
index 4ae8fd1e6..a39055fe3 100644
--- a/win/CS/HandBrakeWPF/Installer/MakeNightly.nsi
+++ b/win/CS/HandBrakeWPF/Installer/MakeNightly.nsi
@@ -9,7 +9,7 @@
; HM NIS Edit Wizard helper defines
!define PRODUCT_NAME "HandBrake"
!define PRODUCT_VERSION "Nightly"
-!define PRODUCT_VERSION_NUMBER "0.10.3.Nightly"
+!define PRODUCT_VERSION_NUMBER "Nightly"
!define PRODUCT_DIR_REGKEY "Software\Microsoft\Windows\CurrentVersion\App Paths\HandBrake.exe"
!define PRODUCT_UNINST_KEY "Software\Microsoft\Windows\CurrentVersion\Uninstall\${PRODUCT_NAME}"
!define PRODUCT_UNINST_ROOT_KEY "HKLM"
diff --git a/win/CS/HandBrakeWPF/Installer/MakeNightly64.nsi b/win/CS/HandBrakeWPF/Installer/MakeNightly64.nsi
index 1459a52cd..76746b032 100644
--- a/win/CS/HandBrakeWPF/Installer/MakeNightly64.nsi
+++ b/win/CS/HandBrakeWPF/Installer/MakeNightly64.nsi
@@ -9,7 +9,7 @@
; HM NIS Edit Wizard helper defines
!define PRODUCT_NAME "HandBrake"
!define PRODUCT_VERSION "Nightly"
-!define PRODUCT_VERSION_NUMBER "0.10.3.Nightly"
+!define PRODUCT_VERSION_NUMBER "Nightly"
!define PRODUCT_DIR_REGKEY "Software\Microsoft\Windows\CurrentVersion\App Paths\HandBrake.exe"
!define PRODUCT_UNINST_KEY "Software\Microsoft\Windows\CurrentVersion\Uninstall\${PRODUCT_NAME}"
!define PRODUCT_UNINST_ROOT_KEY "HKLM"