Convert string tag name to goog.dom.TagName ()

in createDom calls only. This improves the type information of the
created objects.
This commit is contained in:
Rodrigo Queiro 2016-08-19 12:55:45 +02:00 committed by Neil Fraser
parent e03b191f73
commit 88eac2480b
4 changed files with 12 additions and 4 deletions

View file

@ -28,6 +28,7 @@ goog.provide('Blockly.Toolbox');
goog.require('Blockly.Flyout');
goog.require('goog.dom');
goog.require('goog.dom.TagName');
goog.require('goog.events');
goog.require('goog.events.BrowserFeature');
goog.require('goog.html.SafeHtml');
@ -147,7 +148,8 @@ Blockly.Toolbox.prototype.init = function() {
var svg = this.workspace_.getParentSvg();
// Create an HTML container for the Toolbox menu.
this.HtmlDiv = goog.dom.createDom('div', 'blocklyToolboxDiv');
this.HtmlDiv =
goog.dom.createDom(goog.dom.TagName.DIV, 'blocklyToolboxDiv');
this.HtmlDiv.setAttribute('dir', workspace.RTL ? 'RTL' : 'LTR');
svg.parentNode.insertBefore(this.HtmlDiv, svg);