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

Side by Side Diff: content/browser/android/synchronous_compositor_base.cc

Issue 1620053002: sync compositor: Merge input path with chrome (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: tests Created 4 years, 9 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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/synchronous_compositor_base.h" 5 #include "content/browser/android/synchronous_compositor_base.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/supports_user_data.h" 8 #include "base/supports_user_data.h"
9 #include "content/browser/android/in_process/synchronous_compositor_factory_impl .h" 9 #include "content/browser/android/in_process/synchronous_compositor_factory_impl .h"
10 #include "content/browser/android/in_process/synchronous_compositor_impl.h" 10 #include "content/browser/android/in_process/synchronous_compositor_impl.h"
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 RenderWidgetHostViewAndroid* rwhva, 56 RenderWidgetHostViewAndroid* rwhva,
57 WebContents* web_contents) { 57 WebContents* web_contents) {
58 DCHECK(web_contents); 58 DCHECK(web_contents);
59 WebContentsAndroid* web_contents_android = 59 WebContentsAndroid* web_contents_android =
60 static_cast<WebContentsImpl*>(web_contents)->GetWebContentsAndroid(); 60 static_cast<WebContentsImpl*>(web_contents)->GetWebContentsAndroid();
61 if (!web_contents_android->synchronous_compositor_client()) 61 if (!web_contents_android->synchronous_compositor_client())
62 return nullptr; // Not using sync compositing. 62 return nullptr; // Not using sync compositing.
63 63
64 base::CommandLine* command_line = base::CommandLine::ForCurrentProcess(); 64 base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
65 if (command_line->HasSwitch(switches::kIPCSyncCompositing)) { 65 if (command_line->HasSwitch(switches::kIPCSyncCompositing)) {
66 bool async_input =
67 command_line->HasSwitch(switches::kAsyncInputForSyncCompositor);
66 bool use_in_proc_software_draw = 68 bool use_in_proc_software_draw =
67 command_line->HasSwitch(switches::kSingleProcess); 69 command_line->HasSwitch(switches::kSingleProcess);
68 return make_scoped_ptr(new SynchronousCompositorHost( 70 return make_scoped_ptr(new SynchronousCompositorHost(
69 rwhva, web_contents_android->synchronous_compositor_client(), 71 rwhva, web_contents_android->synchronous_compositor_client(),
70 use_in_proc_software_draw)); 72 async_input, use_in_proc_software_draw));
71 } 73 }
72 return make_scoped_ptr(new SynchronousCompositorImpl( 74 return make_scoped_ptr(new SynchronousCompositorImpl(
73 rwhva, web_contents_android->synchronous_compositor_client())); 75 rwhva, web_contents_android->synchronous_compositor_client()));
74 } 76 }
75 77
76 } // namespace content 78 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698