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

Unified Diff: content/browser/renderer_host/input/web_input_event_builders_win.cc

Issue 2016383002: Set PointerType of pointer event on Windows. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2743
Patch Set: Created 4 years, 7 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
Index: content/browser/renderer_host/input/web_input_event_builders_win.cc
diff --git a/content/browser/renderer_host/input/web_input_event_builders_win.cc b/content/browser/renderer_host/input/web_input_event_builders_win.cc
index 253efa8cda99bc5b54b34b334902959f178b8df3..aa85ebf41f7525bf742b316a865a8a8a70c69db2 100644
--- a/content/browser/renderer_host/input/web_input_event_builders_win.cc
+++ b/content/browser/renderer_host/input/web_input_event_builders_win.cc
@@ -90,11 +90,13 @@ static LPARAM GetRelativeCursorPos(HWND hwnd) {
return MAKELPARAM(pos.x, pos.y);
}
-WebMouseEvent WebMouseEventBuilder::Build(HWND hwnd,
- UINT message,
- WPARAM wparam,
- LPARAM lparam,
- double time_stamp) {
+WebMouseEvent WebMouseEventBuilder::Build(
+ HWND hwnd,
+ UINT message,
+ WPARAM wparam,
+ LPARAM lparam,
+ double time_stamp,
+ blink::WebPointerProperties::PointerType pointer_type) {
WebMouseEvent result;
switch (message) {
@@ -151,6 +153,7 @@ WebMouseEvent WebMouseEventBuilder::Build(HWND hwnd,
}
result.timeStampSeconds = time_stamp;
+ result.pointerType = pointer_type;
// set position fields:
@@ -225,11 +228,13 @@ WebMouseEvent WebMouseEventBuilder::Build(HWND hwnd,
// WebMouseWheelEvent ---------------------------------------------------------
-WebMouseWheelEvent WebMouseWheelEventBuilder::Build(HWND hwnd,
- UINT message,
- WPARAM wparam,
- LPARAM lparam,
- double time_stamp) {
+WebMouseWheelEvent WebMouseWheelEventBuilder::Build(
+ HWND hwnd,
+ UINT message,
+ WPARAM wparam,
+ LPARAM lparam,
+ double time_stamp,
+ blink::WebPointerProperties::PointerType pointer_type) {
WebMouseWheelEvent result;
result.type = WebInputEvent::MouseWheel;
@@ -238,6 +243,8 @@ WebMouseWheelEvent WebMouseWheelEventBuilder::Build(HWND hwnd,
result.button = WebMouseEvent::ButtonNone;
+ result.pointerType = pointer_type;
+
// Get key state, coordinates, and wheel delta from event.
UINT key_state;
float wheel_delta;

Powered by Google App Engine
This is Rietveld 408576698