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 "base/threading/thread_task_runner_handle.h" | 8 #include "base/threading/thread_task_runner_handle.h" |
9 #include "cc/animation/animation_host.h" | 9 #include "cc/animation/animation_host.h" |
10 #include "cc/layers/layer.h" | 10 #include "cc/layers/layer.h" |
(...skipping 17 matching lines...) Expand all Loading... |
28 SetTaskRunnerProviderForTesting(TaskRunnerProvider::Create( | 28 SetTaskRunnerProviderForTesting(TaskRunnerProvider::Create( |
29 base::ThreadTaskRunnerHandle::Get(), impl_task_runner)); | 29 base::ThreadTaskRunnerHandle::Get(), impl_task_runner)); |
30 client_->SetLayerTreeHost(this); | 30 client_->SetLayerTreeHost(this); |
31 } | 31 } |
32 | 32 |
33 std::unique_ptr<FakeLayerTreeHost> FakeLayerTreeHost::Create( | 33 std::unique_ptr<FakeLayerTreeHost> FakeLayerTreeHost::Create( |
34 FakeLayerTreeHostClient* client, | 34 FakeLayerTreeHostClient* client, |
35 TestTaskGraphRunner* task_graph_runner, | 35 TestTaskGraphRunner* task_graph_runner, |
36 MutatorHost* mutator_host) { | 36 MutatorHost* mutator_host) { |
37 LayerTreeSettings settings; | 37 LayerTreeSettings settings; |
38 settings.verify_clip_tree_calculations = true; | |
39 return Create(client, task_graph_runner, mutator_host, settings); | 38 return Create(client, task_graph_runner, mutator_host, settings); |
40 } | 39 } |
41 | 40 |
42 std::unique_ptr<FakeLayerTreeHost> FakeLayerTreeHost::Create( | 41 std::unique_ptr<FakeLayerTreeHost> FakeLayerTreeHost::Create( |
43 FakeLayerTreeHostClient* client, | 42 FakeLayerTreeHostClient* client, |
44 TestTaskGraphRunner* task_graph_runner, | 43 TestTaskGraphRunner* task_graph_runner, |
45 MutatorHost* mutator_host, | 44 MutatorHost* mutator_host, |
46 const LayerTreeSettings& settings) { | 45 const LayerTreeSettings& settings) { |
47 return Create(client, task_graph_runner, mutator_host, settings, | 46 return Create(client, task_graph_runner, mutator_host, settings, |
48 CompositorMode::SINGLE_THREADED); | 47 CompositorMode::SINGLE_THREADED); |
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
97 TreeSynchronizer::PushLayerProperties(root_layer()->layer_tree_host(), | 96 TreeSynchronizer::PushLayerProperties(root_layer()->layer_tree_host(), |
98 pending_tree()); | 97 pending_tree()); |
99 mutator_host()->PushPropertiesTo(host_impl_.mutator_host()); | 98 mutator_host()->PushPropertiesTo(host_impl_.mutator_host()); |
100 | 99 |
101 pending_tree()->property_trees()->scroll_tree.PushScrollUpdatesFromMainThread( | 100 pending_tree()->property_trees()->scroll_tree.PushScrollUpdatesFromMainThread( |
102 property_trees(), pending_tree()); | 101 property_trees(), pending_tree()); |
103 return pending_tree()->root_layer_for_testing(); | 102 return pending_tree()->root_layer_for_testing(); |
104 } | 103 } |
105 | 104 |
106 } // namespace cc | 105 } // namespace cc |
OLD | NEW |