Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 4f5b1337cdf766480f21401c40e8f954a970a8d6
https://github.com/WebKit/WebKit/commit/4f5b1337cdf766480f21401c40e8f954a970a8d6
Author: Richard Robinson <[email protected]>
Date: 2024-09-04 (Wed, 04 Sep 2024)
Changed paths:
M Source/WebCore/page/PointerCaptureController.cpp
M Source/WebCore/page/PointerCaptureController.h
Log Message:
-----------
REGRESSION (282524@main) (iOS): Tap and click events unresponsive after
closing Safari and coming back
https://bugs.webkit.org/show_bug.cgi?id=279146
rdar://135211157
Reviewed by Abrar Rahman Protyasha.
In `PointerCaptureController`, there is logic which tries to not execute a
mouse or pointer event
if there is a capturing event whose state is "Ready". However, prior to
282524@main, this logic
only worked to not execute pointer events, but would still in fact execute
mouse events.
After 282524@main, since click, auxclick, and contextmenu are now pointer
events, the `PointerCaptureController` logic
is now successful in preventing both mouse _and_ pointer events.
This in itself isn't a problem, and is the desired behavior when there is an
active capture state.
However, in some cases (such as dismissing Safari), a touch event ends up
beginning but never getting
cancelled properly. Specifically, while a `pointercancel` event is dispatched,
the associated capture
data's state was never properly updated.
Fix this by calling `cancelPointer`, which properly updates the state and also
more closely adheres to
the pointer event specification with regards to which events should be
dispatched.
Fixing this then in turn fixes the original issue, since now there will no
erroneous states which are active.
A test will be added in a follow up.
* Source/WebCore/page/PointerCaptureController.cpp:
(WebCore::PointerCaptureController::dispatchEventForTouchAtIndex):
(WebCore::PointerCaptureController::cancelPointer):
* Source/WebCore/page/PointerCaptureController.h:
Canonical link: https://commits.webkit.org/283187@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes