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

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

Issue 2255983002: DevTools: refactor and fix bugs for DOMBreakpointsSidebarPane (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address CL feedback Created 4 years, 3 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 364 matching lines...) Expand 10 before | Expand all | Expand 10 after
375 375
376 var treeOutline = WebInspector.ElementsTreeOutline.forDOMModel(domModel) ; 376 var treeOutline = WebInspector.ElementsTreeOutline.forDOMModel(domModel) ;
377 treeOutline.rootDOMNode = inspectedRootDocument; 377 treeOutline.rootDOMNode = inspectedRootDocument;
378 378
379 if (!inspectedRootDocument) { 379 if (!inspectedRootDocument) {
380 if (this.isShowing()) 380 if (this.isShowing())
381 domModel.requestDocument(); 381 domModel.requestDocument();
382 return; 382 return;
383 } 383 }
384 384
385 WebInspector.domBreakpointsSidebarPane.restoreBreakpoints(domModel);
386
387 /** 385 /**
388 * @this {WebInspector.ElementsPanel} 386 * @this {WebInspector.ElementsPanel}
389 * @param {?WebInspector.DOMNode} candidateFocusNode 387 * @param {?WebInspector.DOMNode} candidateFocusNode
390 */ 388 */
391 function selectNode(candidateFocusNode) 389 function selectNode(candidateFocusNode)
392 { 390 {
393 if (!candidateFocusNode) 391 if (!candidateFocusNode)
394 candidateFocusNode = inspectedRootDocument.body || inspectedRoot Document.documentElement; 392 candidateFocusNode = inspectedRootDocument.body || inspectedRoot Document.documentElement;
395 393
396 if (!candidateFocusNode) 394 if (!candidateFocusNode)
(...skipping 718 matching lines...) Expand 10 before | Expand all | Expand 10 after
1115 /** 1113 /**
1116 * @override 1114 * @override
1117 * @param {!WebInspector.DOMNode} node 1115 * @param {!WebInspector.DOMNode} node
1118 * @return {?{title: string, color: string}} 1116 * @return {?{title: string, color: string}}
1119 */ 1117 */
1120 decorate: function(node) 1118 decorate: function(node)
1121 { 1119 {
1122 return { color: "orange", title: WebInspector.UIString("Element state: % s", ":" + WebInspector.CSSModel.fromNode(node).pseudoState(node).join(", :")) }; 1120 return { color: "orange", title: WebInspector.UIString("Element state: % s", ":" + WebInspector.CSSModel.fromNode(node).pseudoState(node).join(", :")) };
1123 } 1121 }
1124 } 1122 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698