Source/WebKit2: <rdar://problem/9557598> REGRESSION (WebKit2): Non-activating links...
authormitz@apple.com <mitz@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 27 Feb 2012 18:00:23 +0000 (18:00 +0000)
committermitz@apple.com <mitz@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 27 Feb 2012 18:00:23 +0000 (18:00 +0000)
commitde993c974ecf8f6d1ee68ed1247859e481eafcad
tree670a2adecf6dee57a94842cf8d846482c97f8bb1
parent98138a813a790feda83e7fb4be1d5e06d223be98
Source/WebKit2: <rdar://problem/9557598> REGRESSION (WebKit2): Non-activating links sometimes don’t work
https://bugs.webkit.org/show_bug.cgi?id=79607

Reviewed by Adele Peterson.

Test: TestWebKitAPI/Tests/mac/AcceptsFirstMouse.mm

This was caused by not mapping the mouse event coordinates from window coordinates to
document coordinates.

* WebProcess/WebPage/mac/WebPageMac.mm:
(WebKit::WebPage::performDictionaryLookupAtLocation): Convert the point to main frame
coordinates when performing the hit test.
(WebKit::WebPage::shouldDelayWindowOrderingEvent): Convert the point to the main or focused
frame coordinates when perfomring the hit test.
(WebKit::WebPage::acceptsFirstMouse): Ditto.

Tools: Added a test for <rdar://problem/9557598> REGRESSION (WebKit2): Non-activating links sometimes don’t work
https://bugs.webkit.org/show_bug.cgi?id=79607

Reviewed by Adele Peterson.

* TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj: Added new files.
* TestWebKitAPI/Tests/mac/AcceptsFirstMouse.mm: Added.
(TestWebKitAPI::AcceptsFirstMouse::url):
(TestWebKitAPI::AcceptsFirstMouse::didLoadURL):
(TestWebKitAPI::AcceptsFirstMouse::runTest):
(TestWebKitAPI::TEST_F):
* TestWebKitAPI/Tests/mac/acceptsFirstMouse.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@109004 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebKit2/ChangeLog
Source/WebKit2/WebProcess/WebPage/mac/WebPageMac.mm
Tools/ChangeLog
Tools/TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj
Tools/TestWebKitAPI/Tests/mac/AcceptsFirstMouse.mm [new file with mode: 0644]
Tools/TestWebKitAPI/Tests/mac/acceptsFirstMouse.html [new file with mode: 0644]