diff options
author | davemoore@chromium.org <davemoore@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-05-28 23:35:17 +0000 |
---|---|---|
committer | davemoore@chromium.org <davemoore@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-05-28 23:35:17 +0000 |
commit | 353a34ce51417f032198c1c537af4180d8eb9af2 (patch) | |
tree | 87319602ae8b159050339b2a9a346efa057b4668 /chrome/renderer/render_widget.cc | |
parent | bf5d600f940afbc652b0fbc68de0dfb1ece03564 (diff) | |
download | chromium_src-353a34ce51417f032198c1c537af4180d8eb9af2.zip chromium_src-353a34ce51417f032198c1c537af4180d8eb9af2.tar.gz chromium_src-353a34ce51417f032198c1c537af4180d8eb9af2.tar.bz2 |
Enabled mousewheel coalescing to work better for ChromeOS.
This was important because the browser process couldn't keep up
with the input stream, resulting in poor 2 finger scroll
behavior. It's now tuned to the settings in cros.
BUG=NONE
TEST=NONE
Review URL: http://codereview.chromium.org/2239001
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@48541 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/renderer/render_widget.cc')
-rw-r--r-- | chrome/renderer/render_widget.cc | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/chrome/renderer/render_widget.cc b/chrome/renderer/render_widget.cc index ea801c4..e3d5390 100644 --- a/chrome/renderer/render_widget.cc +++ b/chrome/renderer/render_widget.cc @@ -328,10 +328,17 @@ void RenderWidget::OnHandleInputEvent(const IPC::Message& message) { response->WriteInt(input_event->type); response->WriteBool(processed); - if (input_event->type == WebInputEvent::MouseMove && + if ((input_event->type == WebInputEvent::MouseMove || + input_event->type == WebInputEvent::MouseWheel) && paint_aggregator_.HasPendingUpdate()) { // We want to rate limit the input events in this case, so we'll wait for // painting to finish before ACKing this message. + if (pending_input_event_ack_.get()) { + // As two different kinds of events could cause us to postpone an ack + // we send it now, if we have one pending. The Browser should never + // send us the same kind of event we are delaying the ack for. + Send(pending_input_event_ack_.release()); + } pending_input_event_ack_.reset(response); } else { Send(response); |