Closed Bug 1551092 Opened 5 years ago Closed 3 years ago

movementX in pointerlock reports bad value on Wayland

Categories

(Core :: Widget: Gtk, defect, P3)

66 Branch
defect

Tracking

()

RESOLVED DUPLICATE of bug 1580595

People

(Reporter: cte, Unassigned)

References

(Blocks 1 open bug)

Details

User Agent: Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:66.0) Gecko/20100101 Firefox/66.0

Steps to reproduce:

requestPointerLock on a canvas in Firefox on Wayland. (Fedora 30, Gnome 3.32)

Apparently the problem only affects Firefox on Wayland. I haven't tried Firefox on X. But Firefox in Windows 10 works as expected.

Actual results:

Values reported by movementX and movementY are actually screenX and screenY values respectively.

Expected results:

movementX and movementY values are supposed to report deltavalues (mousemoveEvent.current - mousemoveEvent.previous).

Component: Untriaged → Widget: Gtk
Product: Firefox → Core
Blocks: wayland
Priority: -- → P3

This bug is STILL an issue and causes big problems with web based FPS games (I was trying to develop one, and have spent the last 2 days debugging, only to find out it's a browser issue).

Mozilla, plz fix

Can you please piece of code which uses it? is that event.movementX ?

Here is an example https://codepen.io/timohausmann/pen/GRZBvRq

Before clicking on pointer lock I get relative values (e.g. 10, -20)

After getting pointer lock I get absolute values (e.g. 710, 690)

Status: UNCONFIRMED → RESOLVED
Closed: 3 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.