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

Unified Diff: third_party/WebKit/Source/core/page/scrolling/ScrollingCoordinator.cpp

Issue 1980893002: Remove OwnPtr::release() calls in core/ (part 4). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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/core/page/scrolling/ScrollingCoordinator.cpp
diff --git a/third_party/WebKit/Source/core/page/scrolling/ScrollingCoordinator.cpp b/third_party/WebKit/Source/core/page/scrolling/ScrollingCoordinator.cpp
index 120b2a1e3cd90b850cbba145b5db087969ca3642..97799b10a5ac01fb9daa42727134a48aab38e27a 100644
--- a/third_party/WebKit/Source/core/page/scrolling/ScrollingCoordinator.cpp
+++ b/third_party/WebKit/Source/core/page/scrolling/ScrollingCoordinator.cpp
@@ -286,7 +286,7 @@ static PassOwnPtr<WebScrollbarLayer> createScrollbarLayer(Scrollbar& scrollbar,
OwnPtr<WebScrollbarLayer> scrollbarLayer = adoptPtr(Platform::current()->compositorSupport()->createScrollbarLayer(WebScrollbarImpl::create(&scrollbar), painter, geometry.leakPtr()));
GraphicsLayer::registerContentsLayer(scrollbarLayer->layer());
- return scrollbarLayer.release();
+ return scrollbarLayer;
}
PassOwnPtr<WebScrollbarLayer> ScrollingCoordinator::createSolidColorScrollbarLayer(ScrollbarOrientation orientation, int thumbThickness, int trackStart, bool isLeftSideVerticalScrollbar)
@@ -294,7 +294,7 @@ PassOwnPtr<WebScrollbarLayer> ScrollingCoordinator::createSolidColorScrollbarLay
WebScrollbar::Orientation webOrientation = (orientation == HorizontalScrollbar) ? WebScrollbar::Horizontal : WebScrollbar::Vertical;
OwnPtr<WebScrollbarLayer> scrollbarLayer = adoptPtr(Platform::current()->compositorSupport()->createSolidColorScrollbarLayer(webOrientation, thumbThickness, trackStart, isLeftSideVerticalScrollbar));
GraphicsLayer::registerContentsLayer(scrollbarLayer->layer());
- return scrollbarLayer.release();
+ return scrollbarLayer;
}
static void detachScrollbarLayer(GraphicsLayer* scrollbarGraphicsLayer)
@@ -356,7 +356,7 @@ void ScrollingCoordinator::scrollableAreaScrollbarLayerDidChange(ScrollableArea*
} else {
webScrollbarLayer = createScrollbarLayer(scrollbar, m_page->deviceScaleFactor());
}
- scrollbarLayer = addWebScrollbarLayer(scrollableArea, orientation, webScrollbarLayer.release());
+ scrollbarLayer = addWebScrollbarLayer(scrollableArea, orientation, std::move(webScrollbarLayer));
}
WebLayer* scrollLayer = toWebLayer(scrollableArea->layerForScrolling());

Powered by Google App Engine
This is Rietveld 408576698