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

Side by Side Diff: content/browser/renderer_host/input/input_router_config_helper.cc

Issue 1405613002: Support vsync-aligned wheel event dispatch (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@input_cleanup_todo
Patch Set: Rebase 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 | « no previous file | content/browser/renderer_host/input/input_router_impl.h » ('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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/renderer_host/input/input_router_config_helper.h" 5 #include "content/browser/renderer_host/input/input_router_config_helper.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "cc/base/switches.h"
8 #include "content/public/common/content_switches.h" 9 #include "content/public/common/content_switches.h"
9 #include "ui/events/gesture_detection/gesture_configuration.h" 10 #include "ui/events/gesture_detection/gesture_configuration.h"
10 #include "ui/events/gesture_detection/gesture_detector.h" 11 #include "ui/events/gesture_detection/gesture_detector.h"
11 12
12 namespace content { 13 namespace content {
13 namespace { 14 namespace {
14 15
15 // Default time allowance for the touch ack delay before the touch sequence is 16 // Default time allowance for the touch ack delay before the touch sequence is
16 // cancelled, depending on whether the site has a mobile-friendly viewport. 17 // cancelled, depending on whether the site has a mobile-friendly viewport.
17 // Note that these constants are effective only when the timeout is supported. 18 // Note that these constants are effective only when the timeout is supported.
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 64
64 return config; 65 return config;
65 } 66 }
66 67
67 } // namespace 68 } // namespace
68 69
69 InputRouterImpl::Config GetInputRouterConfigForPlatform() { 70 InputRouterImpl::Config GetInputRouterConfigForPlatform() {
70 InputRouterImpl::Config config; 71 InputRouterImpl::Config config;
71 config.gesture_config = GetGestureEventQueueConfig(); 72 config.gesture_config = GetGestureEventQueueConfig();
72 config.touch_config = GetTouchEventQueueConfig(); 73 config.touch_config = GetTouchEventQueueConfig();
74 #if !defined(OS_ANDROID)
75 config.buffer_wheel_events_until_flush =
76 base::CommandLine::ForCurrentProcess()->HasSwitch(
77 cc::switches::kEnableBeginFrameScheduling);
78 #else
79 config.buffer_wheel_events_until_flush = false;
80 #endif
73 return config; 81 return config;
74 } 82 }
75 83
76 } // namespace content 84 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/browser/renderer_host/input/input_router_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698