diff --git a/core/workspace_svg.js b/core/workspace_svg.js index 3614e65ed..0194925c9 100644 --- a/core/workspace_svg.js +++ b/core/workspace_svg.js @@ -1105,6 +1105,9 @@ Blockly.WorkspaceSvg.prototype.setScale = function(newScale) { // No toolbox, resize flyout. this.flyout_.reflow(); } + // This event has been handled. Don't start a workspace drag. + e.stopPropagation(); + e.preventDefault(); }; /** diff --git a/core/zoom_controls.js b/core/zoom_controls.js index 31a0b2126..f745c9c21 100644 --- a/core/zoom_controls.js +++ b/core/zoom_controls.js @@ -166,10 +166,12 @@ Blockly.ZoomControls.prototype.createDom = function() { Blockly.bindEvent_(zoominSvg, 'mousedown', null, function(e) { workspace.zoomCenter(1); e.stopPropagation(); // Don't start a workspace scroll. + e.preventDefault(); }); Blockly.bindEvent_(zoomoutSvg, 'mousedown', null, function(e) { workspace.zoomCenter(-1); e.stopPropagation(); // Don't start a workspace scroll. + e.preventDefault(); }); return this.svgGroup_;