wisemapping-frontend/libraries/jquery.touchevent.js
Paulo Gustavo Veiga c981276183 Fix typo.
2022-08-13 10:42:20 -07:00

15 lines
454 B
JavaScript

// Passive event listeners
function registerTouchHandler(jQuery) {
jQuery.event.special.touchstart = {
setup: function (_, ns, handle) {
this.addEventListener("touchstart", handle, { passive: true });
}
};
jQuery.event.special.touchmove = {
setup: function (_, ns, handle) {
this.addEventListener("touchmove", handle, { passive: true });
}
};
}
export default registerTouchHandler;