| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/test/fake_layer_tree_host.h" | 5 #include "cc/test/fake_layer_tree_host.h" |
| 6 | 6 |
| 7 #include "base/memory/ptr_util.h" | 7 #include "base/memory/ptr_util.h" |
| 8 #include "cc/animation/animation_host.h" | 8 #include "cc/animation/animation_host.h" |
| 9 #include "cc/layers/layer.h" | 9 #include "cc/layers/layer.h" |
| 10 #include "cc/test/fake_image_serialization_processor.h" | 10 #include "cc/test/fake_image_serialization_processor.h" |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 47 base::ThreadTaskRunnerHandle::Get(), impl_task_runner)); | 47 base::ThreadTaskRunnerHandle::Get(), impl_task_runner)); |
| 48 client_->SetLayerTreeHost(this); | 48 client_->SetLayerTreeHost(this); |
| 49 } | 49 } |
| 50 | 50 |
| 51 std::unique_ptr<FakeLayerTreeHost> FakeLayerTreeHost::Create( | 51 std::unique_ptr<FakeLayerTreeHost> FakeLayerTreeHost::Create( |
| 52 FakeLayerTreeHostClient* client, | 52 FakeLayerTreeHostClient* client, |
| 53 TestTaskGraphRunner* task_graph_runner) { | 53 TestTaskGraphRunner* task_graph_runner) { |
| 54 LayerTreeSettings settings; | 54 LayerTreeSettings settings; |
| 55 settings.verify_transform_tree_calculations = true; | 55 settings.verify_transform_tree_calculations = true; |
| 56 settings.verify_clip_tree_calculations = true; | 56 settings.verify_clip_tree_calculations = true; |
| 57 settings.verify_visible_rect_calculations = true; |
| 57 return Create(client, task_graph_runner, settings); | 58 return Create(client, task_graph_runner, settings); |
| 58 } | 59 } |
| 59 | 60 |
| 60 std::unique_ptr<FakeLayerTreeHost> FakeLayerTreeHost::Create( | 61 std::unique_ptr<FakeLayerTreeHost> FakeLayerTreeHost::Create( |
| 61 FakeLayerTreeHostClient* client, | 62 FakeLayerTreeHostClient* client, |
| 62 TestTaskGraphRunner* task_graph_runner, | 63 TestTaskGraphRunner* task_graph_runner, |
| 63 const LayerTreeSettings& settings) { | 64 const LayerTreeSettings& settings) { |
| 64 return Create(client, task_graph_runner, settings, | 65 return Create(client, task_graph_runner, settings, |
| 65 CompositorMode::SINGLE_THREADED); | 66 CompositorMode::SINGLE_THREADED); |
| 66 } | 67 } |
| (...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 130 pending_tree()->SetPropertyTrees(property_trees()); | 131 pending_tree()->SetPropertyTrees(property_trees()); |
| 131 TreeSynchronizer::PushLayerProperties(root_layer()->GetLayerTree(), | 132 TreeSynchronizer::PushLayerProperties(root_layer()->GetLayerTree(), |
| 132 pending_tree()); | 133 pending_tree()); |
| 133 layer_tree_->animation_host()->PushPropertiesTo(host_impl_.animation_host()); | 134 layer_tree_->animation_host()->PushPropertiesTo(host_impl_.animation_host()); |
| 134 | 135 |
| 135 pending_tree()->UpdatePropertyTreeScrollOffset(property_trees()); | 136 pending_tree()->UpdatePropertyTreeScrollOffset(property_trees()); |
| 136 return pending_tree()->root_layer_for_testing(); | 137 return pending_tree()->root_layer_for_testing(); |
| 137 } | 138 } |
| 138 | 139 |
| 139 } // namespace cc | 140 } // namespace cc |
| OLD | NEW |