Re: [pointerevents] Specify that "click", "dblclick" and "contextmenu" events are PointerEvents

Moving `pointerType` up to `MouseEvent` would work for me.  But I 
assumed that would be contentious / difficult since we'd have to move 
the definitions of different pointing devices up (perhaps evoking IP 
concerns around talking about touch screens in the WPWG).  But perhaps
 it's no worse than trying to update specs to change the type of 
`click` and ultimately more useful?

Note that there'd be some compat risk with moving `pointerType` - eg. 
sites doing "feature detection" incorrectly as 
`event.hasOwnProperty('pointerType')` (I've seen this pattern cause 
real compat problems in other examples when we've moved a property up 
the prototype chain).

Alternately we could add a `pointerType` to 
[InputDeviceCapabilities](https://wicg.github.io/InputDeviceCapabilities/)
 which just references the `PointerEvents` spec for the definition.  
I.e. the capability is "fires pointer events with the given 
pointerType value, or empty string if it doesn't fire pointer events 
at all".

But in general shipping code trumps spec purity.  If we're going to 
try to convince Edge to change to something else we should have a 
compelling argument of why that's better for more than just spec 
authors ;-).  Perhaps it's useful to have the `pointerType` on all 
`MouseEvent` instances, not just `click` etc?

-- 
GitHub Notification of comment by RByers
Please view or discuss this issue at 
https://github.com/w3c/pointerevents/issues/100#issuecomment-271308495
 using your GitHub account

Received on Monday, 9 January 2017 15:11:46 UTC