Move createDom call into the constructor of block drag surface. (#790)

This commit is contained in:
picklesrus
2017-01-04 17:02:06 -08:00
committed by GitHub
parent 791af631e8
commit 9f3e15cd82
2 changed files with 1 additions and 1 deletions

View File

@@ -47,6 +47,7 @@ Blockly.BlockDragSurfaceSvg = function(container) {
* @private
*/
this.container_ = container;
this.createDom();
};
/**

View File

@@ -60,7 +60,6 @@ Blockly.inject = function(container, opt_options) {
// Create surfaces for dragging things. These are optimizations
// so that the broowser does not repaint during the drag.
var blockDragSurface = new Blockly.BlockDragSurfaceSvg(subContainer);
blockDragSurface.createDom();
var workspaceDragSurface = new Blockly.workspaceDragSurfaceSvg(subContainer);
var workspace = Blockly.createMainWorkspace_(svg, options, blockDragSurface,