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

Unified Diff: cc/ScrollbarLayerChromiumTest.cpp

Issue 11099040: [cc] Store CCLayerImpls as scoped_ptrs (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix cc unit tests Created 8 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 | « cc/ScrollbarLayerChromium.cpp ('k') | cc/SolidColorLayerChromium.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/ScrollbarLayerChromiumTest.cpp
diff --git a/cc/ScrollbarLayerChromiumTest.cpp b/cc/ScrollbarLayerChromiumTest.cpp
index 0231e786758cc83f4894614a2b135f7f92c7d224..3aa6aa0865e2df8ee06caa3de2119d299560a787 100644
--- a/cc/ScrollbarLayerChromiumTest.cpp
+++ b/cc/ScrollbarLayerChromiumTest.cpp
@@ -57,7 +57,7 @@ TEST(ScrollbarLayerChromiumTest, resolveScrollLayerPointer)
layerTreeRoot->addChild(child1);
layerTreeRoot->addChild(child2);
- OwnPtr<CCLayerImpl> ccLayerTreeRoot = TreeSynchronizer::synchronizeTrees(layerTreeRoot.get(), nullptr, 0);
+ scoped_ptr<CCLayerImpl> ccLayerTreeRoot = TreeSynchronizer::synchronizeTrees(layerTreeRoot.get(), scoped_ptr<CCLayerImpl>(), 0);
CCLayerImpl* ccChild1 = ccLayerTreeRoot->children()[0];
CCScrollbarLayerImpl* ccChild2 = static_cast<CCScrollbarLayerImpl*>(ccLayerTreeRoot->children()[1]);
@@ -74,7 +74,7 @@ TEST(ScrollbarLayerChromiumTest, resolveScrollLayerPointer)
layerTreeRoot->addChild(child1);
layerTreeRoot->addChild(child2);
- OwnPtr<CCLayerImpl> ccLayerTreeRoot = TreeSynchronizer::synchronizeTrees(layerTreeRoot.get(), nullptr, 0);
+ scoped_ptr<CCLayerImpl> ccLayerTreeRoot = TreeSynchronizer::synchronizeTrees(layerTreeRoot.get(), scoped_ptr<CCLayerImpl>(), 0);
CCScrollbarLayerImpl* ccChild1 = static_cast<CCScrollbarLayerImpl*>(ccLayerTreeRoot->children()[0]);
CCLayerImpl* ccChild2 = ccLayerTreeRoot->children()[1];
@@ -101,7 +101,7 @@ TEST(ScrollbarLayerChromiumTest, scrollOffsetSynchronization)
layerTreeRoot->setMaxScrollPosition(IntSize(30, 50));
contentLayer->setBounds(IntSize(100, 200));
- OwnPtr<CCLayerImpl> ccLayerTreeRoot = TreeSynchronizer::synchronizeTrees(layerTreeRoot.get(), nullptr, 0);
+ scoped_ptr<CCLayerImpl> ccLayerTreeRoot = TreeSynchronizer::synchronizeTrees(layerTreeRoot.get(), scoped_ptr<CCLayerImpl>(), 0);
CCScrollbarLayerImpl* ccScrollbarLayer = static_cast<CCScrollbarLayerImpl*>(ccLayerTreeRoot->children()[1]);
@@ -114,7 +114,7 @@ TEST(ScrollbarLayerChromiumTest, scrollOffsetSynchronization)
contentLayer->setBounds(IntSize(1000, 2000));
CCScrollbarAnimationController* scrollbarController = ccLayerTreeRoot->scrollbarAnimationController();
- ccLayerTreeRoot = TreeSynchronizer::synchronizeTrees(layerTreeRoot.get(), ccLayerTreeRoot.release(), 0);
+ ccLayerTreeRoot = TreeSynchronizer::synchronizeTrees(layerTreeRoot.get(), ccLayerTreeRoot.Pass(), 0);
EXPECT_EQ(scrollbarController, ccLayerTreeRoot->scrollbarAnimationController());
EXPECT_EQ(100, ccScrollbarLayer->currentPos());
« no previous file with comments | « cc/ScrollbarLayerChromium.cpp ('k') | cc/SolidColorLayerChromium.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698