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

Side by Side Diff: cc/test/fake_layer_tree_host_impl.cc

Issue 2668873002: cc: Add checker-imaging support to TileManager. (Closed)
Patch Set: remove include Created 3 years, 10 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
« no previous file with comments | « cc/test/fake_layer_tree_host_impl.h ('k') | cc/test/fake_layer_tree_host_impl_client.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 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_impl.h" 5 #include "cc/test/fake_layer_tree_host_impl.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include "cc/animation/animation_host.h" 9 #include "cc/animation/animation_host.h"
10 #include "cc/test/begin_frame_args_test.h" 10 #include "cc/test/begin_frame_args_test.h"
11 #include "cc/test/fake_layer_tree_host_impl.h" 11 #include "cc/test/fake_layer_tree_host_impl.h"
12 #include "cc/test/layer_tree_settings_for_testing.h" 12 #include "cc/test/layer_tree_settings_for_testing.h"
13 #include "cc/trees/layer_tree_impl.h" 13 #include "cc/trees/layer_tree_impl.h"
14 14
15 namespace cc { 15 namespace cc {
16 16
17 FakeLayerTreeHostImpl::FakeLayerTreeHostImpl( 17 FakeLayerTreeHostImpl::FakeLayerTreeHostImpl(
18 TaskRunnerProvider* task_runner_provider, 18 TaskRunnerProvider* task_runner_provider,
19 TaskGraphRunner* task_graph_runner) 19 TaskGraphRunner* task_graph_runner)
20 : FakeLayerTreeHostImpl(LayerTreeSettingsForTesting(), 20 : FakeLayerTreeHostImpl(LayerTreeSettingsForTesting(),
21 task_runner_provider, 21 task_runner_provider,
22 task_graph_runner) {} 22 task_graph_runner) {}
23 23
24 FakeLayerTreeHostImpl::FakeLayerTreeHostImpl( 24 FakeLayerTreeHostImpl::FakeLayerTreeHostImpl(
25 const LayerTreeSettings& settings, 25 const LayerTreeSettings& settings,
26 TaskRunnerProvider* task_runner_provider, 26 TaskRunnerProvider* task_runner_provider,
27 TaskGraphRunner* task_graph_runner) 27 TaskGraphRunner* task_graph_runner)
28 : FakeLayerTreeHostImpl(settings,
29 task_runner_provider,
30 task_graph_runner,
31 nullptr) {}
32
33 FakeLayerTreeHostImpl::FakeLayerTreeHostImpl(
34 const LayerTreeSettings& settings,
35 TaskRunnerProvider* task_runner_provider,
36 TaskGraphRunner* task_graph_runner,
37 scoped_refptr<base::SequencedTaskRunner> image_worker_task_runner)
28 : LayerTreeHostImpl(settings, 38 : LayerTreeHostImpl(settings,
29 &client_, 39 &client_,
30 task_runner_provider, 40 task_runner_provider,
31 &stats_instrumentation_, 41 &stats_instrumentation_,
32 task_graph_runner, 42 task_graph_runner,
33 AnimationHost::CreateForTesting(ThreadInstance::IMPL), 43 AnimationHost::CreateForTesting(ThreadInstance::IMPL),
34 0, 44 0,
35 nullptr), 45 std::move(image_worker_task_runner)),
36 notify_tile_state_changed_called_(false) { 46 notify_tile_state_changed_called_(false) {
37 // Explicitly clear all debug settings. 47 // Explicitly clear all debug settings.
38 SetDebugState(LayerTreeDebugState()); 48 SetDebugState(LayerTreeDebugState());
39 SetViewportSize(gfx::Size(100, 100)); 49 SetViewportSize(gfx::Size(100, 100));
40 50
41 // Start an impl frame so tests have a valid frame_time to work with. 51 // Start an impl frame so tests have a valid frame_time to work with.
42 base::TimeTicks time_ticks = base::TimeTicks::FromInternalValue(1); 52 base::TimeTicks time_ticks = base::TimeTicks::FromInternalValue(1);
43 WillBeginImplFrame( 53 WillBeginImplFrame(
44 CreateBeginFrameArgsForTesting(BEGINFRAME_FROM_HERE, 0, 1, time_ticks)); 54 CreateBeginFrameArgsForTesting(BEGINFRAME_FROM_HERE, 0, 1, time_ticks));
45 } 55 }
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 layerTree->BuildLayerListAndPropertyTreesForTesting(); 106 layerTree->BuildLayerListAndPropertyTreesForTesting();
97 layerTree->UpdateDrawProperties(update_lcd_text, 107 layerTree->UpdateDrawProperties(update_lcd_text,
98 force_skip_verify_visible_rect_calculations); 108 force_skip_verify_visible_rect_calculations);
99 } 109 }
100 110
101 AnimationHost* FakeLayerTreeHostImpl::animation_host() const { 111 AnimationHost* FakeLayerTreeHostImpl::animation_host() const {
102 return static_cast<AnimationHost*>(mutator_host()); 112 return static_cast<AnimationHost*>(mutator_host());
103 } 113 }
104 114
105 } // namespace cc 115 } // namespace cc
OLDNEW
« no previous file with comments | « cc/test/fake_layer_tree_host_impl.h ('k') | cc/test/fake_layer_tree_host_impl_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698