Summary: | Add a new WKWebpagePreferences SPI for modal container observation policies | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Wenson Hsieh <wenson_hsieh> | ||||||
Component: | WebKit API | Assignee: | Wenson Hsieh <wenson_hsieh> | ||||||
Status: | RESOLVED FIXED | ||||||||
Severity: | Normal | CC: | bdakin, bfulgham, cdumez, ews-watchlist, japhet, katherine_cheney, thorton, webkit-bug-importer, wilander | ||||||
Priority: | P2 | Keywords: | InRadar | ||||||
Version: | WebKit Nightly Build | ||||||||
Hardware: | Unspecified | ||||||||
OS: | Unspecified | ||||||||
Attachments: |
|
Description
Wenson Hsieh
2021-12-08 09:56:19 PST
Created attachment 446390 [details]
Patch
Comment on attachment 446390 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=446390&action=review r=me > Source/WebKit/UIProcess/API/Cocoa/WKWebpagePreferences.mm:466 > + _websitePolicies->setModalContainerObservationPolicy(WebCore::ModalContainerObservationPolicy::Disabled); It really seems silly to require these adaptor methods for these equivalent enums, but I realize that's just the way this stuff is designed. Comment on attachment 446390 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=446390&action=review Thanks for the review! >> Source/WebKit/UIProcess/API/Cocoa/WKWebpagePreferences.mm:466 >> + _websitePolicies->setModalContainerObservationPolicy(WebCore::ModalContainerObservationPolicy::Disabled); > > It really seems silly to require these adaptor methods for these equivalent enums, but I realize that's just the way this stuff is designed. Indeed. That said, it does seem like it would be cleaner to separate the adapter method away from the call to `setModalContainerObservationPolicy` by adding a helper method like `WebKit::coreModalContainerObservationPolicy()`, similar to the mouse event policy one above. I'll do this before landing! Created attachment 446646 [details]
Patch
Committed r286831 (245064@main): <https://commits.webkit.org/245064@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 446646 [details]. |