-
Notifications
You must be signed in to change notification settings - Fork 1.2k
X11: Mouse motion events sometimes contain garbage #3500
Copy link
Copy link
Closed
Labels
DS - x11Affects the X11 backend, or generally free Unix platformsAffects the X11 backend, or generally free Unix platforms
Description
While printing out events on X11, I noticed that sometimes (not always), the motion events are invalid:
DeviceEvent { device_id: DeviceId(X(DeviceId(2))), event: Motion { axis: 0, value: -1.0 } }
DeviceEvent { device_id: DeviceId(X(DeviceId(2))), event: Motion { axis: 1, value: 7.1e-322 } }
DeviceEvent { device_id: DeviceId(X(DeviceId(2))), event: MouseMotion { delta: (-1.0, 7.1e-322) } }
Only one axis gets reported and the second axis is just an unrelated value (most likely smth not belonging to the event).
for i in 0..xev.valuators.mask_len * 8 {
if !xinput2::XIMaskIsSet(mask, i) {
continue;
}
let x = unsafe { *value };
The easiest way I found to reproduce this is just moving the cursor between two monitors. It might also just be a x11 problem.
I'm running natively latest Arch Linux with Gnome using X11.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
DS - x11Affects the X11 backend, or generally free Unix platformsAffects the X11 backend, or generally free Unix platforms