RFR: 8320965: Scrolling on a touch enabled display fails on Wayland [v3]
Jose Pereda
jpereda at openjdk.org
Mon Feb 19 11:22:00 UTC 2024
On Mon, 19 Feb 2024 00:35:48 GMT, Thiago Milczarek Sayao <tsayao at openjdk.org> wrote:
>> Jose Pereda has updated the pull request incrementally with one additional commit since the last revision:
>>
>> Add compile-time checks to GdkSeat
>
> A shot in the dark since I don't own a touch enabled monitor:
>
> Test 1:
>
> Add `GDK_SCROLL_MASK` on the original `gdk_pointer_grab` function;
>
> Test 2:
>
> This PR uses `GDK_SEAT_CAPABILITY_ALL_POINTING` which includes the touch masks.
>
> So the equivalent would include `GDK_TOUCH_MASK` on `gdk_pointer_grab`.
>
>
> I would bet on option 2.
Thanks @tsayao, I can definitely test those suggestions.
If I get it right, you are proposing this change:
status = gdk_pointer_grab(gdkWindow, owner_events, (GdkEventMask)
(GDK_POINTER_MOTION_MASK
| GDK_POINTER_MOTION_HINT_MASK
+ | GDK_TOUCH_MASK // or GDK_SCROLL_MASK
| GDK_BUTTON_MOTION_MASK
| GDK_BUTTON1_MOTION_MASK
| GDK_BUTTON2_MOTION_MASK
| GDK_BUTTON3_MOTION_MASK
| GDK_BUTTON_PRESS_MASK
| GDK_BUTTON_RELEASE_MASK
NULL, cursor, GDK_CURRENT_TIME);
But I don't see how this would fix the issue of the failing test on Linux that happens also without a touch enabled display. I tried both, the test still fails (two out of 5 times or so). Also, this is called only if there is no gdk_seat_grab function (which happens before GTK 3.20).
However, if I use `GDK_SEAT_CAPABILITY_NONE` instead of `GDK_SEAT_CAPABILITY_ALL_POINTING`, it passes 10 out of 10, but that would cancel pointer/touch events, wouldn't it?
Is there any chance that the robot implementation (via XTest, that uses `XTestGrabControl`) might not work fine with the new seat_grab approach after GTK 3.20+?
-------------
PR Comment: https://git.openjdk.org/jfx/pull/1305#issuecomment-1952237235
More information about the openjfx-dev
mailing list