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

Unified Diff: Source/platform/graphics/GraphicsLayerDebugInfo.cpp

Issue 135473002: Include debug name in GraphicsLayerDebugInfo. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: . Created 6 years, 11 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/platform/graphics/GraphicsLayerDebugInfo.h ('k') | public/platform/WebLayerClient.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/graphics/GraphicsLayerDebugInfo.cpp
diff --git a/Source/platform/graphics/GraphicsLayerDebugInfo.cpp b/Source/platform/graphics/GraphicsLayerDebugInfo.cpp
index cb92348ddfe525d8df65dd63524788feace8b7a3..4dcf64afd2c9c0111897171da44b41d334632e05 100644
--- a/Source/platform/graphics/GraphicsLayerDebugInfo.cpp
+++ b/Source/platform/graphics/GraphicsLayerDebugInfo.cpp
@@ -37,6 +37,7 @@ void GraphicsLayerDebugInfo::appendAsTraceFormat(blink::WebString* out) const
RefPtr<JSONObject> jsonObject = JSONObject::create();
appendLayoutRects(jsonObject.get());
appendCompositingReasons(jsonObject.get());
+ appendDebugName(jsonObject.get());
*out = jsonObject->toJSONString();
}
@@ -180,4 +181,12 @@ void GraphicsLayerDebugInfo::appendCompositingReasons(JSONObject* jsonObject) co
jsonObject->setArray("compositing_reasons", jsonArray);
}
+void GraphicsLayerDebugInfo::appendDebugName(JSONObject* jsonObject) const
+{
+ if (m_debugName.isEmpty())
+ return;
+
+ jsonObject->setString("layer_name", m_debugName);
+}
+
} // namespace WebCore
« no previous file with comments | « Source/platform/graphics/GraphicsLayerDebugInfo.h ('k') | public/platform/WebLayerClient.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698