Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 0dd1285aeb793e3db7b0ee3d768a46f29ba50b5c
https://github.com/WebKit/WebKit/commit/0dd1285aeb793e3db7b0ee3d768a46f29ba50b5c
Author: Aditya Keerthi <[email protected]>
Date: 2026-03-11 (Wed, 11 Mar 2026)
Changed paths:
M Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm
Log Message:
-----------
REGRESSION (298350@main): [iOS] After long pressing on an image has an
embedded link, thumbnail photo when clicking and dragging other photos shows
incorrect image
https://bugs.webkit.org/show_bug.cgi?id=309631
rdar://171732399
Reviewed by Wenson Hsieh and Abrar Rahman Protyasha.
298350@main incorrectly changed `-[WKContentView
dragInteraction:previewForLiftingItem:session:]`
to move `_positionInformationLinkIndicator` rather than set it to `nullptr`
after
creating the preview for a drag.
The text indicator snapshot is created when long pressing an image that has an
embedded link. The snapshot is only meant to be used once, for the drag preview
if the user immediately drags the same element. This ensures the drag preview
visual matches the context menu preview. However, by no longer clearing the text
indicator, the stale snapshot is used on every subsequent drag operation.
Fix by restoring the original logic to clear the text indicator once it has been
used for a drag preview.
No new tests due to a lack of testing infrastructure. In order to test this
change both context menu preview presentation, and drag and drop must be
exercised. However, all context menu API tests are currently broken.
Additionally, drag and drop is not testable on iOS using layout tests.
* Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView dragInteraction:previewForLiftingItem:session:]):
Canonical link: https://commits.webkit.org/309064@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications