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

Unified Diff: Source/devtools/front_end/timeline/LayerDetailsView.js

Issue 670503002: Timeline: add layer details view (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 2 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
« no previous file with comments | « Source/devtools/front_end/sdk/LayerTreeModel.js ('k') | Source/devtools/front_end/timeline/Layers3DView.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/devtools/front_end/timeline/LayerDetailsView.js
diff --git a/Source/devtools/front_end/layers/LayerDetailsView.js b/Source/devtools/front_end/timeline/LayerDetailsView.js
similarity index 95%
rename from Source/devtools/front_end/layers/LayerDetailsView.js
rename to Source/devtools/front_end/timeline/LayerDetailsView.js
index b32ca347d725f27aa7b0b1ecc0a7c3a4ccf81b90..d32c5996c0d721da03e75f9e763fc07aa671443b 100644
--- a/Source/devtools/front_end/layers/LayerDetailsView.js
+++ b/Source/devtools/front_end/timeline/LayerDetailsView.js
@@ -88,7 +88,7 @@ WebInspector.LayerDetailsView.CompositingReasonDetail = {
WebInspector.LayerDetailsView.prototype = {
/**
- * @param {!WebInspector.Layers3DView.ActiveObject} activeObject
+ * @param {?WebInspector.Layers3DView.ActiveObject} activeObject
*/
setObject: function(activeObject)
{
@@ -181,17 +181,15 @@ WebInspector.LayerDetailsView.prototype = {
this._compositingReasonsCell.textContent = "n/a";
return;
}
- var fragment = createDocumentFragment();
+ this._compositingReasonsCell.removeChildren();
+ var list = this._compositingReasonsCell.createChild("ul");
for (var i = 0; i < compositingReasons.length; ++i) {
- if (i)
- fragment.createTextChild(",");
- var span = createElement("span");
- span.title = WebInspector.LayerDetailsView.CompositingReasonDetail[compositingReasons[i]] || "";
- span.textContent = compositingReasons[i];
- fragment.appendChild(span);
+ var text = WebInspector.LayerDetailsView.CompositingReasonDetail[compositingReasons[i]] || compositingReasons[i];
+ // If the text is more than one word but does not terminate with period, add the period.
+ if (/\s.*[^.]$/.test(text))
+ text += ".";
+ list.createChild("li").textContent = text;
}
- this._compositingReasonsCell.removeChildren();
- this._compositingReasonsCell.appendChild(fragment);
},
__proto__: WebInspector.VBox.prototype
« no previous file with comments | « Source/devtools/front_end/sdk/LayerTreeModel.js ('k') | Source/devtools/front_end/timeline/Layers3DView.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698