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

Issue 2925883003: [Touch Adjustment] Pass primary_pointer_type to WebGestureEvent and disable adjustment for stylus (Closed)

Created:
3 years, 6 months ago by chongz
Modified:
3 years, 5 months ago
CC:
blink-reviews, blink-reviews-api_chromium.org, chromium-reviews, dglazkov+blink, dtapuska+blinkwatch_chromium.org, dtapuska+chromiumwatch_chromium.org, kinuko+watch, Navid Zolghadr, platform-architecture-syd+reviews-web_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

[Touch Adjustment] Pass primary_pointer_type to WebGestureEvent and disable adjustment for stylus Event Flow: 1. MotionEvent.GetToolType() => 2. GestureEventDetails.primary_pointer_type_ => 3. WebGestureEvent.primary_pointer_type This CL is intended to fix stylus issue on ChromeOS devices. (e.g. Samsung Chromebook Plus) Background: 1. ChromeOS: Stylus generates touch events with large width&height. 2. Android: Stylus generates touch events with 0 width&height. 3. Windows: Stylus generates mouse events. Manually tested on Samsung Galaxy Note 5 and |primary_pointer_type| was passed successfully. BUG=731856 Review-Url: https://codereview.chromium.org/2925883003 Cr-Commit-Position: refs/heads/master@{#482892} Committed: https://chromium.googlesource.com/chromium/src/+/d65eacf7288645732c715f588fc3f5d4ae0e0d81

Patch Set 1 #

Total comments: 5

Patch Set 2 : Add layout test; Update comments; Remove ctor #

Total comments: 2

Patch Set 3 : dtapuska's comment: Add args check #

Total comments: 2

Patch Set 4 : dtapuska's comment: Fix layout test instead #

Total comments: 7

Patch Set 5 : Rebase #

Patch Set 6 : jochen and dtapuska's comments: Add default value #

