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

Unified Diff: content/browser/android/content_view_core_impl.cc

Issue 178303003: Merge 251963 "[Android] Use DIP coordinates for GestureFlingStar..." (Closed) Base URL: svn://svn.chromium.org/chrome/branches/1847/src/
Patch Set: Created 6 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | webkit/child/fling_animator_impl_android.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/android/content_view_core_impl.cc
===================================================================
--- content/browser/android/content_view_core_impl.cc (revision 252975)
+++ content/browser/android/content_view_core_impl.cc (working copy)
@@ -1182,10 +1182,8 @@
WebGestureEvent event = MakeGestureEvent(
WebInputEvent::GestureFlingStart, time_ms, x, y);
- // Velocity should not be scaled by DIP since that interacts poorly with the
- // deceleration constants. The DIP scaling is done on the renderer.
- event.data.flingStart.velocityX = vx;
- event.data.flingStart.velocityY = vy;
+ event.data.flingStart.velocityX = vx / GetDpiScale();
+ event.data.flingStart.velocityY = vy / GetDpiScale();
SendGestureEvent(event);
}
« no previous file with comments | « no previous file | webkit/child/fling_animator_impl_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698