ivaynberg/select2 — pull request #262 by nzgeek (2012-07-25 03:28:16+00:00)
Title: Possible fix for #259

I've added code to spoof a `click()` event after the existing `change()` event. The event data doesn't contain any mouse position information, but it does indicate that the left mouse button was used while clicking.

My reason for adding the `button` and `which` attributes was to try and avoid problems with anti-right-click code. These attributes indicate that it was a left button click that caused the event, allowing it to pass both positive (is it the right button) and negative (is it anything except the left button) checks.

I haven't put in any position information because I couldn't be bothered. It appears that the mouse position data is hard to work with anyway, so it may as well be left blank.