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

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

Issue 2854953006: Move disable_display_vsync out of RendererSettings (Closed)
Patch Set: Fix LayoutTestSupport Created 3 years, 7 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 332 matching lines...) Expand 10 before | Expand all | Expand 10 after
343 ScreenInfo dummy_screen_info; 343 ScreenInfo dummy_screen_info;
344 cc::LayerTreeSettings settings = 344 cc::LayerTreeSettings settings =
345 RenderWidgetCompositor::GenerateLayerTreeSettings( 345 RenderWidgetCompositor::GenerateLayerTreeSettings(
346 *base::CommandLine::ForCurrentProcess(), deps, 1.f, false, 346 *base::CommandLine::ForCurrentProcess(), deps, 1.f, false,
347 dummy_screen_info); 347 dummy_screen_info);
348 348
349 auto compositor_frame_sink = base::MakeUnique<cc::TestCompositorFrameSink>( 349 auto compositor_frame_sink = base::MakeUnique<cc::TestCompositorFrameSink>(
350 std::move(compositor_context_provider), 350 std::move(compositor_context_provider),
351 std::move(worker_context_provider), nullptr /* shared_bitmap_manager */, 351 std::move(worker_context_provider), nullptr /* shared_bitmap_manager */,
352 gpu_memory_buffer_manager, settings.renderer_settings, task_runner, 352 gpu_memory_buffer_manager, settings.renderer_settings, task_runner,
353 synchronous_composite); 353 synchronous_composite, false);
danakj 2017/05/04 15:36:36 /* disable_display_vsync */ or use a local var
Alex Z. 2017/05/04 18:41:56 Done.
354 compositor_frame_sink->SetClient(this); 354 compositor_frame_sink->SetClient(this);
355 compositor_frame_sinks_[routing_id] = compositor_frame_sink.get(); 355 compositor_frame_sinks_[routing_id] = compositor_frame_sink.get();
356 return std::move(compositor_frame_sink); 356 return std::move(compositor_frame_sink);
357 } 357 }
358 358
359 std::unique_ptr<cc::SwapPromise> RequestCopyOfOutput( 359 std::unique_ptr<cc::SwapPromise> RequestCopyOfOutput(
360 int32_t routing_id, 360 int32_t routing_id,
361 std::unique_ptr<cc::CopyOutputRequest> request) override { 361 std::unique_ptr<cc::CopyOutputRequest> request) override {
362 // Note that we can't immediately check compositor_frame_sinks_, since it 362 // Note that we can't immediately check compositor_frame_sinks_, since it
363 // may not have been created yet. Instead, we wait until OnCommit to find 363 // may not have been created yet. Instead, we wait until OnCommit to find
(...skipping 233 matching lines...) Expand 10 before | Expand all | Expand 10 after
597 } 597 }
598 } 598 }
599 599
600 bool IsNavigationInitiatedByRenderer(const blink::WebURLRequest& request) { 600 bool IsNavigationInitiatedByRenderer(const blink::WebURLRequest& request) {
601 RequestExtraData* extra_data = 601 RequestExtraData* extra_data =
602 static_cast<RequestExtraData*>(request.GetExtraData()); 602 static_cast<RequestExtraData*>(request.GetExtraData());
603 return extra_data && extra_data->navigation_initiated_by_renderer(); 603 return extra_data && extra_data->navigation_initiated_by_renderer();
604 } 604 }
605 605
606 } // namespace content 606 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698