
$.fn.extend({
"rightclick": function (fn) {
$(this).mousedown(function (e) {
if (e.which === 3) {
$(this).bind("contextmenu", function (e) {
return false;
});
fn(e);
}
});
return this;
});