Extend EventDispatcher::dispatchSimulatedClick to allow sending a mouseover event
authorjonlee@apple.com <jonlee@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 26 Nov 2012 09:11:52 +0000 (09:11 +0000)
committerjonlee@apple.com <jonlee@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 26 Nov 2012 09:11:52 +0000 (09:11 +0000)
commitc3bafd9020f8b00098aadcfd41f58e366ee8dc3a
tree7e2efba8963c0fb4a929beea46b78dea0072244a
parent9d4cd28fe5ee7f97bf071c7aac4e0a1a0951ffbf
Extend EventDispatcher::dispatchSimulatedClick to allow sending a mouseover event
https://bugs.webkit.org/show_bug.cgi?id=102610
<rdar://problem/12725663>

Reviewed by Darin Adler.

Update the dispatchSimulatedClick() to take option enums for dispatching events.

* dom/SimulatedClickOptions.h: Added. Define two options enums. One tracks which mouse
events to send. The other determines whether to force the element to repaint.

* dom/EventDispatcher.cpp:
(WebCore::EventDispatcher::dispatchSimulatedClick): Refactor to use the option enums.
* dom/EventDispatcher.h:
(EventDispatcher): Update function signature.

* dom/Node.cpp: Refactor parameters to use the options enums rather than booleans.
(WebCore::Node::dispatchSimulatedClick):
* dom/Node.h:

Refactor. Remove redundant comments.
* html/BaseCheckableInputType.cpp:
(WebCore::BaseCheckableInputType::accessKeyAction):
* html/BaseClickableWithKeyInputType.cpp:
(WebCore::BaseClickableWithKeyInputType::accessKeyAction):
* html/HTMLAnchorElement.cpp:
(WebCore::HTMLAnchorElement::accessKeyAction):
* html/HTMLButtonElement.cpp:
(WebCore::HTMLButtonElement::accessKeyAction):
* html/HTMLElement.cpp:
(WebCore::HTMLElement::click):
(WebCore::HTMLElement::accessKeyAction):
* html/HTMLSelectElement.cpp:
(WebCore::HTMLSelectElement::accessKeyAction):
* html/RadioInputType.cpp:
(WebCore::RadioInputType::handleKeydownEvent):
* html/RangeInputType.cpp:
(WebCore::RangeInputType::accessKeyAction):

Add SimulatedClickOptions.h.
* GNUmakefile.list.am:
* Target.pri:
* WebCore.gypi:
* WebCore.vcproj/WebCore.vcproj:
* WebCore.xcodeproj/project.pbxproj:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@135690 268f45cc-cd09-0410-ab3c-d52691b4dbfc
19 files changed:
Source/WebCore/ChangeLog
Source/WebCore/GNUmakefile.list.am
Source/WebCore/Target.pri
Source/WebCore/WebCore.gypi
Source/WebCore/WebCore.vcproj/WebCore.vcproj
Source/WebCore/WebCore.xcodeproj/project.pbxproj
Source/WebCore/dom/EventDispatcher.cpp
Source/WebCore/dom/EventDispatcher.h
Source/WebCore/dom/Node.cpp
Source/WebCore/dom/Node.h
Source/WebCore/dom/SimulatedClickOptions.h [new file with mode: 0644]
Source/WebCore/html/BaseCheckableInputType.cpp
Source/WebCore/html/BaseClickableWithKeyInputType.cpp
Source/WebCore/html/HTMLAnchorElement.cpp
Source/WebCore/html/HTMLButtonElement.cpp
Source/WebCore/html/HTMLElement.cpp
Source/WebCore/html/HTMLSelectElement.cpp
Source/WebCore/html/RadioInputType.cpp
Source/WebCore/html/RangeInputType.cpp