Re: Web MIDI polyfill

Not at all; like I said, I was sailing in uncharted (for myself, at least)
waters, so another set of eyes is appreciated.


On Mon, Dec 17, 2012 at 12:14 PM, Marcos Caceres <w3c@marcosc.com> wrote:

> On Monday, December 17, 2012 at 7:28 PM, Chris Wilson wrote:
> >
> > I went through event dispatching, trying to find an example that wasn't
> dispatching on a DOM element, and couldn't find one; after thinking through
> the implications, I couldn't come up with a reason that building my own
> would have negative implications, and it seemed much easier (and lower
> overhead) than creating a fake element. I could easily be wrong, but I was
> trying to think about it, at least. :)
>
> Ok, I remember now what had screwed me in the past: I'd tried to extend
> DOMEvent and then tried to dispatch that as an event. like:
>
> function MyCustomEvent(){}
> MyCustomEvent.prototype = new DOMEvent();
> var e = new MyCustomEvent();
> document.body.dispatchEvent(e);
>
> Of course, that fails spectacularly (though it shouldn't if Host Objects
> were not magical).
>
> So, I'm really sorry Chris for making you waste time thinking about that.
>
>
> --
> Marcos Caceres
>
>
>
>

Received on Monday, 17 December 2012 20:27:07 UTC