Re: Finding events on a page added using addEventListener
Boris Zbarsky <[email protected]>
| Newsgroups | gmane.comp.mozilla.devel.dom |
|---|---|
| Message-ID | <[email protected]> |
Jon wrote:
> document.addEventListener(
> "DOMNodeInserted",
> function(e) { catcher(e.target); },
> false
> );
Don't you also need to do this with the descendants of e.target?
> I think its triggered if an element is moved around the DOM so that means
> catcher() will be called multiple times on a node and so
> addEventListenerOld will recursively call itself when an event is
> added.
Yes. You need to handle that.
-Boris