diff --git a/core/field_dropdown.js b/core/field_dropdown.js index 059070171..ceddf39a9 100644 --- a/core/field_dropdown.js +++ b/core/field_dropdown.js @@ -437,7 +437,10 @@ Blockly.FieldDropdown.prototype.render_ = function() { // Update arrow's colour. this.arrow_.style.fill = this.sourceBlock_.getColour(); } - goog.dom.removeChildren(/** @type {!Element} */ (this.textElement_)); + var child; + while ((child = this.textElement_.firstChild)) { + this.textElement_.removeChild(child); + } goog.dom.removeNode(this.imageElement_); this.imageElement_ = null; diff --git a/core/tooltip.js b/core/tooltip.js index f93f3ae38..cea221c7e 100644 --- a/core/tooltip.js +++ b/core/tooltip.js @@ -133,7 +133,8 @@ Blockly.Tooltip.createDom = function() { return; // Already created. } // Create an HTML container for popup overlays (e.g. editor widgets). - Blockly.Tooltip.DIV = goog.dom.createDom('div', 'blocklyTooltipDiv'); + Blockly.Tooltip.DIV = document.createElement('div'); + Blockly.Tooltip.DIV.className = 'blocklyTooltipDiv'; document.body.appendChild(Blockly.Tooltip.DIV); }; @@ -287,7 +288,7 @@ Blockly.Tooltip.show_ = function() { return; } // Erase all existing text. - goog.dom.removeChildren(/** @type {!Element} */ (Blockly.Tooltip.DIV)); + Blockly.Tooltip.DIV.innerHTML = ''; // Get the new text. var tip = Blockly.Tooltip.element_.tooltip; while (typeof tip == 'function') { diff --git a/core/widgetdiv.js b/core/widgetdiv.js index 61215b852..82de6a02b 100644 --- a/core/widgetdiv.js +++ b/core/widgetdiv.js @@ -33,7 +33,6 @@ goog.provide('Blockly.WidgetDiv'); goog.require('Blockly.Css'); -goog.require('goog.dom'); goog.require('goog.style'); @@ -65,7 +64,8 @@ Blockly.WidgetDiv.createDom = function() { return; // Already created. } // Create an HTML container for popup overlays (e.g. editor widgets). - Blockly.WidgetDiv.DIV = goog.dom.createDom('div', 'blocklyWidgetDiv'); + Blockly.WidgetDiv.DIV = document.createElement('div'); + Blockly.WidgetDiv.DIV.className = 'blocklyWidgetDiv'; document.body.appendChild(Blockly.WidgetDiv.DIV); }; @@ -99,7 +99,7 @@ Blockly.WidgetDiv.hide = function() { Blockly.WidgetDiv.DIV.style.top = ''; Blockly.WidgetDiv.dispose_ && Blockly.WidgetDiv.dispose_(); Blockly.WidgetDiv.dispose_ = null; - goog.dom.removeChildren(Blockly.WidgetDiv.DIV); + Blockly.WidgetDiv.DIV.innerHTML = ''; } };