Bug 1557871 Fix badged-button leftovers r=dao

In bug 1519577, the badged-button class for toolbarbuttons was replaced
with a "badged" attribute but a few old uses of the class were overlooked.
This patch fixes them.

Differential Revision: https://phabricator.services.mozilla.com/D34438

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Andrew Swan 2019-06-11 14:36:18 +00:00
Родитель eb4d923ebd
Коммит 293531d7dd
3 изменённых файлов: 6 добавлений и 6 удалений

Просмотреть файл

@ -1141,7 +1141,7 @@ BrowserPageActions.addSearchEngine = {
}
for (let engine of this.engines) {
let button = document.createXULElement("toolbarbutton");
button.classList.add("subviewbutton", "subviewbutton-iconic", "badged-button");
button.classList.add("subviewbutton", "subviewbutton-iconic");
button.setAttribute("label", engine.title);
button.setAttribute("image", engine.icon);
button.setAttribute("uri", engine.uri);

Просмотреть файл

@ -601,8 +601,8 @@ class SearchOneOffs {
// Make the top-level menu button.
let button = document.createXULElement("toolbarbutton");
list.appendChild(button);
button.classList.add("addengine-menu-button", "addengine-item",
"badged-button");
button.classList.add("addengine-menu-button", "addengine-item");
button.setAttribute("badged", "true");
button.setAttribute("type", "menu");
button.setAttribute("label",
this.bundle.GetStringFromName("cmd_addFoundEngineMenu"));
@ -648,7 +648,7 @@ class SearchOneOffs {
let button = document.createXULElement(eltType);
button.classList.add("addengine-item");
if (!tooManyEngines) {
button.classList.add("badged-button");
button.setAttribute("badged", "true");
}
button.id = this.telemetryOrigin + "-add-engine-" +
this._fixUpEngineNameForID(engine.title);

Просмотреть файл

@ -456,8 +456,8 @@ var PageActions = {
* URLs, like { 16: url16, 32: url32 }. The best size for the user's
* screen will be used.
* @param isBadged (bool, optional)
* If true, the toolbarbutton for this action will get the
* "badged-button" class.
* If true, the toolbarbutton for this action will get a
* "badged" attribute.
* @param onBeforePlacedInWindow (function, optional)
* Called before the action is placed in the window:
* onBeforePlacedInWindow(window)