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

Side by Side Diff: cc/test/fake_layer_tree_host.h

Issue 2251143002: cc: Reland Move data to LayerTree from LayerTreeHost. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: better fix? Created 4 years, 4 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 unified diff | Download patch
OLDNEW
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 #ifndef CC_TEST_FAKE_LAYER_TREE_HOST_H_ 5 #ifndef CC_TEST_FAKE_LAYER_TREE_HOST_H_
6 #define CC_TEST_FAKE_LAYER_TREE_HOST_H_ 6 #define CC_TEST_FAKE_LAYER_TREE_HOST_H_
7 7
8 #include "cc/debug/micro_benchmark_controller.h" 8 #include "cc/debug/micro_benchmark_controller.h"
9 #include "cc/test/fake_impl_task_runner_provider.h" 9 #include "cc/test/fake_impl_task_runner_provider.h"
10 #include "cc/test/fake_layer_tree_host_client.h" 10 #include "cc/test/fake_layer_tree_host_client.h"
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 FakeLayerTreeHostClient* client, 42 FakeLayerTreeHostClient* client,
43 TestTaskGraphRunner* task_graph_runner, 43 TestTaskGraphRunner* task_graph_runner,
44 const LayerTreeSettings& settings, 44 const LayerTreeSettings& settings,
45 CompositorMode mode, 45 CompositorMode mode,
46 ImageSerializationProcessor* image_serialization_processor); 46 ImageSerializationProcessor* image_serialization_processor);
47 ~FakeLayerTreeHost() override; 47 ~FakeLayerTreeHost() override;
48 48
49 const RendererCapabilities& GetRendererCapabilities() const override; 49 const RendererCapabilities& GetRendererCapabilities() const override;
50 void SetNeedsCommit() override; 50 void SetNeedsCommit() override;
51 void SetNeedsUpdateLayers() override {} 51 void SetNeedsUpdateLayers() override {}
52 void SetNeedsFullTreeSync() override {}
53 52
54 using LayerTreeHost::SetRootLayer; 53 void SetRootLayer(scoped_refptr<Layer> root_layer) {
55 using LayerTreeHost::root_layer; 54 layer_tree_->SetRootLayer(root_layer);
55 }
56 Layer* root_layer() const { return layer_tree_->root_layer(); }
57 PropertyTrees* property_trees() const {
58 return layer_tree_->property_trees();
59 }
56 60
57 LayerImpl* CommitAndCreateLayerImplTree(); 61 LayerImpl* CommitAndCreateLayerImplTree();
58 LayerImpl* CommitAndCreatePendingTree(); 62 LayerImpl* CommitAndCreatePendingTree();
59 63
60 FakeLayerTreeHostImpl* host_impl() { return &host_impl_; } 64 FakeLayerTreeHostImpl* host_impl() { return &host_impl_; }
61 LayerTreeImpl* active_tree() { return host_impl_.active_tree(); } 65 LayerTreeImpl* active_tree() { return host_impl_.active_tree(); }
62 LayerTreeImpl* pending_tree() { return host_impl_.pending_tree(); } 66 LayerTreeImpl* pending_tree() { return host_impl_.pending_tree(); }
63 67
64 using LayerTreeHost::ScheduleMicroBenchmark; 68 using LayerTreeHost::ScheduleMicroBenchmark;
65 using LayerTreeHost::SendMessageToMicroBenchmark; 69 using LayerTreeHost::SendMessageToMicroBenchmark;
(...skipping 28 matching lines...) Expand all
94 FakeLayerTreeHostImpl host_impl_; 98 FakeLayerTreeHostImpl host_impl_;
95 bool needs_commit_; 99 bool needs_commit_;
96 100
97 bool renderer_capabilities_set; 101 bool renderer_capabilities_set;
98 RendererCapabilities renderer_capabilities; 102 RendererCapabilities renderer_capabilities;
99 }; 103 };
100 104
101 } // namespace cc 105 } // namespace cc
102 106
103 #endif // CC_TEST_FAKE_LAYER_TREE_HOST_H_ 107 #endif // CC_TEST_FAKE_LAYER_TREE_HOST_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698