* This can't be tested as of yet (no mouse/event simulation in unittest.js)
* This is both a defect (isLeftClick) and an enhancement (isRight|MiddleClick)
Event.isLeftClick currently does:
return (((event.which) && (event.which == 1)) ||
((event.button) && (event.button == 1)));
This works on non-IE browsers because they do support which as a compatibility standpoint, it seems (I checked on Gecko-based browsers). But the W3C spec for button goes from 0 to 2, not from 1 to 3, with 0 being "left."
So the attached patch fixes this (all existings tests pass properly, of course), and adds, for the hell of it, isMiddleClick and isRightClick.