Skip to content

Conversation

@clopez
Copy link

@clopez clopez commented Dec 16, 2014

Even if a device has touch capabilities (most modern laptops have) the user can still be using the device with a mouse. So install the mouse handler events also for touch-capable devices.

More info: https://hacks.mozilla.org/2013/04/detecting-touch-its-the-why-not-the-how/

@cesutherland
Copy link
Member

@clopez thanks for the reference! This relates to #271 and several other issues.

The issue is, for all touch devices, having both sets of event handlers will trigger the handlers multiple times (per single event). The reference you suggest mentions e.preventDefault to stop propagation of the synthetic click events. Do you know if this actually works? And if it also works for the mouse events?

I don't have a touch + mouse device, but it might be possible for me to debug this myself using chrome's simulated touch events.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants