summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatt A. Tobin <email@mattatobin.com>2020-02-05 13:52:28 -0500
committerwolfbeast <mcwerewolf@wolfbeast.com>2020-04-14 12:37:02 +0200
commit62f39d829dbc630ab287545442ef9a339d2b8fb1 (patch)
treec8b63df6a40e5c3f0442c5f3608ee8c5a8d85e35
parent28971524e4d4832e5c92276cc989535e75f04acc (diff)
downloadUXP-62f39d829dbc630ab287545442ef9a339d2b8fb1.tar
UXP-62f39d829dbc630ab287545442ef9a339d2b8fb1.tar.gz
UXP-62f39d829dbc630ab287545442ef9a339d2b8fb1.tar.lz
UXP-62f39d829dbc630ab287545442ef9a339d2b8fb1.tar.xz
UXP-62f39d829dbc630ab287545442ef9a339d2b8fb1.zip
Issue #65 - Remove AppConstants from toolkit/profile
-rw-r--r--toolkit/profile/content/createProfileWizard.js14
-rw-r--r--toolkit/profile/content/profileSelection.js6
-rw-r--r--toolkit/profile/jar.mn4
3 files changed, 11 insertions, 13 deletions
diff --git a/toolkit/profile/content/createProfileWizard.js b/toolkit/profile/content/createProfileWizard.js
index 14d006b31..f13eb8faa 100644
--- a/toolkit/profile/content/createProfileWizard.js
+++ b/toolkit/profile/content/createProfileWizard.js
@@ -5,8 +5,6 @@
const C = Components.classes;
const I = Components.interfaces;
-Components.utils.import("resource://gre/modules/AppConstants.jsm");
-
const ToolkitProfileService = "@mozilla.org/toolkit/profile-service;1";
var gProfileService;
@@ -118,12 +116,12 @@ function checkCurrentInput(currentInput)
if (!errorMessage) {
finishText.className = "";
- if (AppConstants.platform == "macosx") {
- finishText.firstChild.data = gProfileManagerBundle.getString("profileFinishTextMac");
- }
- else {
- finishText.firstChild.data = gProfileManagerBundle.getString("profileFinishText");
- }
+ finishText.firstChild.data = gProfileManagerBundle
+#ifdef XP_MACOSX
+ .getString("profileFinishTextMac");
+#else
+ .getString("profileFinishText");
+#endif
canAdvance = true;
}
else {
diff --git a/toolkit/profile/content/profileSelection.js b/toolkit/profile/content/profileSelection.js
index 02b9d6873..65a2ba13f 100644
--- a/toolkit/profile/content/profileSelection.js
+++ b/toolkit/profile/content/profileSelection.js
@@ -4,7 +4,6 @@
* 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/. */
-Components.utils.import("resource://gre/modules/AppConstants.jsm");
Components.utils.import("resource://gre/modules/Services.jsm");
const C = Components.classes;
@@ -134,9 +133,10 @@ function onProfilesKey(aEvent)
{
switch ( aEvent.keyCode )
{
+#ifndef XP_MACOSX
case KeyEvent.DOM_VK_BACK_SPACE:
- if (AppConstants.platform != "macosx")
- break;
+ break;
+#endif
case KeyEvent.DOM_VK_DELETE:
ConfirmDelete();
break;
diff --git a/toolkit/profile/jar.mn b/toolkit/profile/jar.mn
index 9b7c22266..1c4afac4c 100644
--- a/toolkit/profile/jar.mn
+++ b/toolkit/profile/jar.mn
@@ -3,7 +3,7 @@
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
toolkit.jar:
- content/mozapps/profile/createProfileWizard.js (content/createProfileWizard.js)
+* content/mozapps/profile/createProfileWizard.js (content/createProfileWizard.js)
* content/mozapps/profile/createProfileWizard.xul (content/createProfileWizard.xul)
- content/mozapps/profile/profileSelection.js (content/profileSelection.js)
+* content/mozapps/profile/profileSelection.js (content/profileSelection.js)
content/mozapps/profile/profileSelection.xul (content/profileSelection.xul)