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 /toolkit | |
parent | 27a19a14646f23194ecfe87530dd8d1d5b25fa57 (diff) | |
download | uxp-e08b25667f20c83cd66e7f55dd98f16ae982974b.tar.gz |
Add architecture detection to "about:" and "about:support"
Issue #492
Diffstat (limited to 'toolkit')
-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 c27916c106..c402ea685c 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 7209b7ad04..016549f436 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 72a7952c4f..a5db7e3a11 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 85c1a6d252..5de3837ad1 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 42f3fb8094..daf6d99e68 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 60f3cc3da4..e288d11c86 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'] |