diff options
author | janekptacijarabaci <janekptacijarabaci@seznam.cz> | 2018-06-13 17:31:46 +0200 |
---|---|---|
committer | janekptacijarabaci <janekptacijarabaci@seznam.cz> | 2018-06-13 17:31:46 +0200 |
commit | e08b25667f20c83cd66e7f55dd98f16ae982974b (patch) | |
tree | 7a8d031f121417cb735c5c6e7bb0cec647482d26 | |
parent | 27a19a14646f23194ecfe87530dd8d1d5b25fa57 (diff) | |
download | UXP-e08b25667f20c83cd66e7f55dd98f16ae982974b.tar UXP-e08b25667f20c83cd66e7f55dd98f16ae982974b.tar.gz UXP-e08b25667f20c83cd66e7f55dd98f16ae982974b.tar.lz UXP-e08b25667f20c83cd66e7f55dd98f16ae982974b.tar.xz UXP-e08b25667f20c83cd66e7f55dd98f16ae982974b.zip |
Add architecture detection to "about:" and "about:support"
Issue #492
-rw-r--r-- | toolkit/content/about.js | 7 | ||||
-rw-r--r-- | toolkit/content/aboutSupport.js | 3 | ||||
-rw-r--r-- | toolkit/content/jar.mn | 2 | ||||
-rw-r--r-- | toolkit/locales/en-US/chrome/global/about.dtd | 2 | ||||
-rw-r--r-- | toolkit/modules/Troubleshoot.jsm | 6 | ||||
-rw-r--r-- | toolkit/modules/moz.build | 6 |
6 files changed, 21 insertions, 5 deletions
diff --git a/toolkit/content/about.js b/toolkit/content/about.js index c27916c10..c402ea685 100644 --- a/toolkit/content/about.js +++ b/toolkit/content/about.js @@ -33,7 +33,12 @@ var versionNum = Components.classes["@mozilla.org/xre/app-info;1"] .getService(Components.interfaces.nsIXULAppInfo) .version; var version = document.getElementById("version"); -version.textContent += " " + versionNum; +#ifdef HAVE_64BIT_BUILD +var versionStr = versionNum + " (64-bit)"; +#else +var versionStr = versionNum + " (32-bit)"; +#endif +version.textContent += " " + versionStr; // insert the buildid of the XUL application var BuildIDVal = Components.classes["@mozilla.org/xre/app-info;1"] diff --git a/toolkit/content/aboutSupport.js b/toolkit/content/aboutSupport.js index 7209b7ad0..016549f43 100644 --- a/toolkit/content/aboutSupport.js +++ b/toolkit/content/aboutSupport.js @@ -42,6 +42,9 @@ var snapshotFormatters = { $("os-box").textContent = data.osVersion; $("supportLink").href = data.supportURL; let version = AppConstants.MOZ_APP_VERSION_DISPLAY; + if (data.versionArch) { + version += " (" + data.versionArch + ")"; + } if (data.vendor) version += " (" + data.vendor + ")"; $("version-box").textContent = version; diff --git a/toolkit/content/jar.mn b/toolkit/content/jar.mn index 72a7952c4..a5db7e3a1 100644 --- a/toolkit/content/jar.mn +++ b/toolkit/content/jar.mn @@ -8,7 +8,7 @@ toolkit.jar: content/global/textbox.css content/global/menulist.css content/global/autocomplete.css - content/global/about.js +* content/global/about.js content/global/about.xhtml content/global/aboutAbout.js content/global/aboutAbout.xhtml diff --git a/toolkit/locales/en-US/chrome/global/about.dtd b/toolkit/locales/en-US/chrome/global/about.dtd index 85c1a6d25..5de3837ad 100644 --- a/toolkit/locales/en-US/chrome/global/about.dtd +++ b/toolkit/locales/en-US/chrome/global/about.dtd @@ -1,7 +1,7 @@ <!-- This Source Code Form is subject to the terms of the Mozilla Public - License, v. 2.0. If a copy of the MPL was not distributed with this - file, You can obtain one at http://mozilla.org/MPL/2.0/. --> -<!ENTITY about.version "Version"> +<!ENTITY about.version "Version:"> <!-- LOCALIZATION NOTE (about.credits.beforeLink): note that there is no space between this phrase and the linked about.credits.linkTitle phrase, so if your locale needs a space between words, add it at the end of this entity. --> <!ENTITY about.credits.beforeLink "See a list of "> diff --git a/toolkit/modules/Troubleshoot.jsm b/toolkit/modules/Troubleshoot.jsm index 42f3fb809..daf6d99e6 100644 --- a/toolkit/modules/Troubleshoot.jsm +++ b/toolkit/modules/Troubleshoot.jsm @@ -188,6 +188,12 @@ var dataProviders = { if (AppConstants.MOZ_UPDATER) data.updateChannel = Cu.import("resource://gre/modules/UpdateUtils.jsm", {}).UpdateUtils.UpdateChannel; +#ifdef HAVE_64BIT_BUILD + data.versionArch = "64-bit"; +#else + data.versionArch = "32-bit"; +#endif + try { data.vendor = Services.prefs.getCharPref("app.support.vendor"); } diff --git a/toolkit/modules/moz.build b/toolkit/modules/moz.build index 60f3cc3da..e288d11c8 100644 --- a/toolkit/modules/moz.build +++ b/toolkit/modules/moz.build @@ -94,7 +94,6 @@ EXTRA_JS_MODULES += [ 'Sqlite.jsm', 'Task.jsm', 'Timer.jsm', - 'Troubleshoot.jsm', 'UpdateUtils.jsm', 'WebChannel.jsm', 'WindowDraggingUtils.jsm', @@ -103,7 +102,10 @@ EXTRA_JS_MODULES += [ EXTRA_JS_MODULES.third_party.jsesc += ['third_party/jsesc/jsesc.js'] EXTRA_JS_MODULES.sessionstore += ['sessionstore/Utils.jsm'] -EXTRA_PP_JS_MODULES += ['NewTabUtils.jsm'] +EXTRA_PP_JS_MODULES += [ + 'NewTabUtils.jsm', + 'Troubleshoot.jsm', +] if not CONFIG['MOZ_WEBEXTENSIONS']: EXTRA_PP_JS_MODULES += ['UpdateChannel.jsm'] |