RE: HTML5 Feedback: Event bubbling and various event handler DOM attributes




-----Original Message-----
From: Simon Pieters [mailto:simonp@opera.com]
Sent: Wednesday, May 19, 2010 3:51 PM
To: public-html@w3.org; Travis Leithead
Cc: Adrian Bateman
Subject: Re: HTML5 Feedback: Event bubbling and various event handler DOM attributes



On Wed, 19 May 2010 20:28:52 +0200, Travis Leithead <travil@microsoft.com<mailto:travil@microsoft.com>>

wrote:



> focus/blur and readystatechange DOM attributes?

>

> Similarly to the above argument, the readystatechange event fires at

> the document and does not bubble, yet a DOM attribute is defined on

> the Window interface for "onreadystatechange." Also, blur/focus events

> _may_ fire on Window, and do fire on Elements, but because they also

> don't bubble, their event handler DOM attributes on the HTMLDocument

> interface seems somewhat odd.

>

> What is the design principle for this?



I think the design principle here is to expose all event handlers on all of Window, HTMLDocument and HTMLElement, for consistency and ease of impl.

The exception is event handlers for <marquee>.



If that’s the design principle then I can agree with it; I just suspect that others will ask the same question, and wondered if there was more to it.

Received on Monday, 24 May 2010 20:35:49 UTC