var touchmoved;
$('button').on('touchend', function(e){
if(touchmoved != true){
// button click action
}
}).on('touchmove', function(e){
touchmoved = true;
}).on('touchstart', function(){
touchmoved = false;
});
More Related Contents:
- How to disable scrolling temporarily?
- Smooth scrolling when clicking an anchor link
- What’s the best way to detect a ‘touch screen’ device using JavaScript?
- Scroll Automatically to the Bottom of the Page
- How to scroll an HTML page to a given anchor
- Prevent scrolling of parent element when inner element scroll position reaches top/bottom?
- Event when user stops scrolling
- Prevent BODY from scrolling when a modal is opened
- Keep overflow div scrolled to bottom unless user scrolls up
- How to scroll to specific item using jQuery?
- Binding multiple events to a listener (without JQuery)?
- Javascript Drag and drop for touch devices [closed]
- event.wheelDelta returns undefined
- Scroll smoothly to specific element on page
- prevent Scroll bubbling from element to window
- How to do a horizontal scroll on mouse wheel scroll?
- How to scroll the window using JQuery $.scrollTo() function
- Fade In on Scroll Down, Fade Out on Scroll Up – based on element position in window
- Stop fixed position at footer
- javascript: detect scroll end
- jQuery on ‘double click’ event (dblclick for mobile)
- jQuery live scroll event on mobile (work around)
- Javascript: do an action after user is done scrolling
- How to determine scroll direction without actually scrolling
- ScrollTo function in AngularJS
- jQuery – bind event on Scroll Stop
- Choppy/Laggy scroll event on Chrome and IE
- Load ajax when scroll reaches 80%
- Automatically scroll down chat div
- How to determine if the client is a touch device [duplicate]