Implement WheelEvent constructor
authorharaken@chromium.org <haraken@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 30 Jan 2013 22:43:57 +0000 (22:43 +0000)
committerharaken@chromium.org <haraken@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 30 Jan 2013 22:43:57 +0000 (22:43 +0000)
commit1b021dd36ff98d012a8ba022fc97fb091ff9a86a
treeef04034771fb8c9929d14c0312739cd16126bf4c
parentd9ecff3c000f1dc32552b090bdd10c884776e793
Implement WheelEvent constructor
https://bugs.webkit.org/show_bug.cgi?id=108303

Reviewed by Adam Barth.

Source/WebCore:

Editor's draft: https://dvcs.w3.org/hg/d4e/raw-file/tip/source_respec.htm

This patch implements UIEvent constructor under a DOM4_EVENTS_CONSTRUCTOR flag,
which is enabled on Chromium and Safari.

Test: fast/events/constructors/wheel-event-constructor.html

* dom/WheelEvent.cpp:
(WebCore::WheelEventInit::WheelEventInit):
(WebCore):
(WebCore::WheelEvent::WheelEvent):
(WebCore::WheelEvent::initWheelEvent):
* dom/WheelEvent.h:
(WheelEventInit):
(WebCore):
(WheelEvent):
(WebCore::WheelEvent::create):
(WebCore::WheelEvent::wheelDelta):
(WebCore::WheelEvent::wheelDeltaX):
(WebCore::WheelEvent::wheelDeltaY):
(WebCore::WheelEvent::rawDeltaX):
(WebCore::WheelEvent::rawDeltaY):
(WebCore::WheelEvent::granularity):
(WebCore::WheelEvent::webkitDirectionInvertedFromDevice):
(WebCore::WheelEvent::isHorizontal):
* dom/WheelEvent.idl:

Source/WebKit/chromium:

This patch just renames an enum value to avoid style check error.

* src/WebViewImpl.cpp:
(WebKit::WebViewImpl::scrollBy):

LayoutTests:

Editor's draft: https://dvcs.w3.org/hg/d4e/raw-file/tip/source_respec.htm

This patch implements UIEvent constructor under a DOM4_EVENTS_CONSTRUCTOR flag,
which is enabled on Chromium and Safari.

Test: fast/events/constructors/wheel-event-constructor.html

* fast/events/constructors/wheel-event-constructor-expected.txt: Added.
* fast/events/constructors/wheel-event-constructor.html: Added.
* platform/efl/TestExpectations:
* platform/gtk/TestExpectations:
* platform/qt/TestExpectations:
* platform/win/TestExpectations:
* platform/wincairo/TestExpectations:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@141318 268f45cc-cd09-0410-ab3c-d52691b4dbfc
17 files changed:
LayoutTests/ChangeLog
LayoutTests/fast/dom/constructed-objects-prototypes-expected.txt
LayoutTests/fast/dom/dom-constructors-expected.txt
LayoutTests/fast/dom/dom-constructors.html
LayoutTests/fast/events/constructors/wheel-event-constructor-expected.txt [new file with mode: 0644]
LayoutTests/fast/events/constructors/wheel-event-constructor.html [new file with mode: 0644]
LayoutTests/platform/efl/TestExpectations
LayoutTests/platform/gtk/TestExpectations
LayoutTests/platform/qt/TestExpectations
LayoutTests/platform/win/TestExpectations
LayoutTests/platform/wincairo/TestExpectations
Source/WebCore/ChangeLog
Source/WebCore/dom/WheelEvent.cpp
Source/WebCore/dom/WheelEvent.h
Source/WebCore/dom/WheelEvent.idl
Source/WebKit/chromium/ChangeLog
Source/WebKit/chromium/src/WebViewImpl.cpp