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

Unified Diff: public/web/WebInputEvent.h

Issue 1212113007: Add WebPointerProperties type. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Comments, do not touch radiusX/Y, relocate WebPointerProperties.h Created 5 years, 5 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 | « public/platform/WebPointerProperties.h ('k') | public/web/WebTouchPoint.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: public/web/WebInputEvent.h
diff --git a/public/web/WebInputEvent.h b/public/web/WebInputEvent.h
index b5d0a8bc6052b1f56fabe2537e52a02a86eb92b8..f9fcb5497091c2bd46c3c38165184b800669eff1 100644
--- a/public/web/WebInputEvent.h
+++ b/public/web/WebInputEvent.h
@@ -33,6 +33,7 @@
#include "../platform/WebCommon.h"
#include "../platform/WebGestureDevice.h"
+#include "../platform/WebPointerProperties.h"
#include "../platform/WebRect.h"
#include "WebTouchPoint.h"
@@ -300,16 +301,8 @@ public:
// WebMouseEvent --------------------------------------------------------------
-class WebMouseEvent : public WebInputEvent {
+class WebMouseEvent : public WebInputEvent, public WebPointerProperties {
public:
- enum Button {
- ButtonNone = -1,
- ButtonLeft,
- ButtonMiddle,
- ButtonRight
- };
-
- Button button;
int x;
int y;
int windowX;
@@ -322,7 +315,7 @@ public:
WebMouseEvent()
: WebInputEvent(sizeof(WebMouseEvent))
- , button(ButtonNone)
+ , WebPointerProperties()
, x(0)
, y(0)
, windowX(0)
@@ -338,7 +331,7 @@ public:
protected:
explicit WebMouseEvent(unsigned sizeParam)
: WebInputEvent(sizeParam)
- , button(ButtonNone)
+ , WebPointerProperties()
, x(0)
, y(0)
, windowX(0)
@@ -522,6 +515,7 @@ public:
// WebTouchEvent --------------------------------------------------------------
+// TODO(e_hakkinen): Replace with WebPointerEvent. crbug.com/508283
class WebTouchEvent : public WebInputEvent {
public:
// Maximum number of simultaneous touches supported on
« no previous file with comments | « public/platform/WebPointerProperties.h ('k') | public/web/WebTouchPoint.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698