Re: [pointerevents] Incorrect movementX/Y in PointerEvents

I think it's a bug that `movementX`/Y is different between the compat 
mouse events and pointer events.  In general the whole reason 
`PointerEvent` derives from `MouseEvent` is that you want to be able 
to easily upgrade existing code designed for `MouseEvent` to use work 
with `PointerEvent`.  So we should file bugs against Chrome and Edge 
for this and write an WPT for it.

In terms of the larger interaction, conceptually PointerLock operates 
at a level of abstraction below the DOM events (closer to the OS / raw
 input).  So I don't think it would make sense for PointerLock to 
apply only to the compat mouse events.  So at a minimum PointerLock 
needs to apply to all `pointerType="mouse"` PointerEvents.

I'm pretty sure it doesn't make sense to try to apply PointerLock to 
`pointerType="touch"` or probably even to any pen scenarios.  It's 
designed for gaming scenarios where you want to hide the cursor and 
support infinite movement along an axis (relying on relative motion 
instead of absolute position).  This is really a mouse-specific 
concept.  Arguably we might want a 
`InputDeviceCapabilities.hasRelativeMotion` flag that only mice (and 
devices that emulate a mouse - trackpads, gamepad joysticks, etc.) 
set, but in practice `pointerType="mouse"` is probably adequate.  The 
PointerLock spec talks specifically and exclusively (AFAICT) about 
mouse devices, so I'm not sure any spec change is needed here.  
@scheib is the expert though. 

GitHub Notification of comment by RByers
Please view or discuss this issue at
 using your GitHub account

Received on Thursday, 25 August 2016 19:16:17 UTC