diff --git a/core/block_dragger.js b/core/block_dragger.js index 9a6c46573..fa9bbcafd 100644 --- a/core/block_dragger.js +++ b/core/block_dragger.js @@ -152,6 +152,13 @@ Blockly.BlockDragger.prototype.startBlockDrag = function(currentDragDeltaXY, hea Blockly.Events.setGroup(true); } + // Mutators don't have the same type of z-ordering as the normal workspace during a drag. + // They have to rely on the order of the blocks in the svg. For performance reasons that + // usually happens at the end of a drag, but do it at the beginning for mutators. + if (this.workspace_.isMutator) { + this.draggingBlock_.bringToFront(); + } + this.workspace_.setResizesEnabled(false); Blockly.BlockAnimations.disconnectUiStop();