W3C home > Mailing lists > Public > public-webapi@w3.org > March 2006

Re: ISSUE-30: mousewheel event

From: Maciej Stachowiak <mjs@apple.com>
Date: Fri, 3 Mar 2006 15:04:02 -0800
Message-Id: <B2056913-ACAC-4273-9447-08B0CADBF4F0@apple.com>
Cc: Jonas Sicking <jonas@sicking.cc>, Web APIs WG <public-webapi@w3.org>
To: Matthew Raymond <mattraymond@earthlink.net>


On Mar 3, 2006, at 2:38 PM, Matthew Raymond wrote:

>
> Jonas Sicking wrote:
>>>> I want to catch events from input devices to override the default
>>>> behaviour.  Whatever the default behaviour is is irrelevant.
>>>    So if I have my mouse set up to switch applications when I  
>>> move the
>>> mouse wheel, the BROWSER should prevent me from doing so and instead
>>> hand that input off to a Javascript function?!? Get real!
>>
>> Hopefully if you configure your mousewheel to do that then the window
>> manager won't even send a mousewheel event to the applications and so
>> the UA wouldn't even fire the event.
>
>    Does a mouse wheel generate a "mousewheel" event at the operating
> system level, or does it generate some type of scroll-related  
> event? Are
> we dictating that user agents pass input events to scripted event
> functions without abstraction of that input? There are two problems
> here. First, we can't assume that a mouse wheel triggered a specific
> event type. Second, we can't assume that the event type triggered is
> mouse wheel related. For instance, my OS may take key presses for
> certain keys and change them into "pointer scroll" events. Do we  
> ignore
> these events because they aren't technically "mouse wheel" events? It
> doesn't matter what we call the DOM event we're talking about here,  
> but
> it does matter how we define the DOM event itself.

The primary semantic intent of the event is to represent the  
scrollwheel found on some mice. Anything that is treated as "the  
same" by the operating system should trigger the same event. What  
counts as the same is up to the operating system and the UA. For  
instance, the trackpad on many Apple laptops allows a two-finger drag  
that causes scrolling. This is treated as a mousewheel event even  
though there is no wheel or indeed even a mouse involved.

I think what to actually do is pretty clear, as UAs already have this  
implemented, we just need to make sure it is also specified clearly.

Regards,
Maciej
Received on Friday, 3 March 2006 23:04:03 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 8 January 2008 14:18:53 GMT