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

Unified Diff: third_party/WebKit/Source/devtools/front_end/ui/ReportView.js

Issue 1960663003: DevTools: introduce the Clear storage pane in the resources panel. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: tests fixed Created 4 years, 7 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/ui/ReportView.js
diff --git a/third_party/WebKit/Source/devtools/front_end/ui/ReportView.js b/third_party/WebKit/Source/devtools/front_end/ui/ReportView.js
index dbb7979f8c7ae26510e33ae5b5dc32535a84cc6b..8195dd5694241e220499363d6ad23eaa631d87af 100644
--- a/third_party/WebKit/Source/devtools/front_end/ui/ReportView.js
+++ b/third_party/WebKit/Source/devtools/front_end/ui/ReportView.js
@@ -21,6 +21,18 @@ WebInspector.ReportView = function(title)
WebInspector.ReportView.prototype = {
/**
+ * @param {string} subtitle
+ */
+ setSubtitle: function(subtitle)
+ {
+ if (this._subtitleElement && this._subtitleElement.textContent === subtitle)
+ return;
+ if (!this._subtitleElement)
+ this._subtitleElement = this._headerElement.createChild("div", "report-subtitle");
+ this._subtitleElement.textContent = subtitle;
+ },
+
+ /**
* @param {?string} url
*/
setURL: function(url)
@@ -48,11 +60,12 @@ WebInspector.ReportView.prototype = {
/**
* @param {string} title
+ * @param {string=} className
* @return {!WebInspector.ReportView.Section}
*/
- appendSection: function(title)
+ appendSection: function(title, className)
{
- var section = new WebInspector.ReportView.Section(title);
+ var section = new WebInspector.ReportView.Section(title, className);
section.show(this._sectionList);
return section;
},
@@ -69,11 +82,14 @@ WebInspector.ReportView.prototype = {
* @constructor
* @extends {WebInspector.VBox}
* @param {string} title
+ * @param {string=} className
*/
-WebInspector.ReportView.Section = function(title)
+WebInspector.ReportView.Section = function(title, className)
{
WebInspector.VBox.call(this);
this.element.classList.add("report-section");
+ if (className)
+ this.element.classList.add(className);
this._headerElement = this.element.createChild("div", "report-section-header");
this._titleElement = this._headerElement.createChild("div", "report-section-title");
this._titleElement.textContent = title;

Powered by Google App Engine
This is Rietveld 408576698