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

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

Issue 1385043002: cc: Remove SetLayerTreeHostClientReady() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@startcomp
Patch Set: sky's offline comment Created 5 years, 2 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_proxy.h ('k') | cc/test/layer_tree_test.cc » ('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/layer_test_common.h" 5 #include "cc/test/layer_test_common.h"
6 6
7 #include "cc/base/math_util.h" 7 #include "cc/base/math_util.h"
8 #include "cc/base/region.h" 8 #include "cc/base/region.h"
9 #include "cc/layers/append_quads_data.h" 9 #include "cc/layers/append_quads_data.h"
10 #include "cc/quads/draw_quad.h" 10 #include "cc/quads/draw_quad.h"
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 } 113 }
114 114
115 LayerTestCommon::LayerImplTest::LayerImplTest(const LayerTreeSettings& settings) 115 LayerTestCommon::LayerImplTest::LayerImplTest(const LayerTreeSettings& settings)
116 : client_(FakeLayerTreeHostClient::DIRECT_3D), 116 : client_(FakeLayerTreeHostClient::DIRECT_3D),
117 output_surface_(FakeOutputSurface::Create3d()), 117 output_surface_(FakeOutputSurface::Create3d()),
118 host_(FakeLayerTreeHost::Create(&client_, &task_graph_runner_, settings)), 118 host_(FakeLayerTreeHost::Create(&client_, &task_graph_runner_, settings)),
119 root_layer_impl_(LayerImpl::Create(host_->host_impl()->active_tree(), 1)), 119 root_layer_impl_(LayerImpl::Create(host_->host_impl()->active_tree(), 1)),
120 render_pass_(RenderPass::Create()), 120 render_pass_(RenderPass::Create()),
121 layer_impl_id_(2) { 121 layer_impl_id_(2) {
122 root_layer_impl_->SetHasRenderSurface(true); 122 root_layer_impl_->SetHasRenderSurface(true);
123 host_->host_impl()->SetVisible(true);
123 host_->host_impl()->InitializeRenderer(output_surface_.get()); 124 host_->host_impl()->InitializeRenderer(output_surface_.get());
124 } 125 }
125 126
126 LayerTestCommon::LayerImplTest::~LayerImplTest() {} 127 LayerTestCommon::LayerImplTest::~LayerImplTest() {}
127 128
128 void LayerTestCommon::LayerImplTest::CalcDrawProps( 129 void LayerTestCommon::LayerImplTest::CalcDrawProps(
129 const gfx::Size& viewport_size) { 130 const gfx::Size& viewport_size) {
130 LayerImplList layer_list; 131 LayerImplList layer_list;
131 LayerTreeHostCommon::CalcDrawPropsImplInputsForTesting inputs( 132 LayerTreeHostCommon::CalcDrawPropsImplInputsForTesting inputs(
132 root_layer_impl_.get(), viewport_size, &layer_list); 133 root_layer_impl_.get(), viewport_size, &layer_list);
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
179 render_pass_->shared_quad_state_list.clear(); 180 render_pass_->shared_quad_state_list.clear();
180 181
181 surface_impl->AppendQuads( 182 surface_impl->AppendQuads(
182 render_pass_.get(), gfx::Transform(), 183 render_pass_.get(), gfx::Transform(),
183 Occlusion(gfx::Transform(), SimpleEnclosedRegion(occluded), 184 Occlusion(gfx::Transform(), SimpleEnclosedRegion(occluded),
184 SimpleEnclosedRegion()), 185 SimpleEnclosedRegion()),
185 SK_ColorBLACK, 1.f, nullptr, &data, RenderPassId(1, 1)); 186 SK_ColorBLACK, 1.f, nullptr, &data, RenderPassId(1, 1));
186 } 187 }
187 188
188 } // namespace cc 189 } // namespace cc
OLDNEW
« no previous file with comments | « cc/test/fake_proxy.h ('k') | cc/test/layer_tree_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698