WebCore: For continuous scrolling devices on the Mac (trackpads and Mighty/Magic
authorenrica@apple.com <enrica@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 15 Mar 2010 20:31:04 +0000 (20:31 +0000)
committerenrica@apple.com <enrica@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 15 Mar 2010 20:31:04 +0000 (20:31 +0000)
commit13780daf5b06a986de04bc02ec78b263cad3f775
treebf59a5f97c62dfdc3ac3cad0dcf97183b12405f5
parentfe7a0389c7f57f3d0ac1a387c8d4daf8b50d94ab
WebCore: For continuous scrolling devices on the Mac (trackpads and Mighty/Magic
Mice), set the number of wheel ticks equal to the atomic increment of
the device: a pixel.  This ensures that any scrolling action will
generate at least one wheel tick, regardless of the speed/length of
the gesture.

Reviewed by John Sullivan.

https://bugs.webkit.org/show_bug.cgi?id=29601
<rdar://problem/7453254>

Tests: fast/events/continuous-platform-wheelevent-in-scrolling-div.html
       fast/events/platform-wheelevent-in-scrolling-div.html

* platform/mac/WebCoreSystemInterface.h: Modify method signature.
* platform/mac/WebCoreSystemInterface.mm: Ditto.
* platform/mac/WheelEventMac.mm:
(WebCore::PlatformWheelEvent::PlatformWheelEvent): Call into
WebKitSystemInterface to determine both wheelTicksX/Y and deltaX/Y.
WKSI will query the event system for number of wheel ticks and
pixels/lines scrolled based on the device type.

WebKit/mac: Updated call to WKGetWheelEventDeltas() to match new method signature.

Reviewed by John Sullivan.

https://bugs.webkit.org/show_bug.cgi?id=29601
<rdar://problem/7453254>

* WebView/WebDynamicScrollBarsView.mm:
(-[WebDynamicScrollBarsView scrollWheel:]):

WebKitLibraries: Added two new output arguments to WKGetWheelEventDeltas() to return
the number of scroll wheel ticks in the x and y directions.

Reviewed by John Sullivan.

https://bugs.webkit.org/show_bug.cgi?id=29601.
<rdar://problem/7453254>

* WebKitSystemInterface.h:
* libWebKitSystemInterfaceLeopard.a:
* libWebKitSystemInterfaceSnowLeopard.a:
* libWebKitSystemInterfaceTiger.a:

LayoutTests: These tests verify that scrollwheel events (both continuous and
non-continuous) generate the expected pixel deltas in scrollable
regions, and also generate DOM mousewheel events with expected
wheelDelta values.

Reviewed by John Sullivan.

https://bugs.webkit.org/show_bug.cgi?id=29601
<rdar://problem/7453254>

* fast/events/continuous-platform-wheelevent-in-scrolling-div-expected.txt: Added.
* fast/events/continuous-platform-wheelevent-in-scrolling-div.html: Added.
* fast/events/platform-wheelevent-in-scrolling-div-expected.txt: Added.
* fast/events/platform-wheelevent-in-scrolling-div.html: Added.
* fast/events/wheelevent-in-scrolling-div-expected.txt: Rebased
expected results due to change in test output formatting.
* fast/events/wheelevent-in-scrolling-div.html: Modified to use common
js logging and assertion functions.
* platform/gtk/Skipped: DRT support needed by tests not yet implemented
in GTK port.  See https://bugs.webkit.org/show_bug.cgi?id=36003.
* platform/mac-tiger/Skipped: DRT support needed by tests not possible
to implement in Tiger.
* platform/qt/Skipped: DRT support for tests not yet implemented in Qt
port.  See https://bugs.webkit.org/show_bug.cgi?id=36004.
* platform/win/Skipped: DRT support for tests not yet implemented in
Windows port.  See https://bugs.webkit.org/show_bug.cgi?id=36002.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@56012 268f45cc-cd09-0410-ab3c-d52691b4dbfc
22 files changed:
LayoutTests/ChangeLog
LayoutTests/fast/events/continuous-platform-wheelevent-in-scrolling-div-expected.txt [new file with mode: 0644]
LayoutTests/fast/events/continuous-platform-wheelevent-in-scrolling-div.html [new file with mode: 0644]
LayoutTests/fast/events/platform-wheelevent-in-scrolling-div-expected.txt [new file with mode: 0644]
LayoutTests/fast/events/platform-wheelevent-in-scrolling-div.html [new file with mode: 0644]
LayoutTests/fast/events/wheelevent-in-scrolling-div-expected.txt
LayoutTests/fast/events/wheelevent-in-scrolling-div.html
LayoutTests/platform/gtk/Skipped
LayoutTests/platform/mac-tiger/Skipped
LayoutTests/platform/qt/Skipped
LayoutTests/platform/win/Skipped
WebCore/ChangeLog
WebCore/platform/mac/WebCoreSystemInterface.h
WebCore/platform/mac/WebCoreSystemInterface.mm
WebCore/platform/mac/WheelEventMac.mm
WebKit/mac/ChangeLog
WebKit/mac/WebView/WebDynamicScrollBarsView.mm
WebKitLibraries/ChangeLog
WebKitLibraries/WebKitSystemInterface.h
WebKitLibraries/libWebKitSystemInterfaceLeopard.a
WebKitLibraries/libWebKitSystemInterfaceSnowLeopard.a
WebKitLibraries/libWebKitSystemInterfaceTiger.a