diff --git a/browser/base/content/urlbarBindings.xml b/browser/base/content/urlbarBindings.xml index 37d6f611c8a6..28d988b53fa6 100644 --- a/browser/base/content/urlbarBindings.xml +++ b/browser/base/content/urlbarBindings.xml @@ -3002,7 +3002,7 @@ // otherwise just rely on the panel id for common arrowpanels. let type = this._panel.firstChild.getAttribute("popupid") || this._panel.id; - if (type.startsWith("password-")) + if (type == "password") return "passwords"; if (type == "editBookmarkPanel") return "bookmarks"; diff --git a/browser/components/readinglist/sidebar.js b/browser/components/readinglist/sidebar.js index 02a3e3fb8e01..bc943110a295 100644 --- a/browser/components/readinglist/sidebar.js +++ b/browser/components/readinglist/sidebar.js @@ -54,6 +54,7 @@ let RLSidebar = { addEventListener("unload", () => this.uninit()); this.list = document.getElementById("list"); + this.emptyListInfo = document.getElementById("emptyListInfo"); this.itemTemplate = document.getElementById("item-template"); this.list.addEventListener("click", event => this.onListClick(event)); @@ -91,6 +92,8 @@ let RLSidebar = { this.list.appendChild(itemNode); this.itemNodesById.set(item.id, itemNode); this.itemsById.set(item.id, item); + + this.emptyListInfo.hidden = true; }, /** @@ -106,6 +109,8 @@ let RLSidebar = { this.itemsById.delete(item.id); // TODO: ensureListItems doesn't yet cope with needing to add one item. //this.ensureListItems(); + + this.emptyListInfo.hidden = (this.numItems > 0); }, /** @@ -148,6 +153,7 @@ let RLSidebar = { log.warn("Error adding item", e); } }); + this.emptyListInfo.hidden = (this.numItems > 0); }), /** @@ -350,6 +356,11 @@ let RLSidebar = { if (!itemNode) return; + if (event.target.classList.contains("remove-button")) { + ReadingList.deleteItem(this.getItemFromNode(itemNode)); + return; + } + this.activeItem = itemNode; this.openActiveItem(event); }, diff --git a/browser/components/readinglist/sidebar.xhtml b/browser/components/readinglist/sidebar.xhtml index 12f0342eaff7..7aaacb4f3fea 100644 --- a/browser/components/readinglist/sidebar.xhtml +++ b/browser/components/readinglist/sidebar.xhtml @@ -11,7 +11,7 @@
- +