W3C home > Mailing lists > Public > www-dom@w3.org > April to June 2011

Re: [DOMCore] Making event initializing easier

From: Anne van Kesteren <annevk@opera.com>
Date: Sat, 25 Jun 2011 12:32:03 +0200
To: "Ian Hickson" <ian@hixie.ch>
Cc: "Jonas Sicking" <jonas@sicking.cc>, "www-dom@w3.org" <www-dom@w3.org>
Message-ID: <op.vxmnjpgb64w2qv@anne-van-kesterens-macbook-pro.local>
On Fri, 24 Jun 2011 20:23:58 +0200, Ian Hickson <ian@hixie.ch> wrote:
> Can you have some text in the core spec such that constructors like the
> above can just be defined as:
>    The FooEvent() constructor is an _Event Object Constructor_.
> ...or some such? Looks like the steps can be made generic easily; step 1
> can just refer to "the interface that the constructor was called on" or
> some such (heycam can give you better text), the others are already

http://dev.w3.org/2006/webapi/progress/#interface-progressevent has  
something like that now.

"ProgressEvent(type, eventInitDict) is an event constructor for  
ProgressEvent." with "event constructor for /interface/" being the generic  

> generic except for the argument names, but you can just refer to the
> arguments by position rather than name. Then there'd be just one prose
> line and some IDL each time.

Well no. You also need to define the event initialization dictionary and  
how it maps to the event. I do not think that can be done in a generic way.

Anne van Kesteren
Received on Saturday, 25 June 2011 10:32:38 UTC

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