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

Side by Side Diff: content/browser/android/in_process/synchronous_compositor_impl.cc

Issue 1253553002: Add switch to use ipc command buffer in Android WebView (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review Created 5 years, 5 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 #include "content/browser/android/in_process/synchronous_compositor_impl.h" 5 #include "content/browser/android/in_process/synchronous_compositor_impl.h"
6 6
7 #include "base/auto_reset.h" 7 #include "base/auto_reset.h"
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "base/lazy_instance.h" 9 #include "base/lazy_instance.h"
10 #include "base/message_loop/message_loop.h" 10 #include "base/message_loop/message_loop.h"
(...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after
140 g_factory.Get().SetDeferredGpuService(service); 140 g_factory.Get().SetDeferredGpuService(service);
141 GpuProcessHost::RegisterGpuMainThreadFactory( 141 GpuProcessHost::RegisterGpuMainThreadFactory(
142 CreateInProcessGpuThreadForSynchronousCompositor); 142 CreateInProcessGpuThreadForSynchronousCompositor);
143 } 143 }
144 144
145 // static 145 // static
146 void SynchronousCompositor::SetRecordFullDocument(bool record_full_document) { 146 void SynchronousCompositor::SetRecordFullDocument(bool record_full_document) {
147 g_factory.Get().SetRecordFullDocument(record_full_document); 147 g_factory.Get().SetRecordFullDocument(record_full_document);
148 } 148 }
149 149
150 // static
151 void SynchronousCompositor::SetUseIpcCommandBuffer() {
152 g_factory.Get().SetUseIpcCommandBuffer();
153 }
154
150 void SynchronousCompositorImpl::DidInitializeRendererObjects( 155 void SynchronousCompositorImpl::DidInitializeRendererObjects(
151 SynchronousCompositorOutputSurface* output_surface, 156 SynchronousCompositorOutputSurface* output_surface,
152 SynchronousCompositorExternalBeginFrameSource* begin_frame_source, 157 SynchronousCompositorExternalBeginFrameSource* begin_frame_source,
153 cc::InputHandler* input_handler) { 158 cc::InputHandler* input_handler) {
154 DCHECK(!output_surface_); 159 DCHECK(!output_surface_);
155 DCHECK(!begin_frame_source_); 160 DCHECK(!begin_frame_source_);
156 DCHECK(output_surface); 161 DCHECK(output_surface);
157 DCHECK(begin_frame_source); 162 DCHECK(begin_frame_source);
158 DCHECK(compositor_client_); 163 DCHECK(compositor_client_);
159 DCHECK(input_handler); 164 DCHECK(input_handler);
(...skipping 247 matching lines...) Expand 10 before | Expand all | Expand 10 after
407 g_factory.Get(); // Ensure it's initialized. 412 g_factory.Get(); // Ensure it's initialized.
408 SynchronousCompositorImpl::CreateForWebContents(contents); 413 SynchronousCompositorImpl::CreateForWebContents(contents);
409 } 414 }
410 SynchronousCompositorImpl* instance = 415 SynchronousCompositorImpl* instance =
411 SynchronousCompositorImpl::FromWebContents(contents); 416 SynchronousCompositorImpl::FromWebContents(contents);
412 DCHECK(instance); 417 DCHECK(instance);
413 instance->SetClient(client); 418 instance->SetClient(client);
414 } 419 }
415 420
416 } // namespace content 421 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698