Closed damassi closed 10 years ago
Looks good. How was this manifesting itself? Were you seeing errors?
Yup, it was throwing errors whenever I would attempt to drag anything on my desktop, which delegated touch events to mouse via jQuery. I suspect it was some kind of bubbling race condition (which comes first, the touch or the click?) which only manifests itself in certain contexts but this effectively fixed it.
Sounds good, sir. Thanks for the PR!
np :)
This PR adds an additional check to check against the
touches
property in a native touch event, which may or may not exist if the user is creating or 'triggering' an artificial event. (The example being, when a dev wants to delegate mousedowns and mouseups to touchstart and touchend for sharing events across all platforms.)