From 4edcf5839b21d022a379d773c517ab114636b80b Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Sat, 1 Apr 2017 11:24:01 -0400 Subject: [PATCH] Don't show context menu on right-click on tag selector background --- .../content/zotero/bindings/tagselector.xml | 50 ++++++++++++------- 1 file changed, 31 insertions(+), 19 deletions(-) diff --git a/chrome/content/zotero/bindings/tagselector.xml b/chrome/content/zotero/bindings/tagselector.xml index ac56abf760..37ddbe2f89 100644 --- a/chrome/content/zotero/bindings/tagselector.xml +++ b/chrome/content/zotero/bindings/tagselector.xml @@ -176,25 +176,7 @@ }.bind(this)); tagsBox.addEventListener('mousedown', function (event) { - if (!this.editable) return; - - if (event.button == 2) { - // Without the setTimeout, the popup gets immediately hidden - // for some reason - setTimeout(function () { - _popupNode = event.originalTarget; - this.id('tag-menu').openPopup( - null, - 'after_pointer', - event.clientX + 2, - event.clientY + 2, - true, - event - ); - event.stopPropagation(); - event.preventDefault(); - }.bind(this)); - } + this.handleTagMouseDown(event); }.bind(this)); tagsBox.addEventListener('dragover', this.dragObserver.onDragOver); @@ -739,6 +721,36 @@ + + + +