From bbd57a9a16e316a91e09b86d107f64da13deea80 Mon Sep 17 00:00:00 2001 From: Katelyn Mann Date: Thu, 11 Aug 2016 11:00:02 -0700 Subject: [PATCH] Fix #536 by changing workspace's dispose method to remove the injectDiv wrapper of the svg. The wrapper div was introduced in #512. --- core/workspace_svg.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/core/workspace_svg.js b/core/workspace_svg.js index 8e06fb415..bddde64f1 100644 --- a/core/workspace_svg.js +++ b/core/workspace_svg.js @@ -275,8 +275,9 @@ Blockly.WorkspaceSvg.prototype.dispose = function() { this.zoomControls_ = null; } if (!this.options.parentWorkspace) { - // Top-most workspace. Dispose of the SVG too. - goog.dom.removeNode(this.getParentSvg()); + // Top-most workspace. Dispose of the div that the + // svg is injected into (i.e. injectionDiv). + goog.dom.removeNode(this.getParentSvg().parentNode); } if (this.resizeHandlerWrapper_) { Blockly.unbindEvent_(this.resizeHandlerWrapper_);