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

Side by Side Diff: Source/WebCore/inspector/front-end/DOMAgent.js

Issue 11366221: Merge 133885 - Web Inspector: Add option to disable rulers (Elements panel) (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1312/
Patch Set: Created 8 years, 1 month 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009, 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2009, 2010 Google Inc. All rights reserved.
3 * Copyright (C) 2009 Joseph Pecoraro 3 * Copyright (C) 2009 Joseph Pecoraro
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are 6 * modification, are permitted provided that the following conditions are
7 * met: 7 * met:
8 * 8 *
9 * * Redistributions of source code must retain the above copyright 9 * * Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 1224 matching lines...) Expand 10 before | Expand all | Expand 10 after
1235 { 1235 {
1236 DOMAgent.setInspectModeEnabled(enabled, this._buildHighlightConfig(), ca llback); 1236 DOMAgent.setInspectModeEnabled(enabled, this._buildHighlightConfig(), ca llback);
1237 }, 1237 },
1238 1238
1239 /** 1239 /**
1240 * @param {string=} mode 1240 * @param {string=} mode
1241 */ 1241 */
1242 _buildHighlightConfig: function(mode) 1242 _buildHighlightConfig: function(mode)
1243 { 1243 {
1244 mode = mode || "all"; 1244 mode = mode || "all";
1245 var highlightConfig = { showInfo: mode === "all" }; 1245 var highlightConfig = { showInfo: mode === "all", showRulers: WebInspect or.settings.showMetricsRulers.get() };
1246 if (mode === "all" || mode === "content") 1246 if (mode === "all" || mode === "content")
1247 highlightConfig.contentColor = WebInspector.Color.PageHighlight.Cont ent.toProtocolRGBA(); 1247 highlightConfig.contentColor = WebInspector.Color.PageHighlight.Cont ent.toProtocolRGBA();
1248 1248
1249 if (mode === "all" || mode === "padding") 1249 if (mode === "all" || mode === "padding")
1250 highlightConfig.paddingColor = WebInspector.Color.PageHighlight.Padd ing.toProtocolRGBA(); 1250 highlightConfig.paddingColor = WebInspector.Color.PageHighlight.Padd ing.toProtocolRGBA();
1251 1251
1252 if (mode === "all" || mode === "border") 1252 if (mode === "all" || mode === "border")
1253 highlightConfig.borderColor = WebInspector.Color.PageHighlight.Borde r.toProtocolRGBA(); 1253 highlightConfig.borderColor = WebInspector.Color.PageHighlight.Borde r.toProtocolRGBA();
1254 1254
1255 if (mode === "all" || mode === "margin") 1255 if (mode === "all" || mode === "margin")
(...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after
1453 shadowRootPopped: function(hostId, rootId) 1453 shadowRootPopped: function(hostId, rootId)
1454 { 1454 {
1455 this._domAgent._childNodeRemoved(hostId, rootId); 1455 this._domAgent._childNodeRemoved(hostId, rootId);
1456 } 1456 }
1457 } 1457 }
1458 1458
1459 /** 1459 /**
1460 * @type {?WebInspector.DOMAgent} 1460 * @type {?WebInspector.DOMAgent}
1461 */ 1461 */
1462 WebInspector.domAgent = null; 1462 WebInspector.domAgent = null;
OLDNEW
« no previous file with comments | « Source/WebCore/inspector/InspectorOverlayPage.html ('k') | Source/WebCore/inspector/front-end/Settings.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698