A javascript library for touch gestures .
Please check the demo on your tablet device .
- start,end
- tap,doubletap,longtap,hold
- flick,swipe
- pinch,rotate
var objTouch = document.getElementById('touch');//get object var Touches = JTouch(objTouch);//init JTouch Touches.on('start',function(){ console.log('start'); }).on('end',function(){ console.log('end'); });Touches.on('flick',function(evt,data){ console.log('flick'); switch(data['direction']){ case 'left' : Trans.next(); break; case 'right': Trans.prev(); break; } });
You can check it on your tablet device . (ipad,surface..)
http://liutian1937.github.io/JTouch/touch.htmlNeed translate.js album.js
http://liutian1937.github.io/JTouch/carousel.htmlNeed translate.js