From 3969f3129f3830cdcd2a478e9d57f203e451f5b9 Mon Sep 17 00:00:00 2001 From: alschmiedt Date: Tue, 22 Sep 2020 16:35:22 -0700 Subject: [PATCH] Fix bug in trashcan (#4306) --- core/trashcan.js | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/core/trashcan.js b/core/trashcan.js index 0d5cc03ea..b6a05d5e8 100644 --- a/core/trashcan.js +++ b/core/trashcan.js @@ -311,8 +311,6 @@ Blockly.Trashcan.prototype.createDom = function() { this.svgLid_.setAttributeNS(Blockly.utils.dom.XLINK_NS, 'xlink:href', this.workspace_.options.pathToMedia + Blockly.SPRITE.url); - Blockly.bindEventWithChecks_( - this.svgGroup_, 'mousedown', this, this.blockMouseDownWhenFull_); Blockly.bindEventWithChecks_(this.svgGroup_, 'mouseup', this, this.click); // bindEventWithChecks_ quashes events too aggressively. See: // https://groups.google.com/forum/#!topic/blockly/QF4yB9Wx00s @@ -566,18 +564,6 @@ Blockly.Trashcan.prototype.fireUiEvent_ = function(trashcanOpen) { Blockly.Events.fire(uiEvent); }; -/** - * Prevents a workspace scroll and click event if the trashcan has blocks. - * @param {!Event} e A mouse down event. - * @private - */ -Blockly.Trashcan.prototype.blockMouseDownWhenFull_ = function(e) { - if (this.hasContents_()) { - e.stopPropagation(); // Don't start a workspace scroll. - } -}; - - /** * Indicate that the trashcan can be clicked (by opening it) if it has blocks. * @private