enyojs/enyo — pull request #875 by aarontam (2014-10-03 01:39:25+00:00)
Title: BHV-14565: Do not pass shared event object references when firing custom event.

### Issue
Event objects are being repurposed and sent as the event argument for custom events, but can continue to be modified by multiple code paths, potentially resulting in callstack errors if dispatched back to the same location.

### Fix
We remove the event parameter where possible (and in the case of `TouchScrollStrategy`, we call the desired methods directly and do not bubble the event at all). In other cases, we pass the relevant properties in a hash directly as part of the event firing argument if we do not need access to such properties as `originator`. In cases where we need access to the `originator`, which will be have a different meaning when firing a custom event, we pass a clone of the original object in the `originalEvent` property.

### Notes
This can be a fairly intrusive change as it touches many parts of the code. I would appreciate extra review and also a sanity check in terms of deciding whether to pass a clone of the original object versus passing only the relevant properties.

Enyo-DCO-1.1-Signed-off-by: Aaron Tam