Bug 1938075 - Remove inline event handler from buildOtherBookmarksFolder. r=places-reviewers,mak
Differential Revision: https://phabricator.services.mozilla.com/D232492
This commit is contained in:
@@ -2237,13 +2237,14 @@ var BookmarkingUI = {
|
||||
let otherBookmarksButton = document.createXULElement("toolbarbutton");
|
||||
otherBookmarksButton.setAttribute("type", "menu");
|
||||
otherBookmarksButton.setAttribute("container", "true");
|
||||
otherBookmarksButton.setAttribute(
|
||||
"onpopupshowing",
|
||||
"document.getElementById('PlacesToolbar')._placesView._onOtherBookmarksPopupShowing(event);"
|
||||
);
|
||||
otherBookmarksButton.id = "OtherBookmarks";
|
||||
otherBookmarksButton.className = "bookmark-item";
|
||||
otherBookmarksButton.hidden = "true";
|
||||
otherBookmarksButton.addEventListener("popupshowing", event =>
|
||||
document
|
||||
.getElementById("PlacesToolbar")
|
||||
._placesView._onOtherBookmarksPopupShowing(event)
|
||||
);
|
||||
|
||||
MozXULElement.insertFTLIfNeeded("browser/places.ftl");
|
||||
document.l10n.setAttributes(otherBookmarksButton, "other-bookmarks-folder");
|
||||
|
||||
Reference in New Issue
Block a user