-
Bug
-
Resolution: Fixed
-
P4
-
jfx21
-
None
-
b07
-
linux
When running a JavaFX application (like the attached one) with just a pannable ScrollPane on an embedded device (Linux-aarch64) with a touch enabled display, users can scroll the content just by dragging their finger on the touch screen. This works fine on X11, but fails on Wayland:
With X11, after MOUSE_PRESSED, MOUSE_DRAGGED events are fired repeatedly while the user moves their finger on the screen, and scrolling works as expected:
Event: MOUSE_PRESSED
Event: MOUSE_DRAGGED
Event: MOUSE_DRAGGED
...
Event: MOUSE_DRAGGED
Event: MOUSE_RELEASED
With Wayland, however, after MOUSE_PRESSED, dragging starts, there is one MOUSE_DRAGGED event, and the view shifts slightly, but immediately stops scrolling and a MOUSE_RELEASED event is fired, even with the finger still pressing the display:
Event: MOUSE_PRESSED
Event: MOUSE_DRAGGED
Event: MOUSE_RELEASED
Running with GDK_DEBUG=events shows:
Gdk-Message: 09:56:07.169: touch begin: window 4194306
touch id: 18
pointer emulating: true
Event: MOUSE_PRESSED
Gdk-Message: 09:56:07.216: touch update: window 4194306
touch id: 18
pointer emulating: true
Gdk-Message: 09:56:07.327: touch update: window 4194306
touch id: 18
pointer emulating: true
Gdk-Message: 09:56:07.329: touch update: window 4194306
touch id: 18
pointer emulating: true
...
Gdk-Message: 09:56:07.339: touch update: window 4194306
touch id: 18
pointer emulating: true
Event: MOUSE_DRAGGED
Gdk-Message: 09:56:07.363: touch end: window 4194306
touch id: 18
pointer emulating: true
Event: MOUSE_RELEASED
And running with GDK_DEBUG=nograbs "fixes" the issue, and scrolling works fine on Wayland as well.
With X11, after MOUSE_PRESSED, MOUSE_DRAGGED events are fired repeatedly while the user moves their finger on the screen, and scrolling works as expected:
Event: MOUSE_PRESSED
Event: MOUSE_DRAGGED
Event: MOUSE_DRAGGED
...
Event: MOUSE_DRAGGED
Event: MOUSE_RELEASED
With Wayland, however, after MOUSE_PRESSED, dragging starts, there is one MOUSE_DRAGGED event, and the view shifts slightly, but immediately stops scrolling and a MOUSE_RELEASED event is fired, even with the finger still pressing the display:
Event: MOUSE_PRESSED
Event: MOUSE_DRAGGED
Event: MOUSE_RELEASED
Running with GDK_DEBUG=events shows:
Gdk-Message: 09:56:07.169: touch begin: window 4194306
touch id: 18
pointer emulating: true
Event: MOUSE_PRESSED
Gdk-Message: 09:56:07.216: touch update: window 4194306
touch id: 18
pointer emulating: true
Gdk-Message: 09:56:07.327: touch update: window 4194306
touch id: 18
pointer emulating: true
Gdk-Message: 09:56:07.329: touch update: window 4194306
touch id: 18
pointer emulating: true
...
Gdk-Message: 09:56:07.339: touch update: window 4194306
touch id: 18
pointer emulating: true
Event: MOUSE_DRAGGED
Gdk-Message: 09:56:07.363: touch end: window 4194306
touch id: 18
pointer emulating: true
Event: MOUSE_RELEASED
And running with GDK_DEBUG=nograbs "fixes" the issue, and scrolling works fine on Wayland as well.
- blocks
-
JDK-8326710 ☂ JavaFX support for XWayland
- Open