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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/elements/ElementsPanel.js

Issue 2902273002: DevTools: convert linkifyURL params into options object (Closed)
Patch Set: rebase and ac Created 3 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.
3 * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com> 3 * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com>
4 * Copyright (C) 2009 Joseph Pecoraro 4 * Copyright (C) 2009 Joseph Pecoraro
5 * 5 *
6 * Redistribution and use in source and binary forms, with or without 6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions 7 * modification, are permitted provided that the following conditions
8 * are met: 8 * are met:
9 * 9 *
10 * 1. Redistributions of source code must retain the above copyright 10 * 1. Redistributions of source code must retain the above copyright
(...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after
254 if (!domModel) 254 if (!domModel)
255 return; 255 return;
256 var treeOutline = Elements.ElementsTreeOutline.forDOMModel(domModel); 256 var treeOutline = Elements.ElementsTreeOutline.forDOMModel(domModel);
257 if (!treeOutline) 257 if (!treeOutline)
258 return; 258 return;
259 var header = this._treeOutlineHeaders.get(treeOutline); 259 var header = this._treeOutlineHeaders.get(treeOutline);
260 if (!header) 260 if (!header)
261 return; 261 return;
262 header.removeChildren(); 262 header.removeChildren();
263 header.createChild('div', 'elements-tree-header-frame').textContent = Common .UIString('Frame'); 263 header.createChild('div', 'elements-tree-header-frame').textContent = Common .UIString('Frame');
264 header.appendChild(Components.Linkifier.linkifyURL(target.inspectedURL(), ta rget.name())); 264 header.appendChild(Components.Linkifier.linkifyURL(target.inspectedURL(), {t ext: target.name()}));
265 } 265 }
266 266
267 _updateTreeOutlineVisibleWidth() { 267 _updateTreeOutlineVisibleWidth() {
268 if (!this._treeOutlines.length) 268 if (!this._treeOutlines.length)
269 return; 269 return;
270 270
271 var width = this._splitWidget.element.offsetWidth; 271 var width = this._splitWidget.element.offsetWidth;
272 if (this._splitWidget.isVertical()) 272 if (this._splitWidget.isVertical())
273 width -= this._splitWidget.sidebarSize(); 273 width -= this._splitWidget.sidebarSize();
274 for (var i = 0; i < this._treeOutlines.length; ++i) 274 for (var i = 0; i < this._treeOutlines.length; ++i)
(...skipping 811 matching lines...) Expand 10 before | Expand all | Expand 10 after
1086 * @param {!SDK.DOMNode} node 1086 * @param {!SDK.DOMNode} node
1087 * @return {?{title: string, color: string}} 1087 * @return {?{title: string, color: string}}
1088 */ 1088 */
1089 decorate(node) { 1089 decorate(node) {
1090 return { 1090 return {
1091 color: 'orange', 1091 color: 'orange',
1092 title: Common.UIString('Element state: %s', ':' + node.domModel().cssModel ().pseudoState(node).join(', :')) 1092 title: Common.UIString('Element state: %s', ':' + node.domModel().cssModel ().pseudoState(node).join(', :'))
1093 }; 1093 };
1094 } 1094 }
1095 }; 1095 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698