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

Side by Side Diff: content/test/layouttest_support.cc

Issue 2208693003: Revert of cc: Make LayerTreeTests use a DelegatingRenderer and Display. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 "content/public/test/layouttest_support.h" 5 #include "content/public/test/layouttest_support.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 246 matching lines...) Expand 10 before | Expand all | Expand 10 after
257 task_runner = base::ThreadTaskRunnerHandle::Get().get(); 257 task_runner = base::ThreadTaskRunnerHandle::Get().get();
258 258
259 cc::LayerTreeSettings settings = 259 cc::LayerTreeSettings settings =
260 RenderWidgetCompositor::GenerateLayerTreeSettings( 260 RenderWidgetCompositor::GenerateLayerTreeSettings(
261 *base::CommandLine::ForCurrentProcess(), deps, 1.f); 261 *base::CommandLine::ForCurrentProcess(), deps, 1.f);
262 262
263 auto output_surface = base::MakeUnique<cc::TestDelegatingOutputSurface>( 263 auto output_surface = base::MakeUnique<cc::TestDelegatingOutputSurface>(
264 std::move(compositor_context_provider), 264 std::move(compositor_context_provider),
265 std::move(worker_context_provider), std::move(display_output_surface), 265 std::move(worker_context_provider), std::move(display_output_surface),
266 deps->GetSharedBitmapManager(), deps->GetGpuMemoryBufferManager(), 266 deps->GetSharedBitmapManager(), deps->GetGpuMemoryBufferManager(),
267 settings.renderer_settings, task_runner, synchronous_composite, 267 settings.renderer_settings, task_runner, synchronous_composite);
268 false /* force_disable_reclaim_resources */);
269 output_surfaces_[routing_id] = output_surface.get(); 268 output_surfaces_[routing_id] = output_surface.get();
270 return std::move(output_surface); 269 return std::move(output_surface);
271 } 270 }
272 271
273 std::unique_ptr<cc::SwapPromise> RequestCopyOfOutput( 272 std::unique_ptr<cc::SwapPromise> RequestCopyOfOutput(
274 int32_t routing_id, 273 int32_t routing_id,
275 std::unique_ptr<cc::CopyOutputRequest> request) override { 274 std::unique_ptr<cc::CopyOutputRequest> request) override {
276 // Note that we can't immediately check output_surfaces_, since it may not 275 // Note that we can't immediately check output_surfaces_, since it may not
277 // have been created yet. Instead, we wait until OnCommit to find the 276 // have been created yet. Instead, we wait until OnCommit to find the
278 // currently active OutputSurface for the given RenderWidget routing_id. 277 // currently active OutputSurface for the given RenderWidget routing_id.
(...skipping 291 matching lines...) Expand 10 before | Expand all | Expand 10 after
570 return result; 569 return result;
571 } 570 }
572 571
573 void SchedulerRunIdleTasks(const base::Closure& callback) { 572 void SchedulerRunIdleTasks(const base::Closure& callback) {
574 scheduler::RendererScheduler* scheduler = 573 scheduler::RendererScheduler* scheduler =
575 content::RenderThreadImpl::current()->GetRendererScheduler(); 574 content::RenderThreadImpl::current()->GetRendererScheduler();
576 scheduler::RunIdleTasksForTesting(scheduler, callback); 575 scheduler::RunIdleTasksForTesting(scheduler, callback);
577 } 576 }
578 577
579 } // namespace content 578 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/gpu/render_widget_compositor_unittest.cc ('k') | services/ui/surfaces/display_compositor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698