EightMedia/hammer.js — pull request #567 by tehnomaag (2014-06-12 15:31:22+00:00)
Title: Added middle and right button support.

By default Hammer only supported left-button mouse input.

Now this can be configured by passing in mouseButtons array to Hammer options object like so:

Hammer(element, {
// Left, mid and right buttons allowed
mouseButtons: [0,1,2]
});

PS: Handle and preventDefault the "contextmenu" event yourself for right-click dragging with Hammer to work properly in your document. Example:

document.documentElement.addEventListener("contextmenu", function (ev) { ev.preventDefault(); });