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

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

Issue 362273002: DevTools: Reduce code via using document.createElementWithClass and document.createChild. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 6 months 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/SourcesPanel.js
diff --git a/Source/devtools/front_end/sources/SourcesPanel.js b/Source/devtools/front_end/sources/SourcesPanel.js
index a294bc4e429c83172bd397d53d8cae35711b64d5..bb84e5d192001177a3e25dd6404520848ecdc229 100644
--- a/Source/devtools/front_end/sources/SourcesPanel.js
+++ b/Source/devtools/front_end/sources/SourcesPanel.js
@@ -715,8 +715,7 @@ WebInspector.SourcesPanel.prototype = {
_createDebugToolbar: function()
{
- var debugToolbar = document.createElement("div");
- debugToolbar.className = "scripts-debug-toolbar";
+ var debugToolbar = document.createElementWithClass("div", "scripts-debug-toolbar");
var title, handler;
var platformSpecificModifier = WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta;
@@ -772,8 +771,7 @@ WebInspector.SourcesPanel.prototype = {
_createDebugToolbarDrawer: function()
{
- var debugToolbarDrawer = document.createElement("div");
- debugToolbarDrawer.className = "scripts-debug-toolbar-drawer";
+ var debugToolbarDrawer = document.createElementWithClass("div", "scripts-debug-toolbar-drawer");
var label = WebInspector.UIString("Pause On Caught Exceptions");
var setting = WebInspector.settings.pauseOnCaughtException;
« no previous file with comments | « Source/devtools/front_end/sources/NavigatorView.js ('k') | Source/devtools/front_end/sources/SourcesView.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698