[webkit-changes] [WebKit/WebKit] 3918b5: [macOS] Cannot click to move cursor focus to mail ...
Aditya Keerthi
noreply at github.com
Fri Sep 6 10:43:30 PDT 2024
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 3918b513f4cd13a5d13e03bbd6e1a6a680875882
https://github.com/WebKit/WebKit/commit/3918b513f4cd13a5d13e03bbd6e1a6a680875882
Author: Aditya Keerthi <akeerthi at apple.com>
Date: 2024-09-06 (Fri, 06 Sep 2024)
Changed paths:
M Source/WebKit/UIProcess/mac/PageClientImplMac.mm
M Source/WebKit/UIProcess/mac/WKTextAnimationManager.h
M Source/WebKit/UIProcess/mac/WKTextAnimationManager.mm
M Source/WebKit/UIProcess/mac/WebViewImpl.h
M Source/WebKit/UIProcess/mac/WebViewImpl.mm
M Tools/TestWebKitAPI/Tests/WebKitCocoa/WritingTools.mm
Log Message:
-----------
[macOS] Cannot click to move cursor focus to mail body after using smart reply and clicking in subject field
https://bugs.webkit.org/show_bug.cgi?id=279234
rdar://135281189
Reviewed by Wenson Hsieh, Richard Robinson, and Abrar Rahman Protyasha.
A `_WTTextEffectView` is inserted into the view hierarchy when performing
Writing Tools animations. However, it is currently not being removed once the
animations are complete. This is problematic, as the `_WTTextEffectView`
prevents the `WKWebView` from becoming first responder, when clicking over the
web view.
Fix by removing the effect view once animations are complete.
Additionally, resolve memory leaks and actually remove text effects from a map
when they are finished. That is the signal used to remove the effect view.
* Source/WebKit/UIProcess/mac/PageClientImplMac.mm:
(WebKit::PageClientImpl::didCommitLoadForMainFrame):
Remove the effect view when navigating to a different page.
* Source/WebKit/UIProcess/mac/WKTextAnimationManager.h:
* Source/WebKit/UIProcess/mac/WKTextAnimationManager.mm:
(-[WKTextAnimationManager addTextAnimationForAnimationID:withData:]):
Add a completion handler for the source animation, in order to keep the
map of effects up-to-date and remove a memory leak.
Add the effect view to the view hierarchy when needed.
(-[WKTextAnimationManager removeTextAnimationForAnimationID:]):
Remove the effect view if there are no active effects.
(-[WKTextAnimationManager hideTextAnimationView]):
* Source/WebKit/UIProcess/mac/WebViewImpl.h:
* Source/WebKit/UIProcess/mac/WebViewImpl.mm:
(WebKit::WebViewImpl::hideTextAnimationView):
* Tools/TestWebKitAPI/Tests/WebKitCocoa/WritingTools.mm:
(TEST(WritingTools, FocusWebViewAfterAnimation)):
Canonical link: https://commits.webkit.org/283274@main
To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications
More information about the webkit-changes
mailing list