[Synthetic Click] Dispatch mouseout soon after mouseup
authorzalan@apple.com <zalan@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 12 Mar 2019 01:58:17 +0000 (01:58 +0000)
committerzalan@apple.com <zalan@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 12 Mar 2019 01:58:17 +0000 (01:58 +0000)
commita69331274e31359ae7789d08eb92940b7ebc816a
tree542df8c55b149bd03ac5999dd40c84bbd1e7a052
parent85349505358f5d44728b1c67ddbf46355c80e27a
[Synthetic Click] Dispatch mouseout soon after mouseup
https://bugs.webkit.org/show_bug.cgi?id=195575
<rdar://problem/47093049>

Reviewed by Simon Fraser.

Source/WebCore:

Let's fire a mouseout event when a click is submitted as the result of a tap. It helps to dismiss content which would otherwise require you to move the mouse (cases like control bar on youtube.com).

Test: fast/events/touch/ios/content-observation/mouse-out-event-should-fire-on-click.html

* page/EventHandler.h:
* page/ios/EventHandlerIOS.mm:
(WebCore::EventHandler::dispatchFakeMouseOut):

Source/WebKit:

* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::completeSyntheticClick):

LayoutTests:

* fast/events/touch/ios/content-observation/mouse-out-event-should-fire-on-click-expected.txt: Added.
* fast/events/touch/ios/content-observation/mouse-out-event-should-fire-on-click.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@242763 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/fast/events/touch/ios/content-observation/visibility-change-happens-while-in-mousemoved.html
Source/WebCore/ChangeLog
Source/WebCore/page/EventHandler.cpp
Source/WebCore/page/EventHandler.h
Source/WebCore/page/ios/EventHandlerIOS.mm
Source/WebKit/ChangeLog
Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm