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

Unified Diff: third_party/WebKit/Source/platform/graphics/GraphicsLayer.cpp

Issue 2389973002: Use std::unique_ptr to signal ownership transfer in WebCompositorSupport (Closed)
Patch Set: rebase Created 4 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
Index: third_party/WebKit/Source/platform/graphics/GraphicsLayer.cpp
diff --git a/third_party/WebKit/Source/platform/graphics/GraphicsLayer.cpp b/third_party/WebKit/Source/platform/graphics/GraphicsLayer.cpp
index 18d7bc3970f992c42e2468c61fbd5260de52b425..2eac66ac70d939243f33ab3055f4a80a22997b9f 100644
--- a/third_party/WebKit/Source/platform/graphics/GraphicsLayer.cpp
+++ b/third_party/WebKit/Source/platform/graphics/GraphicsLayer.cpp
@@ -116,9 +116,8 @@ GraphicsLayer::GraphicsLayer(GraphicsLayerClient* client)
#endif
m_contentLayerDelegate = wrapUnique(new ContentLayerDelegate(this));
- m_layer =
- wrapUnique(Platform::current()->compositorSupport()->createContentLayer(
- m_contentLayerDelegate.get()));
+ m_layer = Platform::current()->compositorSupport()->createContentLayer(
+ m_contentLayerDelegate.get());
m_layer->layer()->setDrawsContent(m_drawsContent && m_contentsVisible);
m_layer->layer()->setLayerClient(this);
}
@@ -1040,8 +1039,8 @@ void GraphicsLayer::setContentsToImage(
if (image && skImage) {
if (!m_imageLayer) {
- m_imageLayer = wrapUnique(
- Platform::current()->compositorSupport()->createImageLayer());
+ m_imageLayer =
+ Platform::current()->compositorSupport()->createImageLayer();
registerContentsLayer(m_imageLayer->layer());
}
m_imageLayer->setImage(skImage.get());

Powered by Google App Engine
This is Rietveld 408576698