Re: [touch-events] Specify what browsers do on non-touch devices

I propose we mark the APIs historically used for mobile device detection as deprecated:
 - ontouch* members on window, document, Element
 - document.createTouch, document.createTouchList (already deprecated)
 - document.createEvent("TouchEvent")  (not mentioned by the spec at all today)

They should be supported only by mobile devices for legacy web compat reasons.  Sites wishing to do real cross-device TouchEvent feature detection should use `if (window.TouchEvent)`.  Chrome would then change to [consistently expose these APIs only on mobile and not desktop](https://bugs.chromium.org/p/chromium/issues/detail?id=392584), while otherwise fully supporting TouchEvents on all platforms in all situations (removing our error-prone hardware-detection-on-startup hack).

Thoughts?

-- 
GitHub Notification of comment by RByers
Please view or discuss this issue at https://github.com/w3c/touch-events/issues/64#issuecomment-327671775 using your GitHub account

Received on Thursday, 7 September 2017 03:13:20 UTC