Upstream version 9.38.198.0
[platform/framework/web/crosswalk.git] / src / third_party / WebKit / Source / devtools / front_end / ui / Checkbox.js
index 7802c09..07a9fd7 100644 (file)
  */
 WebInspector.Checkbox = function(label, className, tooltip)
 {
-    this.element = document.createElement('label');
-    this._inputElement = document.createElement('input');
+    this.element = document.createElementWithClass("label", className);
+    this._inputElement = this.element.createChild("input");
     this._inputElement.type = "checkbox";
-
-    this.element.className = className;
-    this.element.appendChild(this._inputElement);
-    this.element.appendChild(document.createTextNode(label));
+    this.element.createTextChild(label);
     if (tooltip)
         this.element.title = tooltip;
 }