| OLD | NEW |
| 1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "cc/trees/tree_synchronizer.h" | 5 #include "cc/trees/tree_synchronizer.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 #include <set> | 10 #include <set> |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 53 | 53 |
| 54 class MockLayer : public Layer { | 54 class MockLayer : public Layer { |
| 55 public: | 55 public: |
| 56 static scoped_refptr<MockLayer> Create( | 56 static scoped_refptr<MockLayer> Create( |
| 57 std::vector<int>* layer_impl_destruction_list) { | 57 std::vector<int>* layer_impl_destruction_list) { |
| 58 return make_scoped_refptr(new MockLayer(layer_impl_destruction_list)); | 58 return make_scoped_refptr(new MockLayer(layer_impl_destruction_list)); |
| 59 } | 59 } |
| 60 | 60 |
| 61 std::unique_ptr<LayerImpl> CreateLayerImpl( | 61 std::unique_ptr<LayerImpl> CreateLayerImpl( |
| 62 LayerTreeImpl* tree_impl) override { | 62 LayerTreeImpl* tree_impl) override { |
| 63 return MockLayerImpl::Create(tree_impl, layer_id_); | 63 return MockLayerImpl::Create(tree_impl, id()); |
| 64 } | 64 } |
| 65 | 65 |
| 66 void PushPropertiesTo(LayerImpl* layer_impl) override { | 66 void PushPropertiesTo(LayerImpl* layer_impl) override { |
| 67 Layer::PushPropertiesTo(layer_impl); | 67 Layer::PushPropertiesTo(layer_impl); |
| 68 | 68 |
| 69 MockLayerImpl* mock_layer_impl = static_cast<MockLayerImpl*>(layer_impl); | 69 MockLayerImpl* mock_layer_impl = static_cast<MockLayerImpl*>(layer_impl); |
| 70 mock_layer_impl->SetLayerImplDestructionList(layer_impl_destruction_list_); | 70 mock_layer_impl->SetLayerImplDestructionList(layer_impl_destruction_list_); |
| 71 } | 71 } |
| 72 | 72 |
| 73 private: | 73 private: |
| (...skipping 624 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 698 host_->CommitAndCreatePendingTree(); | 698 host_->CommitAndCreatePendingTree(); |
| 699 host_impl->ActivateSyncTree(); | 699 host_impl->ActivateSyncTree(); |
| 700 EXPECT_EQ( | 700 EXPECT_EQ( |
| 701 CombinedAnimationScale(0.f, 0.f), | 701 CombinedAnimationScale(0.f, 0.f), |
| 702 host_impl->active_tree()->property_trees()->GetAnimationScales( | 702 host_impl->active_tree()->property_trees()->GetAnimationScales( |
| 703 transform_layer->transform_tree_index(), host_impl->active_tree())); | 703 transform_layer->transform_tree_index(), host_impl->active_tree())); |
| 704 } | 704 } |
| 705 | 705 |
| 706 } // namespace | 706 } // namespace |
| 707 } // namespace cc | 707 } // namespace cc |
| OLD | NEW |