examples/common/touch-emulator.js
function hasTouchSupport() {
        return ("ontouchstart" in window) || // touch events
               (window.Modernizr && window.Modernizr.touch) || // modernizr
               (navigator.msMaxTouchPoints || navigator.maxTouchPoints) > 2; // pointer events
    }
function hasTouchSupport() {
        return ("ontouchstart" in window) || // touch events
               (window.Modernizr && window.Modernizr.touch) || // modernizr
               (navigator.msMaxTouchPoints || navigator.maxTouchPoints) > 2; // pointer events
    }
function hasTouchSupport ( ) { return ( "ontouchstart" in window ) || // touch events ( window . Modernizr && window . Modernizr . touch ) || // modernizr ( navigator . msMaxTouchPoints || navigator . maxTouchPoints ) > 2 ; // pointer events }
we don't have to emulate on a touch device
@returns {boolean}
we don t have to emulate on a touch device