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

Unified Diff: third_party/WebKit/Source/devtools/front_end/audits/AuditsPanel.js

Issue 2174863003: DevTools: traverse widget hierarchy to reveal views. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: lcean Created 4 years, 5 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: third_party/WebKit/Source/devtools/front_end/audits/AuditsPanel.js
diff --git a/third_party/WebKit/Source/devtools/front_end/audits/AuditsPanel.js b/third_party/WebKit/Source/devtools/front_end/audits/AuditsPanel.js
index 1a5060a392934579a18572878412583600167d5d..43a33b9f4ad607e0ce69d443185eebc351b7c46c 100644
--- a/third_party/WebKit/Source/devtools/front_end/audits/AuditsPanel.js
+++ b/third_party/WebKit/Source/devtools/front_end/audits/AuditsPanel.js
@@ -129,9 +129,13 @@ WebInspector.AuditsPanel.prototype = {
*/
showResults: function(categoryResults)
{
- if (!categoryResults._resultView)
- categoryResults._resultView = new WebInspector.AuditResultView(categoryResults);
-
+ if (!categoryResults._resultView) {
+ categoryResults.sort((a, b) => (a.title || "").localeCompare(b.title || ""));
+ var resultView = new WebInspector.View.ExpandableStackContainer();
+ for (var i = 0; i < categoryResults.length; ++i)
+ resultView.appendView(new WebInspector.AuditCategoryResultPane(categoryResults[i]), true);
+ categoryResults._resultView = resultView;
+ }
this.visibleView = categoryResults._resultView;
},

Powered by Google App Engine
This is Rietveld 408576698