Allow contextmenu events to work on the sidebar

(closes #4036)
This commit is contained in:
Bryan Housel
2017-05-12 14:39:41 +01:00
parent 5a6a194ddf
commit ff14dbf944
+5 -2
View File
@@ -164,8 +164,11 @@ export function behaviorSelect(context) {
// Edge and IE really like to show the contextmenu on the
// menubar when user presses a keyboard menu button
// even after we've already preventdefaulted the key event.
d3.event.preventDefault();
d3.event.stopPropagation();
var e = d3.event;
if (+e.clientX === 0 && +e.clientY === 0) {
d3.event.preventDefault();
d3.event.stopPropagation();
}
});
selection