Bug 1382570 - Ignore non-left clicks on the bookmark icon. r=Gijs
MozReview-Commit-ID: KrFYUijzawU
--- a/browser/base/content/browser-places.js
+++ b/browser/base/content/browser-places.js
@@ -1936,18 +1936,18 @@ var BookmarkingUI = {
if (widget.overflowed) {
// Close the overflow panel because the Edit Bookmark panel will appear.
widget.node.removeAttribute("closemenu");
}
this.onStarCommand(aEvent);
},
onStarCommand(aEvent) {
- // Ignore clicks on the star if we are updating its state.
- if (!this._pendingUpdate) {
+ // Ignore non-left clicks on the star, or if we are updating its state.
+ if (!this._pendingUpdate && aEvent.button == 0) {
let isBookmarked = this._itemGuids.size > 0;
// Disable the old animation in photon
if (!isBookmarked && !AppConstants.MOZ_PHOTON_THEME)
this._showBookmarkedNotification();
// Set up variables for new animation in Photon
if (!isBookmarked && AppConstants.MOZ_PHOTON_ANIMATIONS) {
BrowserUtils.setToolbarButtonHeightProperty(this.star);
this.star.setAttribute("animate", "true");