Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1286)

Unified Diff: Source/devtools/front_end/sources/AdvancedSearchView.js

Issue 805853002: DevTools: Make labeled checkbox a web component (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/devtools/front_end/sources/AdvancedSearchView.js
diff --git a/Source/devtools/front_end/sources/AdvancedSearchView.js b/Source/devtools/front_end/sources/AdvancedSearchView.js
index b215078125fd4dd5e58dd697be205e54c5f6e544..60fd3ddf30756e8084c82a37e6c85ff5fe08e7cf 100644
--- a/Source/devtools/front_end/sources/AdvancedSearchView.js
+++ b/Source/devtools/front_end/sources/AdvancedSearchView.js
@@ -28,19 +28,17 @@ WebInspector.AdvancedSearchView = function()
this._search.setAttribute("results", "0");
this._search.setAttribute("size", 30);
- this._ignoreCaseLabel = this._searchPanelElement.createChild("label");
+ this._ignoreCaseLabel = createCheckboxLabel(WebInspector.UIString("Ignore case"));
this._ignoreCaseLabel.classList.add("search-config-label");
- this._ignoreCaseCheckbox = this._ignoreCaseLabel.createChild("input");
- this._ignoreCaseCheckbox.setAttribute("type", "checkbox");
+ this._searchPanelElement.appendChild(this._ignoreCaseLabel);
+ this._ignoreCaseCheckbox = this._ignoreCaseLabel.checkboxElement;
this._ignoreCaseCheckbox.classList.add("search-config-checkbox");
- this._ignoreCaseLabel.createTextChild(WebInspector.UIString("Ignore case"));
- this._regexLabel = this._searchPanelElement.createChild("label");
+ this._regexLabel = createCheckboxLabel(WebInspector.UIString("Regular expression"));
this._regexLabel.classList.add("search-config-label");
- this._regexCheckbox = this._regexLabel.createChild("input");
- this._regexCheckbox.setAttribute("type", "checkbox");
+ this._searchPanelElement.appendChild(this._regexLabel);
+ this._regexCheckbox = this._regexLabel.checkboxElement;
this._regexCheckbox.classList.add("search-config-checkbox");
- this._regexLabel.createTextChild(WebInspector.UIString("Regular expression"));
this._searchStatusBarElement = this.contentElement.createChild("div", "search-status-bar-summary");
this._searchMessageElement = this._searchStatusBarElement.createChild("div", "search-message");
« no previous file with comments | « Source/devtools/front_end/settings/SettingsScreen.js ('k') | Source/devtools/front_end/sources/BreakpointsSidebarPane.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698