From eaa813d1305e2f3648a02bdbd6dc9ebca1ff668f Mon Sep 17 00:00:00 2001 From: Tom Schuster Date: Fri, 5 Dec 2014 11:07:15 -0800 Subject: [PATCH] Bug 1103181 - Remove quote() from about:addons/config on android/metro. r=rnewman --- browser/metro/base/content/pages/config.js | 4 ++-- mobile/android/chrome/content/aboutAddons.js | 2 +- mobile/android/chrome/content/config.js | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/browser/metro/base/content/pages/config.js b/browser/metro/base/content/pages/config.js index 0240da7d690..66b232583db 100644 --- a/browser/metro/base/content/pages/config.js +++ b/browser/metro/base/content/pages/config.js @@ -86,7 +86,7 @@ var NewPrefDialog = { } // If item already in list, it's being changed, else added - let item = document.querySelector(".pref-item[name=" + aPrefName.quote() + "]"); + let item = document.querySelector(".pref-item[name=\"" + CSS.escape(aPrefName) + "\"]"); if (item) { this._positiveButton.textContent = gStringBundle.GetStringFromName("newPref.changeButton"); } else { @@ -463,7 +463,7 @@ var AboutConfig = { } // If pref not already in list, refresh display as it's being added - let item = document.querySelector(".pref-item[name=" + pref.name.quote() + "]"); + let item = document.querySelector(".pref-item[name=\"" + CSS.escape(pref.name) + "\"]"); if (!item) { document.location.reload(); return; diff --git a/mobile/android/chrome/content/aboutAddons.js b/mobile/android/chrome/content/aboutAddons.js index c8407595c41..0a02bc0d59f 100644 --- a/mobile/android/chrome/content/aboutAddons.js +++ b/mobile/android/chrome/content/aboutAddons.js @@ -238,7 +238,7 @@ var Addons = { _getElementForAddon: function(aKey) { let list = document.getElementById("addons-list"); - let element = list.querySelector("div[addonID=" + aKey.quote() + "]"); + let element = list.querySelector("div[addonID=\"" + CSS.escape(aKey) + "\"]"); return element; }, diff --git a/mobile/android/chrome/content/config.js b/mobile/android/chrome/content/config.js index c2318f45a6e..337af78ccba 100644 --- a/mobile/android/chrome/content/config.js +++ b/mobile/android/chrome/content/config.js @@ -87,7 +87,7 @@ var NewPrefDialog = { } // If item already in list, it's being changed, else added - let item = document.querySelector(".pref-item[name=" + aPrefName.quote() + "]"); + let item = document.querySelector(".pref-item[name=\"" + CSS.escape(aPrefName) + "\"]"); if (item) { this._positiveButton.textContent = gStringBundle.GetStringFromName("newPref.changeButton"); } else { @@ -472,7 +472,7 @@ var AboutConfig = { } // If pref not already in list, refresh display as it's being added - let item = document.querySelector(".pref-item[name=" + pref.name.quote() + "]"); + let item = document.querySelector(".pref-item[name=\"" + CSS.escape(pref.name) + "\"]"); if (!item) { document.location.reload(); return;