| Index: cc/trees/layer_tree_host_unittest_picture.cc
|
| diff --git a/cc/trees/layer_tree_host_unittest_picture.cc b/cc/trees/layer_tree_host_unittest_picture.cc
|
| index 9c5d00eddb145249b7099a090634019f6afafaf9..ec42144df83176bd59c98fe01981235e5b309c58 100644
|
| --- a/cc/trees/layer_tree_host_unittest_picture.cc
|
| +++ b/cc/trees/layer_tree_host_unittest_picture.cc
|
| @@ -81,7 +81,8 @@ class LayerTreeHostPictureTestTwinLayer
|
| }
|
|
|
| FakePictureLayerImpl* pending_picture_impl =
|
| - static_cast<FakePictureLayerImpl*>(pending_root_impl->children()[0]);
|
| + static_cast<FakePictureLayerImpl*>(
|
| + pending_root_impl->children()[0].get());
|
|
|
| if (!active_root_impl) {
|
| EXPECT_EQ(0, activates_);
|
| @@ -96,7 +97,8 @@ class LayerTreeHostPictureTestTwinLayer
|
| }
|
|
|
| FakePictureLayerImpl* active_picture_impl =
|
| - static_cast<FakePictureLayerImpl*>(active_root_impl->children()[0]);
|
| + static_cast<FakePictureLayerImpl*>(
|
| + active_root_impl->children()[0].get());
|
|
|
| // After the first activation, when we commit again, we'll have a pending
|
| // and active layer. Then we recreate a picture layer in the 4th activate
|
| @@ -115,7 +117,8 @@ class LayerTreeHostPictureTestTwinLayer
|
| EXPECT_EQ(2, activates_);
|
| } else {
|
| FakePictureLayerImpl* active_picture_impl =
|
| - static_cast<FakePictureLayerImpl*>(active_root_impl->children()[0]);
|
| + static_cast<FakePictureLayerImpl*>(
|
| + active_root_impl->children()[0].get());
|
| EXPECT_EQ(nullptr, active_picture_impl->GetPendingOrActiveTwinLayer());
|
| }
|
|
|
| @@ -152,7 +155,7 @@ class LayerTreeHostPictureTestResizeViewportWithGpuRaster
|
| void BeginTest() override { PostSetNeedsCommitToMainThread(); }
|
|
|
| void CommitCompleteOnThread(LayerTreeHostImpl* impl) override {
|
| - LayerImpl* child = impl->sync_tree()->root_layer()->children()[0];
|
| + LayerImpl* child = impl->sync_tree()->root_layer()->children()[0].get();
|
| FakePictureLayerImpl* picture_impl =
|
| static_cast<FakePictureLayerImpl*>(child);
|
| gfx::Size tile_size =
|
| @@ -221,7 +224,7 @@ class LayerTreeHostPictureTestChangeLiveTilesRectWithRecycleTree
|
| void BeginTest() override { PostSetNeedsCommitToMainThread(); }
|
|
|
| void DrawLayersOnThread(LayerTreeHostImpl* impl) override {
|
| - LayerImpl* child = impl->active_tree()->root_layer()->children()[0];
|
| + LayerImpl* child = impl->active_tree()->root_layer()->children()[0].get();
|
| FakePictureLayerImpl* picture_impl =
|
| static_cast<FakePictureLayerImpl*>(child);
|
| switch (++frame_) {
|
| @@ -272,7 +275,7 @@ class LayerTreeHostPictureTestChangeLiveTilesRectWithRecycleTree
|
| }
|
|
|
| void WillActivateTreeOnThread(LayerTreeHostImpl* impl) override {
|
| - LayerImpl* child = impl->sync_tree()->root_layer()->children()[0];
|
| + LayerImpl* child = impl->sync_tree()->root_layer()->children()[0].get();
|
| FakePictureLayerImpl* picture_impl =
|
| static_cast<FakePictureLayerImpl*>(child);
|
| PictureLayerTiling* tiling = picture_impl->HighResTiling();
|
| @@ -326,8 +329,8 @@ class LayerTreeHostPictureTestRSLLMembership : public LayerTreeHostPictureTest {
|
|
|
| void CommitCompleteOnThread(LayerTreeHostImpl* impl) override {
|
| LayerImpl* root = impl->sync_tree()->root_layer();
|
| - LayerImpl* child = root->children()[0];
|
| - LayerImpl* gchild = child->children()[0];
|
| + LayerImpl* child = root->children()[0].get();
|
| + LayerImpl* gchild = child->children()[0].get();
|
| FakePictureLayerImpl* picture = static_cast<FakePictureLayerImpl*>(gchild);
|
|
|
| switch (impl->sync_tree()->source_frame_number()) {
|
| @@ -348,8 +351,8 @@ class LayerTreeHostPictureTestRSLLMembership : public LayerTreeHostPictureTest {
|
|
|
| void DidActivateTreeOnThread(LayerTreeHostImpl* impl) override {
|
| LayerImpl* root = impl->active_tree()->root_layer();
|
| - LayerImpl* child = root->children()[0];
|
| - LayerImpl* gchild = child->children()[0];
|
| + LayerImpl* child = root->children()[0].get();
|
| + LayerImpl* gchild = child->children()[0].get();
|
| FakePictureLayerImpl* picture = static_cast<FakePictureLayerImpl*>(gchild);
|
|
|
| switch (impl->active_tree()->source_frame_number()) {
|
| @@ -430,8 +433,8 @@ class LayerTreeHostPictureTestRSLLMembershipWithScale
|
|
|
| void WillActivateTreeOnThread(LayerTreeHostImpl* impl) override {
|
| LayerImpl* root = impl->sync_tree()->root_layer();
|
| - LayerImpl* pinch = root->children()[0];
|
| - LayerImpl* gchild = pinch->children()[0];
|
| + LayerImpl* pinch = root->children()[0].get();
|
| + LayerImpl* gchild = pinch->children()[0].get();
|
| FakePictureLayerImpl* picture = static_cast<FakePictureLayerImpl*>(gchild);
|
| ready_to_draw_ = false;
|
|
|
| @@ -457,8 +460,8 @@ class LayerTreeHostPictureTestRSLLMembershipWithScale
|
|
|
| void DrawLayersOnThread(LayerTreeHostImpl* impl) override {
|
| LayerImpl* root = impl->active_tree()->root_layer();
|
| - LayerImpl* pinch = root->children()[0];
|
| - LayerImpl* gchild = pinch->children()[0];
|
| + LayerImpl* pinch = root->children()[0].get();
|
| + LayerImpl* gchild = pinch->children()[0].get();
|
| FakePictureLayerImpl* picture = static_cast<FakePictureLayerImpl*>(gchild);
|
|
|
| if (frame_ != last_frame_drawn_)
|
|
|