make it possible to either augment objects or to use prototypical inheritance

This version allows you to add event dispatching abilities with the older EventDispatcher.call(this) call, or to use the EventDispatcher.prototype as prototype for your object, as in the latest version of the library.

I've changed the example to demonstrate both styles.