Index: public/web/WebInputEvent.h |
diff --git a/public/web/WebInputEvent.h b/public/web/WebInputEvent.h |
index b5d0a8bc6052b1f56fabe2537e52a02a86eb92b8..5093259a41f79fa3b9f48d25b5154db11cae3fda 100644 |
--- a/public/web/WebInputEvent.h |
+++ b/public/web/WebInputEvent.h |
@@ -34,6 +34,8 @@ |
#include "../platform/WebCommon.h" |
#include "../platform/WebGestureDevice.h" |
#include "../platform/WebRect.h" |
+#include "WebMouseProperties.h" |
+#include "WebPointerProperties.h" |
#include "WebTouchPoint.h" |
#include <string.h> |
@@ -300,16 +302,8 @@ public: |
// WebMouseEvent -------------------------------------------------------------- |
-class WebMouseEvent : public WebInputEvent { |
+class WebMouseEvent : public WebInputEvent, public WebMouseProperties { |
public: |
- enum Button { |
- ButtonNone = -1, |
- ButtonLeft, |
- ButtonMiddle, |
- ButtonRight |
- }; |
- |
- Button button; |
int x; |
int y; |
int windowX; |
@@ -322,7 +316,7 @@ public: |
WebMouseEvent() |
: WebInputEvent(sizeof(WebMouseEvent)) |
- , button(ButtonNone) |
+ , WebMouseProperties() |
, x(0) |
, y(0) |
, windowX(0) |
@@ -338,7 +332,7 @@ public: |
protected: |
explicit WebMouseEvent(unsigned sizeParam) |
: WebInputEvent(sizeParam) |
- , button(ButtonNone) |
+ , WebMouseProperties() |
, x(0) |
, y(0) |
, windowX(0) |
@@ -425,6 +419,17 @@ public: |
} |
}; |
+// WebPointerEvent ------------------------------------------------------------ |
+ |
+class WebPointerEvent : public WebMouseEvent, public WebPointerProperties { |
Rick Byers
2015/07/06 17:22:38
Let's hold off adding WebPointerEvent until we hav
USE eero AT chromium.org
2015/07/07 10:00:55
Done.
|
+public: |
+ WebPointerEvent() |
+ : WebMouseEvent(sizeof(WebPointerEvent)) |
+ , WebPointerProperties() |
+ { |
+ } |
+}; |
+ |
// WebGestureEvent -------------------------------------------------------------- |
class WebGestureEvent : public WebInputEvent { |
@@ -522,6 +527,7 @@ public: |
// WebTouchEvent -------------------------------------------------------------- |
+// TODO(e_hakkinen): Replace with WebPointerEvent. |
class WebTouchEvent : public WebInputEvent { |
public: |
// Maximum number of simultaneous touches supported on |