W3C home > Mailing lists > Public > www-svg@w3.org > August 2006

Re: SVG12: wheelDelta should be UIEvent.detail

From: Bjoern Hoehrmann <derhoermi@gmx.net>
Date: Tue, 08 Aug 2006 20:05:11 +0200
To: "Scott Hayman" <shayman@rim.com>
Cc: <www-svg@w3.org>
Message-ID: <i7ihd2pb8lian4jjdbvd0pl2c6pna55vom@hive.bjoern.hoehrmann.de>

* Scott Hayman wrote:
>It seems odd to me, and here I am speaking on my own behalf and not that
>of the WG, that an event that inherits from MouseEvent could re-use the
>'detail' attribute for something other than what it is specified for by
>MouseEvent.  I would think that this would be more confusing than
>introducing a new attribute.

In DOM Level 2 Events, only three mouse event types use UIEvent.detail,
click, mouseup, and mousedown. For all three event types UIEvent.detail
reflects the same information; in order to avoid stating this for all
three event types, the specification just says once that if it is used,
then like this. The text there is not meant to establish a relationship
between the MouseEvent interface and UIEvent.detail.

>So the 'detail' attribute of MouseEvent in the DOM Level 3 Events spec
>no longer contains the information about the number of button presses?
>Isn't this a backwards compatibility issue?

There is no change, UIEvent.detail is still in use for click, mouseup,
and mousedown, and not in use for e.g. mousemove. If some event object
for a mousemove event in some implementation specifies the number of
mouse button presses and releases, then that implementation operates
outside of what is specified in the DOM Events specification. I do not
think this is particularily confusing, it is not important for e.g.
the mousemove event to inform about the number of clicks, but it might
be useful if it would carry information about, say, the direction of
the move, the current device velocity, or what mouse gesture is being
performed, a fixed relationship between the MouseEvent interface and
UIEvent.detail is neither needed nor useful, so it's not there.
-- 
Björn Höhrmann · mailto:bjoern@hoehrmann.de · http://bjoern.hoehrmann.de
Weinh. Str. 22 · Telefon: +49(0)621/4309674 · http://www.bjoernsworld.de
68309 Mannheim · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/ 
Received on Tuesday, 8 August 2006 18:05:22 GMT

This archive was generated by hypermail 2.3.1 : Friday, 8 March 2013 15:54:35 GMT