src/js/hammer.js
function(event, data) {
        // we also want to trigger dom events
        if (this.options.domEvents) {
            triggerDomEvent(event, data);
        }

        // no handlers, so skip it all
        var handlers = this.handlers[event] && this.handlers[event].slice();
        if (!handlers || !handlers.length) {
            return;
        }

        data.type = event;
        data.preventDefault = function() {
            data.srcEvent.preventDefault();
        };

        var i = 0;
        while (i < handlers.length) {
            handlers[i](data);
            i++;
        }
    }
function(event, data) {
        // we also want to trigger dom events
        if (this.options.domEvents) {
            triggerDomEvent(event, data);
        }

        // no handlers, so skip it all
        var handlers = this.handlers[event] && this.handlers[event].slice();
        if (!handlers || !handlers.length) {
            return;
        }

        data.type = event;
        data.preventDefault = function() {
            data.srcEvent.preventDefault();
        };

        var i = 0;
        while (i < handlers.length) {
            handlers[i](data);
            i++;
        }
    }
function ( event , data ) { // we also want to trigger dom events if ( this . options . domEvents ) { triggerDomEvent ( event , data ) ; } // no handlers, so skip it all var handlers = this . handlers [ event ] && this . handlers [ event ] . slice ( ) ; if ( ! handlers || ! handlers . length ) { return ; } data . type = event ; data . preventDefault = function ( ) { data . srcEvent . preventDefault ( ) ; } ; var i = 0 ; while ( i < handlers . length ) { handlers [ i ] ( data ) ; i ++ ; } }
emit event to the listeners
@param {String} event
@param {Object} data
emit event to the listeners