Unified diffs Side-by-side diffs Delta from patch set Stats (+136 lines, -10 lines) Patch
M content/browser/renderer_host/render_widget_host_view_aura_unittest.cc View 1 2 3 4 1 chunk +30 lines, -0 lines 0 comments Download
M content/shell/test_runner/event_sender.cc View 1 2 3 4 5 5 chunks +6 lines, -4 lines 0 comments Download
M third_party/WebKit/LayoutTests/fast/events/touch/gesture/gesture-scrollbar.html View 1 2 3 2 chunks +2 lines, -2 lines 0 comments Download
M third_party/WebKit/LayoutTests/fast/events/touch/gesture/gesture-scrollbar-mainframe.html View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/LayoutTests/fast/events/touch/gesture/gesture-scrollbar-textarea.html View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
A third_party/WebKit/LayoutTests/touchadjustment/stylus-generated-gesture-tap.html View 1 1 chunk +27 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/input/EventHandler.cpp View 1 2 3 4 1 chunk +4 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/platform/exported/WebInputEvent.cpp View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/public/platform/WebGestureEvent.h View 1 2 3 4 5 1 chunk +4 lines, -0 lines 0 comments Download
M ui/events/blink/blink_event_util.cc View 1 2 3 4 3 chunks +23 lines, -1 line 0 comments Download
M ui/events/gesture_detection/gesture_event_data.h View 1 1 chunk +1 line, -0 lines 0 comments Download
M ui/events/gesture_detection/gesture_event_data.cc View 3 chunks +24 lines, -0 lines 0 comments Download
M ui/events/gesture_event_details.h View 1 2 3 4 5 2 chunks +11 lines, -0 lines 0 comments Download
M ui/events/gesture_event_details.cc View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 60 (36 generated)
chongz
dtapuska@ PTAL, thanks! denniskempin@ Can you take a look if this will on ChromeOS? Or ...
3 years, 6 months ago (2017-06-14 19:09:07 UTC) #16
mustaq
Do we need to cover conversions from non-MotionEvents? Like from ui::GestureEvent, as in RenderWidgetHostViewEventHandler::OnGestureEvent? Also ...
3 years, 6 months ago (2017-06-14 20:37:48 UTC) #18
mustaq
Do we need to cover conversions from non-MotionEvents? Like from ui::GestureEvent, as in RenderWidgetHostViewEventHandler::OnGestureEvent? Also ...
3 years, 6 months ago (2017-06-14 20:37:49 UTC) #19
dtapuska
On 2017/06/14 20:37:49, mustaq wrote: > Do we need to cover conversions from non-MotionEvents? Like ...
3 years, 6 months ago (2017-06-14 20:51:35 UTC) #20
chongz
On 2017/06/14 20:51:35, dtapuska wrote: > On 2017/06/14 20:37:49, mustaq wrote: > > Do we ...
3 years, 6 months ago (2017-06-14 23:53:23 UTC) #21
mustaq
> Do you mean we could get |ui::GestureEvent| without going through the > |GestureProvider::OnTouchEvent(const MotionEvent& ...
3 years, 6 months ago (2017-06-15 14:42:41 UTC) #22
dtapuska
https://codereview.chromium.org/2925883003/diff/40001/third_party/WebKit/public/platform/WebGestureEvent.h File third_party/WebKit/public/platform/WebGestureEvent.h (right): https://codereview.chromium.org/2925883003/diff/40001/third_party/WebKit/public/platform/WebGestureEvent.h#newcode43 third_party/WebKit/public/platform/WebGestureEvent.h:43: WebPointerProperties::PointerType primary_pointer_type; On 2017/06/14 23:53:23, chongz wrote: > On ...
3 years, 6 months ago (2017-06-15 14:47:24 UTC) #23
mustaq
On 2017/06/15 14:47:24, dtapuska wrote: > https://codereview.chromium.org/2925883003/diff/40001/third_party/WebKit/public/platform/WebGestureEvent.h > File third_party/WebKit/public/platform/WebGestureEvent.h (right): > > https://codereview.chromium.org/2925883003/diff/40001/third_party/WebKit/public/platform/WebGestureEvent.h#newcode43 > ...
3 years, 6 months ago (2017-06-15 14:53:28 UTC) #24
chongz
On 2017/06/15 14:42:41, mustaq wrote: > > Do you mean we could get |ui::GestureEvent| without ...
3 years, 6 months ago (2017-06-15 21:40:08 UTC) #27
dtapuska
https://codereview.chromium.org/2925883003/diff/60001/content/shell/test_runner/event_sender.cc File content/shell/test_runner/event_sender.cc (right): https://codereview.chromium.org/2925883003/diff/60001/content/shell/test_runner/event_sender.cc#newcode2528 content/shell/test_runner/event_sender.cc:2528: getPointerType(args, false, event.primary_pointer_type); You should probably check if there ...
3 years, 6 months ago (2017-06-16 14:49:35 UTC) #30
chongz
dtapuska@ PTAL again, thanks! https://codereview.chromium.org/2925883003/diff/60001/content/shell/test_runner/event_sender.cc File content/shell/test_runner/event_sender.cc (right): https://codereview.chromium.org/2925883003/diff/60001/content/shell/test_runner/event_sender.cc#newcode2528 content/shell/test_runner/event_sender.cc:2528: getPointerType(args, false, event.primary_pointer_type); On 2017/06/16 ...
3 years, 6 months ago (2017-06-16 15:34:00 UTC) #33
dtapuska
https://codereview.chromium.org/2925883003/diff/80001/content/shell/test_runner/event_sender.cc File content/shell/test_runner/event_sender.cc (right): https://codereview.chromium.org/2925883003/diff/80001/content/shell/test_runner/event_sender.cc#newcode2529 content/shell/test_runner/event_sender.cc:2529: if (!args->PeekNext().IsEmpty() && args->PeekNext()->IsString()) { Do you really need ...
3 years, 6 months ago (2017-06-16 15:46:24 UTC) #34
chongz
https://codereview.chromium.org/2925883003/diff/80001/content/shell/test_runner/event_sender.cc File content/shell/test_runner/event_sender.cc (right): https://codereview.chromium.org/2925883003/diff/80001/content/shell/test_runner/event_sender.cc#newcode2529 content/shell/test_runner/event_sender.cc:2529: if (!args->PeekNext().IsEmpty() && args->PeekNext()->IsString()) { On 2017/06/16 15:46:23, dtapuska ...
3 years, 6 months ago (2017-06-16 16:03:02 UTC) #37
chongz
dtapuska@ PTAL again, thanks! https://codereview.chromium.org/2925883003/diff/100001/content/shell/test_runner/event_sender.cc File content/shell/test_runner/event_sender.cc (right): https://codereview.chromium.org/2925883003/diff/100001/content/shell/test_runner/event_sender.cc#newcode2528 content/shell/test_runner/event_sender.cc:2528: if (!getPointerType(args, false, event.primary_pointer_type)) dtapuska@ ...
3 years, 6 months ago (2017-06-19 19:46:04 UTC) #40
dtapuska
On 2017/06/19 19:46:04, chongz wrote: > dtapuska@ PTAL again, thanks! > > https://codereview.chromium.org/2925883003/diff/100001/content/shell/test_runner/event_sender.cc > File ...
3 years, 6 months ago (2017-06-23 17:11:01 UTC) #41
dtapuska
https://codereview.chromium.org/2925883003/diff/100001/content/shell/test_runner/event_sender.cc File content/shell/test_runner/event_sender.cc (right): https://codereview.chromium.org/2925883003/diff/100001/content/shell/test_runner/event_sender.cc#newcode2528 content/shell/test_runner/event_sender.cc:2528: if (!getPointerType(args, false, event.primary_pointer_type)) On 2017/06/19 19:46:04, chongz wrote: ...
3 years, 6 months ago (2017-06-23 17:11:11 UTC) #42
dtapuska
https://codereview.chromium.org/2925883003/diff/100001/content/shell/test_runner/event_sender.cc File content/shell/test_runner/event_sender.cc (right): https://codereview.chromium.org/2925883003/diff/100001/content/shell/test_runner/event_sender.cc#newcode2528 content/shell/test_runner/event_sender.cc:2528: if (!getPointerType(args, false, event.primary_pointer_type)) On 2017/06/23 17:11:11, dtapuska wrote: ...
3 years, 6 months ago (2017-06-23 17:14:37 UTC) #43
chongz
sadrul@ PTAL at "ui/events/", thanks! https://codereview.chromium.org/2925883003/diff/100001/content/shell/test_runner/event_sender.cc File content/shell/test_runner/event_sender.cc (right): https://codereview.chromium.org/2925883003/diff/100001/content/shell/test_runner/event_sender.cc#newcode2528 content/shell/test_runner/event_sender.cc:2528: if (!getPointerType(args, false, event.primary_pointer_type)) ...
3 years, 6 months ago (2017-06-23 17:39:13 UTC) #45
sadrul
lgtm
3 years, 5 months ago (2017-06-26 21:57:44 UTC) #46
chongz
jochen@ PTAL at "content/" and "third_party/WebKit/", thanks!
3 years, 5 months ago (2017-06-26 22:12:05 UTC) #48
jochen (gone - plz use gerrit)
lgtm with comment addressed https://codereview.chromium.org/2925883003/diff/100001/third_party/WebKit/public/platform/WebGestureEvent.h File third_party/WebKit/public/platform/WebGestureEvent.h (right): https://codereview.chromium.org/2925883003/diff/100001/third_party/WebKit/public/platform/WebGestureEvent.h#newcode42 third_party/WebKit/public/platform/WebGestureEvent.h:42: WebPointerProperties::PointerType primary_pointer_type; can you assign ...
3 years, 5 months ago (2017-06-27 09:29:24 UTC) #49
chongz
https://codereview.chromium.org/2925883003/diff/100001/content/shell/test_runner/event_sender.cc File content/shell/test_runner/event_sender.cc (right): https://codereview.chromium.org/2925883003/diff/100001/content/shell/test_runner/event_sender.cc#newcode2528 content/shell/test_runner/event_sender.cc:2528: if (!getPointerType(args, false, event.primary_pointer_type)) On 2017/06/23 17:39:13, chongz wrote: ...
3 years, 5 months ago (2017-06-27 20:13:13 UTC) #52
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2925883003/140001
3 years, 5 months ago (2017-06-28 05:18:10 UTC) #57
commit-bot: I haz the power
3 years, 5 months ago (2017-06-28 05:22:16 UTC) #60
Message was sent while issue was closed.
Committed patchset #6 (id:140001) as
https://chromium.googlesource.com/chromium/src/+/d65eacf7288645732c715f588fc3...

Powered by Google App Engine
This is Rietveld 408576698