jupiterjs/jquerypp — pull request #45 by jbrumwell (2012-08-17 16:54:36+00:00)
Title: Fastfix: Original can be undefined

Fixes pageX, pageY and which for when the original event does not exist and
the original value is undefined.

I was working with a jquery plugin that invokes mousemove like so

/trigger mousemove to move the knob to the current position
$(document).on({
mousemove: $.proxy(this.mousemove, this),
mouseup: $.proxy(this.mouseup, this)
}).trigger('mousemove');

Since the mousemove handler handles actually mouse movements and this custom event, when calling:

var something = e.pageX || someothervalue;

It causes and error "original is undefined" I have not needed the which event but it most likely suffers from the same issue.