diff --git a/Application/FileConverter/Application.xaml.cs b/Application/FileConverter/Application.xaml.cs index 4d8caf5..5ec9d2b 100644 --- a/Application/FileConverter/Application.xaml.cs +++ b/Application/FileConverter/Application.xaml.cs @@ -177,8 +177,12 @@ namespace FileConverter private void Initialize() { - Diagnostics.Debug.Log("File Converter v" + ApplicationVersion.ToString()); - +#if BUILD32 + Diagnostics.Debug.Log("File Converter v" + ApplicationVersion.ToString() + " (32 bits)"); +#else + Diagnostics.Debug.Log("File Converter v" + ApplicationVersion.ToString() + " (64 bits)"); +#endif + // Retrieve arguments. Debug.Log("Retrieve arguments..."); string[] args = Environment.GetCommandLineArgs(); diff --git a/Application/FileConverter/Upgrade/Helpers.cs b/Application/FileConverter/Upgrade/Helpers.cs index 0ad3cc2..dfcb2b4 100644 --- a/Application/FileConverter/Upgrade/Helpers.cs +++ b/Application/FileConverter/Upgrade/Helpers.cs @@ -25,7 +25,12 @@ namespace FileConverter.Upgrade public static async Task GetLatestVersionDescriptionAsync(OnUpgradeOperationCompletedEventHandler onGetCompleteDelegate = null) { +#if BUILD32 + Uri uri = new Uri(Helpers.BaseURI + "version (x86).xml"); +#else Uri uri = new Uri(Helpers.BaseURI + "version.xml"); +#endif + Stream stream = await Helpers.webClient.OpenReadTaskAsync(uri); UpgradeVersionDescription upgradeVersionDescription = null; @@ -64,7 +69,7 @@ namespace FileConverter.Upgrade { if (upgradeVersionDescription == null) { - throw new ArgumentNullException("upgradeVersionDescription"); + throw new ArgumentNullException(nameof(upgradeVersionDescription)); } Uri uri = new Uri(Helpers.BaseURI + "CHANGELOG.md"); diff --git a/Application/FileConverter/Upgrade/UpgradeVersionDescription.cs b/Application/FileConverter/Upgrade/UpgradeVersionDescription.cs index b141dec..081d403 100644 --- a/Application/FileConverter/Upgrade/UpgradeVersionDescription.cs +++ b/Application/FileConverter/Upgrade/UpgradeVersionDescription.cs @@ -20,34 +20,14 @@ namespace FileConverter get; set; } - - [XmlIgnore] + + [XmlElement("URL")] public string InstallerURL - { - get - { -#if BUILD32 - return this.InstallerX86URL; -#else - return this.InstallerX64URL; -#endif - } - } - - [XmlElement("URL")] - public string InstallerX64URL { get; set; } - - [XmlElement("URLx86")] - public string InstallerX86URL - { - get; - set; - } - + [XmlIgnore] public string ChangeLog { diff --git a/version (x86).xml b/version (x86).xml new file mode 100644 index 0000000..afab095 --- /dev/null +++ b/version (x86).xml @@ -0,0 +1,4 @@ + + + http://github.com/Tichau/FileConverter/releases/download/v1.0/FileConverter-1.0-x86-setup.msi + \ No newline at end of file