New issue
Advanced search Search tips

Issue 627207 link

Starred by 3 users

Issue metadata

Status: Fixed
Owner:
Closed: Jul 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 2
Type: Bug



Sign in to add a comment

Long-press sends two sequences of pointer events

Project Member Reported by mustaq@chromium.org, Jul 11 2016

Issue description

Steps:
0. Take a touch device, or enable touch-emulation.
1. Enable PointerEvent through chrome://flags/#enable-pointer-events.
2. Go to http://rbyers.github.io/eventTest.html, enable PE output.
3. Long-tap on the page.

Expected output:
A single sequence of pointerover, pointerenter, pointerdown events, all with pointerType=touch

Actual outout:
Two sequences of pointerover, pointerenter, pointerdown events one after another, the first sequence with pointerType=touch & the second one with pointerType=mouse

Looks like the call to handleMousePressEvent(PlatformMouseEvent&) from EventHandler::handleGestureLongPress is causing the second sequence to fire.

 

Comment 1 by mustaq@chromium.org, Jul 18 2016

Cc: mustaq@chromium.org
 Issue 622418  has been merged into this issue.
Project Member

Comment 2 by bugdroid1@chromium.org, Jul 20 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/326934c3dd341e43ecaa2c05fbf7597f7c21764d

commit 326934c3dd341e43ecaa2c05fbf7597f7c21764d
Author: mustaq <mustaq@chromium.org>
Date: Wed Jul 20 20:17:01 2016

PointerEvents for long-press: fix double firing & canceling MEs

This CL fixes two bugs related to PointerEvents and gesture long
presses:

A. We fire pointer events from touch events. Gesture long-press
handler was calling handleMousePressEvent, which caused firing
of additional pointer events for the same touch sequence. This
CL skips firing PEs from PlatformMouseEvents synthesized from
touch.

B. Canceling a pointerdown should suppress all following
MouseEvents, including those fires through touch-gestures. We
have fixed the GestureTap case before. This CL fixes the only
remaining ME case: MEs from gesture long-press.

BUG= 627207 , 606938 

Review-Url: https://codereview.chromium.org/2141993003
Cr-Commit-Position: refs/heads/master@{#406649}

[modify] https://crrev.com/326934c3dd341e43ecaa2c05fbf7597f7c21764d/third_party/WebKit/LayoutTests/fast/events/pointerevents/mouse-pointer-chorded-buttons.html
[add] https://crrev.com/326934c3dd341e43ecaa2c05fbf7597f7c21764d/third_party/WebKit/LayoutTests/fast/events/pointerevents/touch-pointer-long-press.html
[modify] https://crrev.com/326934c3dd341e43ecaa2c05fbf7597f7c21764d/third_party/WebKit/LayoutTests/fast/events/pointerevents/touch-pointer-mouse-expected.txt
[modify] https://crrev.com/326934c3dd341e43ecaa2c05fbf7597f7c21764d/third_party/WebKit/LayoutTests/fast/events/pointerevents/touch-pointer-mouse.html
[modify] https://crrev.com/326934c3dd341e43ecaa2c05fbf7597f7c21764d/third_party/WebKit/Source/core/input/EventHandler.cpp
[modify] https://crrev.com/326934c3dd341e43ecaa2c05fbf7597f7c21764d/third_party/WebKit/Source/core/input/EventHandler.h
[modify] https://crrev.com/326934c3dd341e43ecaa2c05fbf7597f7c21764d/third_party/WebKit/Source/core/input/GestureManager.cpp
[modify] https://crrev.com/326934c3dd341e43ecaa2c05fbf7597f7c21764d/third_party/WebKit/Source/core/input/GestureManager.h

Comment 3 by mustaq@chromium.org, Jul 20 2016

Status: Fixed (was: Assigned)

Sign in to add a comment