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

Unified Diff: samples/ui_lib/touch/Scroller.dart

Issue 10969073: Fixing up WheelEvent to follow W3C standards and work on all platforms. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Incorporating review feedback Created 8 years, 3 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 | « lib/html/templates/html/interface/interface_WheelEvent.darttemplate ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: samples/ui_lib/touch/Scroller.dart
diff --git a/samples/ui_lib/touch/Scroller.dart b/samples/ui_lib/touch/Scroller.dart
index 54304cb26fd2fb5ced07973737bfcd08c621b075..64210e9ce6f8e0f2716f089f819d221e041aacfc 100644
--- a/samples/ui_lib/touch/Scroller.dart
+++ b/samples/ui_lib/touch/Scroller.dart
@@ -161,10 +161,10 @@ class Scroller implements Draggable, MomentumDelegate {
_touchHandler.enable(capture);
_frame.on.mouseWheel.add((e) {
- if (e.wheelDeltaY != 0 && verticalEnabled ||
- e.wheelDeltaX != 0 && horizontalEnabled) {
- num x = horizontalEnabled ? e.wheelDeltaX : 0;
- num y = verticalEnabled ? e.wheelDeltaY : 0;
+ if (e.deltaY != 0 && verticalEnabled ||
+ e.deltaX != 0 && horizontalEnabled) {
+ num x = horizontalEnabled ? e.deltaX : 0;
+ num y = verticalEnabled ? e.deltaY : 0;
throwDelta(x, y, FAST_SNAP_DECELERATION_FACTOR);
e.preventDefault();
}
« no previous file with comments | « lib/html/templates/html/interface/interface_WheelEvent.darttemplate ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698