W3C home > Mailing lists > Public > whatwg@whatwg.org > October 2013

[whatwg] Should onfoo event handler properties be on Element or HTMLElement?

From: Philip Jägenstedt <philipj@opera.com>
Date: Tue, 8 Oct 2013 15:49:48 +0200
Message-ID: <CAMQvoC=zuWHUA_Ftn4BzhBzXFc0ud4AK4pRofrL6hGFfsD3Y6Q@mail.gmail.com>
To: WHATWG <whatwg@whatwg.org>
The spec says HTMLElement, by way of GlobalEventHandlers and
"HTMLElement implements GlobalEventHandlers":


Gecko has "HTMLElement implements GlobalEventHandlers" in its IDL,[1]
but somewhat surprisingly also "SVGElement implements

I'm trying to add GlobalEventHandlers IDL in Blink [3] to reduce code
duplication, where the current state of things is that the onfoo event
handler attributes are on Element, not HTMLElement. I can see two

1. Do what Gecko does, even though there's no SVG spec requiring it yet.
2. Just say "Element implements GlobalEventHandlers".

I would prefer option 2, since we already have a unified "Document
implements GlobalEventHandlers".

Would other browser vendors be OK with this change?


[1] http://hg.mozilla.org/mozilla-central/file/e48cee83453d/dom/webidl/HTMLElement.webidl
[2] http://hg.mozilla.org/mozilla-central/file/e48cee83453d/dom/webidl/SVGElement.webidl
[3] http://code.google.com/p/chromium/issues/detail?id=305112
Received on Tuesday, 8 October 2013 13:50:19 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 17:00:11 UTC