[webkit-changes] [WebKit/WebKit] dc1ebf: [MacOS] WKWebView should have SPI to report whethe...
Abrar Rahman Protyasha
noreply at github.com
Fri May 3 08:48:59 PDT 2024
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: dc1ebf3e81905b72da8d9f266b88db88d7847f08
https://github.com/WebKit/WebKit/commit/dc1ebf3e81905b72da8d9f266b88db88d7847f08
Author: Abrar Rahman Protyasha <a_protyasha at apple.com>
Date: 2024-05-03 (Fri, 03 May 2024)
Changed paths:
M Source/WebKit/UIProcess/API/Cocoa/WKWebView.mm
M Source/WebKit/UIProcess/API/Cocoa/WKWebViewPrivate.h
M Source/WebKit/UIProcess/API/ios/WKWebViewIOS.mm
M Tools/TestWebKitAPI/Tests/WebKitCocoa/WKPDFView.mm
Log Message:
-----------
[MacOS] WKWebView should have SPI to report whether a PDF is being displayed
https://bugs.webkit.org/show_bug.cgi?id=273639
rdar://127442624
Reviewed by Tim Horton.
This patch exposes the `_isDisplayingPDF` method on WKWebViewMac, which
clients can query to answer whether the web view is presenting a main
frame PDF.
This also establishes parity with WKWebViewIOS, where the namesake was
added in 149116 at main.
* Source/WebKit/UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _isDisplayingPDF]):
Move getter implementation to this shared location.
* Source/WebKit/UIProcess/API/Cocoa/WKWebViewPrivate.h:
Move property declaration to the shared WKPrivate category.
* Source/WebKit/UIProcess/API/ios/WKWebViewIOS.mm:
(-[WKWebView _isDisplayingPDF]): Deleted.
* Tools/TestWebKitAPI/Tests/WebKitCocoa/WKPDFView.mm:
(TEST(WKWebView, IsDisplayingPDF)):
Add an API test exercising the `_isDisplayingPDF` SPI.
Canonical link: https://commits.webkit.org/278324@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