Index: public/web/WebInputEvent.h |
diff --git a/public/web/WebInputEvent.h b/public/web/WebInputEvent.h |
index a21e26705b7e3b47fe8f4e50d5a4a3b589a450b8..058300bf7a27bc49809e40095da7ca0b77589c38 100644 |
--- a/public/web/WebInputEvent.h |
+++ b/public/web/WebInputEvent.h |
@@ -343,6 +343,15 @@ protected: |
class WebMouseWheelEvent : public WebMouseEvent { |
public: |
+ // The rail mode for a wheel event specifies the axis on which scrolling is |
+ // expected to stick. If this axis is set to Free, then scrolling is not |
+ // stuck to any axis. |
+ enum RailMode { |
Rick Byers
2015/03/18 23:30:58
We'll want to use this from WebGestureEvent too I
ccameron
2015/03/19 00:05:10
Good point -- done. Did this to the platform event
|
+ RailModeFree = 0, |
+ RailModeHorizontal = 1 << 0, |
Rick Byers
2015/03/18 23:30:58
these don't need to be flags, right? I.e. it's no
ccameron
2015/03/19 00:05:10
The same is true of Phase, so I was guessing this
|
+ RailModeVertical = 1 << 1, |
+ }; |
+ |
enum Phase { |
PhaseNone = 0, |
PhaseBegan = 1 << 0, |
@@ -390,6 +399,8 @@ public: |
// instead of scroll. |
bool canScroll; |
+ RailMode railMode; |
+ |
WebMouseWheelEvent() |
: WebMouseEvent(sizeof(WebMouseWheelEvent)) |
, deltaX(0.0f) |
@@ -405,6 +416,7 @@ public: |
, scrollByPage(false) |
, hasPreciseScrollingDeltas(false) |
, canScroll(true) |
+ , railMode(RailModeFree) |
{ |
} |
}; |