New issue
Advanced search Search tips

Issue 731914 link

Starred by 1 user

Issue metadata

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



Sign in to add a comment

Touchscreen overscroll navigation on Linux is jittery when the cursor is outside the window

Project Member Reported by mcnee@chromium.org, Jun 9 2017

Issue description

Chrome Version: 61.0.3121.0
OS: Linux

What steps will reproduce the problem?
(1) On linux, with a touchscreen, start an overscroll navigation with the cursor positioned off of the window (the touchscreen input will need to be floating)
(2) Observe that a spurious mouse-move reaches the overscroll controller causing it to reset the overscroll

This results in the overscroll being jittery/unresponsive.

The mouse-move is created here: https://cs.chromium.org/chromium/src/ui/views/widget/desktop_aura/desktop_window_tree_host_x11.cc?l=1920
The original XEvent is an EnterNotify with mode NotifyGrab.
 

Comment 1 by mcnee@chromium.org, Jun 9 2017

Cc: osh...@chromium.org sadrul@chromium.org
Status: Started (was: Assigned)
cc'ing sadrul and oshima for comment, as you've introduced related logic in https://codereview.chromium.org/11411059 and https://codereview.chromium.org/22264002

I notice that synthetic mouse-moves are dropped during an overscroll gesture: https://cs.chromium.org/chromium/src/content/browser/renderer_host/render_widget_host_view_event_handler.cc?l=315
and that there are several places where mouse-moves created from EnterNotify XEvents are marked as synthesized
https://cs.chromium.org/chromium/src/ui/aura/window_tree_host_x11.cc?l=255
https://cs.chromium.org/chromium/src/ui/platform_window/x11/x11_window.cc?l=90
https://cs.chromium.org/chromium/src/ui/events/platform/x11/x11_event_source_libevent.cc?l=90

Marking this EnterNotify mouse-move as synthesized as well fixes this. Does this seem like a reasonable fix?
Project Member

Comment 2 by bugdroid1@chromium.org, Jul 5 2017

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

commit 08381b6e5c3fc97d80e116f770d4fe0f1c06e0e5
Author: mcnee <mcnee@chromium.org>
Date: Wed Jul 05 15:23:12 2017

Mark the ET_MOUSE_MOVED created from a pointer grab as synthesized.

When the mouse pointer is outside of the window and an overscroll
navigation is started with a touchscreen, an ET_MOUSE_MOVED event
is created from the EnterNotify XEvent in
DesktopWindowTreeHostX11::DispatchEvent. This is not marked as
synthesized, so it interferes with the overscroll gesture.

ET_MOUSE_MOVED events created from an EnterNotify are marked as
synthesized elsewhere, so we move this logic into
EventFlagsFromXEvent, so the events are consistently marked as
synthesized.

BUG= 731914 

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

[modify] https://crrev.com/08381b6e5c3fc97d80e116f770d4fe0f1c06e0e5/content/browser/renderer_host/render_widget_host_view_event_handler.cc
[modify] https://crrev.com/08381b6e5c3fc97d80e116f770d4fe0f1c06e0e5/content/browser/web_contents/web_contents_view_aura_browsertest.cc
[modify] https://crrev.com/08381b6e5c3fc97d80e116f770d4fe0f1c06e0e5/ui/aura/env_input_state_controller.cc
[modify] https://crrev.com/08381b6e5c3fc97d80e116f770d4fe0f1c06e0e5/ui/aura/window_tree_host_x11.cc
[modify] https://crrev.com/08381b6e5c3fc97d80e116f770d4fe0f1c06e0e5/ui/events/platform/x11/x11_event_source_libevent.cc
[modify] https://crrev.com/08381b6e5c3fc97d80e116f770d4fe0f1c06e0e5/ui/events/x/events_x_unittest.cc
[modify] https://crrev.com/08381b6e5c3fc97d80e116f770d4fe0f1c06e0e5/ui/events/x/events_x_utils.cc
[modify] https://crrev.com/08381b6e5c3fc97d80e116f770d4fe0f1c06e0e5/ui/platform_window/x11/x11_window.cc

Comment 3 by mcnee@chromium.org, Jul 10 2017

Status: Fixed (was: Started)
Project Member

Comment 4 by bugdroid1@chromium.org, Jul 10 2017

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

commit d61b0c9cbd9b6a34d58e02b5aa878dd16af9e0b1
Author: Kevin McNee <mcnee@chromium.org>
Date: Mon Jul 10 19:28:26 2017

Re-enable WebContentsViewAuraTest.QuickOverscrollDirectionChange on linux.

This test was affected by  crbug.com/731914  . Now that this has been
fixed, the test passes.

In the original bug filed when this was disabled ( crbug.com/440043 ),
the problem was that it was timing out. There do not appear to be any
timing issues now.

Bug: 440043,  731914 
Change-Id: I864952b1d9a2e3f95677badd8b699f8c0b641067
Reviewed-on: https://chromium-review.googlesource.com/563978
Reviewed-by: Sadrul Chowdhury <sadrul@chromium.org>
Commit-Queue: Kevin McNee <mcnee@chromium.org>
Cr-Commit-Position: refs/heads/master@{#485345}
[modify] https://crrev.com/d61b0c9cbd9b6a34d58e02b5aa878dd16af9e0b1/content/browser/web_contents/web_contents_view_aura_browsertest.cc

Sign in to add a comment