mirror of
https://github.com/google/blockly.git
synced 2026-01-10 18:37:09 +01:00
Block browser context menu in the toolbox and flyout
This commit is contained in:
@@ -280,7 +280,7 @@ Blockly.init_ = function(mainWorkspace) {
|
||||
var svg = mainWorkspace.getParentSvg();
|
||||
|
||||
// Suppress the browser's context menu.
|
||||
Blockly.bindEventWithChecks_(svg, 'contextmenu', null,
|
||||
Blockly.bindEventWithChecks_(svg.parentNode, 'contextmenu', null,
|
||||
function(e) {
|
||||
if (!Blockly.utils.isTargetInput(e)) {
|
||||
e.preventDefault();
|
||||
|
||||
Reference in New Issue
Block a user