Re: Question about wheel events

On 10/14/2010 02:32 AM, David Flanagan wrote:
> The current Editor's Draft has this description of the deltaMode
> property of WheelEvent
>
>> deltaMode of type unsigned long, readonly
>> The deltaMode attribute contains an indication of to indicate the i
>> units of measurement for the delta values. The default value is
>> DOM_DELTA_PIXEL (pixels). The value of deltaMode may be different for
>> each of deltaX, deltaY, and deltaZ, based on system configuration.
>
> Does the fact that deltaMode can be different for the X, Y, and Z axes
> mean that browsers always generate separate events for each axis?
>
> If a user moves the mouse wheel "diagonally" to scroll down and to the
> right, is the browser required to generate one wheel event, two wheel
> events, or can it do either one of those things?
>
> I think the spec ought to be clarified to explain this.
>
> David Flanagan
>
>

Since there is separate delta for different axis, browser should
generate only one event if deltaMode is the same.
If for some reason different deltaMode is used for different axis,
then there will be several events.

But perhaps the spec should be clarified.

-Olli

Received on Wednesday, 20 October 2010 15:56:28 UTC