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

Re: Moving Form Events from DOM3 Events to HTML5 (was: Removing Form Events?)

From: Ian Hickson <ian@hixie.ch>
Date: Mon, 21 Sep 2009 22:10:14 +0000 (UTC)
To: Doug Schepers <schepers@w3.org>
Cc: "www-dom@w3.org" <www-dom@w3.org>
Message-ID: <Pine.LNX.4.62.0909212157590.2822@hixie.dreamhostps.com>
On Mon, 21 Sep 2009, Doug Schepers wrote:
> Ian Hickson wrote (on 9/21/09 6:42 AM):
> > On Mon, 21 Sep 2009, Doug Schepers wrote:
> > > 
> > >  I'm pondering removing the event types associated with forms: 'change'
> > >  [1], 'submit' [2], and 'reset' [3].  They are so specific to HTML that
> > >  they are probably best defined there, rather than in a generic DOM Event
> > >  specification.
> > 
> > What does it mean to define an event? (i.e. what would I have to do in
> > HTML5 if we moved this there?)
> 
> You would need to specify the event type (e.g. 'submit'), which 
> interface(s) it uses, what values it populates the attributes of that 
> interface with and where they are derived from, whether it bubbles, what 
> the event target is, whether or not it is cancelable, what its default 
> action is (if that is to be defined in the spec, and is not 
> UA-dependent), and what extra context information it has beyond simply 
> the event target.
>
> You also need to specify the conditions under which it is dispatched... 
> say, user submits a form, or more precisely, user activates a <input> 
> element which is of types 'submit' or 'image' on a form.  You might also 
> discuss the conditions under which an event does not fire, or when it 
> exhibits idiosyncratic behavior (like 'load'), because of legacy quirks.

In that case HTML5 already defines 'submit', 'DOMActivate', 'load', 
'DOMContentLoaded', 'error', 'change', 'input', 'unload', 'focus' (just 
for elements, not windows), and 'blur' (again just for elements, not 
windows), as well as many other events that DOM3 Events doesn't currently 
mention.

It doesn't currently define 'reset' or 'abort'. I'd be happy to define 
those in HTML5; their absence is an oversight.

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'
Received on Monday, 21 September 2009 22:03:59 GMT

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