W3C home > Mailing lists > Public > www-dom@w3.org > July to September 2000

Re: event registration another way

From: <keshlam@us.ibm.com>
Date: Thu, 28 Sep 2000 09:55:05 -0400
To: www-dom@w3.org
Message-ID: <OFCEA72CE8.F2509664-ON85256968.004B618F@lotus.com>

> <quote>
>    If multiple identical EventListeners are registered
>    on the same EventTarget with the same parameters
>    the duplicate instances are discarded. They do not
> </quote>
>I assume the above "multiple identical EventListeners"
>refers to object identity.

That is our intent. (Though the definition of object identity may vary by
binding, for the same reasons that have caused us to consider adding
Node.isSameNode() as a more trustworthy alternative to the language's ==

>If I had it my way, I'd rather that removeEventListener
>method had to be called as many times as addEventListener
>but still insist that the event listener be called only once.

Interesting point re deregistering restoring the state before the
registration, for "stacking" purposes. If we'd thought of it, I think we
might have gone that route.

It'd be possible,but a bit messy, to add that feature later; we'd
essentially need a new de-registration method, with the old one becoming a
sort of "de-register all stacked registrations".

At this point in the development cycle we really should be making only
those changes which are Absolutely Necessary. I'm torn re whether this
qualifies as such or not.

(Good to know folks are starting to try to use our events... but ye gods,
we HAVE to find a way to provoke this sort of feedback _before_ we nail the
spec in place!)
Received on Thursday, 28 September 2000 10:01:23 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 20 October 2015 10:46:07 UTC