src/js/common/util.js
function(ev) {
        var rightClick;

        ev = ev || window.event;

        if (ev.which) {
            rightClick = ev.which === 3;
        } else if (ev.button) {
            rightClick = ev.button === 2;
        }

        return rightClick;
    }
function(ev) {
        var rightClick;

        ev = ev || window.event;

        if (ev.which) {
            rightClick = ev.which === 3;
        } else if (ev.button) {
            rightClick = ev.button === 2;
        }

        return rightClick;
    }
function ( ev ) { var rightClick ; ev = ev || window . event ; if ( ev . which ) { rightClick = ev . which === 3 ; } else if ( ev . button ) { rightClick = ev . button === 2 ; } return rightClick ; }
Detect right button by mouse event
@param {object} ev - Mouse event
@returns {boolean} State
Detect right button by mouse event