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

Re: [DOMCore] Making event initializing easier

From: Anne van Kesteren <annevk@opera.com>
Date: Sat, 02 Jul 2011 08:42:40 +0200
To: www-dom@w3.org, "David Flanagan" <dflanagan@mozilla.com>
Message-ID: <op.vxzbleij64w2qv@anne-van-kesterens-macbook-pro.local>
On Fri, 01 Jul 2011 22:43:45 +0200, David Flanagan <dflanagan@mozilla.com>  
wrote:
> You should swap the order of steps 3 and 4, or include text in step 4
> excluding dictionary members named "type".

The dictionary defined does not include type so any members named such  
will not make it that far.


> Should this algorithm also set isTrusted?  That attribute actually seems
> overspecified currently.  initEvent() sets it explicitly, and there is
> text that says that it must be initialized to false, and it is also set
> explicitly by dispatchEvent() even though it is readonly.

initEvent() sets it because you can have a trusted event that an author  
changes. dispatchEvent() sets it for the same reason.


> Does this spec need to say something about when isTrusted is true?

It says so in the fire an event steps.


> Step 2 should probably only succeed if it is the name of an interface
> that inherits from Event and defines an initEvent() method, right?

No. Events created that way however cannot do more than changing the type  
and whether it bubbles or is cancelable using the initEvent() method.


> Hixie said he plans to remove the initEvent() methods for whatever event
> interfaces he can.  If he does that, it will probably require changes to
> the table in step 1.


-- 
Anne van Kesteren
http://annevankesteren.nl/
Received on Saturday, 2 July 2011 06:43:00 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 22 June 2012 06:14:08 GMT