-
Notifications
You must be signed in to change notification settings - Fork 515
WebKit iOS xcode16.2 b3
Rolf Bjarne Kvinge edited this page Dec 2, 2024
·
2 revisions
#WebKit.framework https://github.com/xamarin/xamarin-macios/pull/21733
diff -ruN /Applications/Xcode_16.2.0-beta2.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/WebKit.framework/Headers/WKDownloadDelegate.h /Applications/Xcode_16.2.0-beta3.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/WebKit.framework/Headers/WKDownloadDelegate.h
--- /Applications/Xcode_16.2.0-beta2.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/WebKit.framework/Headers/WKDownloadDelegate.h 2024-10-31 05:41:35
+++ /Applications/Xcode_16.2.0-beta3.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/WebKit.framework/Headers/WKDownloadDelegate.h 2024-11-16 06:20:34
@@ -38,6 +38,16 @@
WKDownloadRedirectPolicyAllow,
} NS_SWIFT_NAME(WKDownload.RedirectPolicy) API_AVAILABLE(macos(11.3), ios(14.5));
+/* @enum WKDownloadPlaceholderPolicy
+ @abstract The policy for creating a placeholder file in the Downloads directory during downloads.
+ @constant WKDownloadPlaceholderPolicyDisable Do not create a placeholder file.
+ @constant WKDownloadPlaceholderPolicyEnable Create a placeholder file.
+ */
+typedef NS_ENUM(NSInteger, WKDownloadPlaceholderPolicy) {
+ WKDownloadPlaceholderPolicyDisable,
+ WKDownloadPlaceholderPolicyEnable,
+} NS_SWIFT_NAME(WKDownload.PlaceholderPolicy) API_AVAILABLE(ios(18.2), visionos(NA));
+
NS_ASSUME_NONNULL_BEGIN
WK_SWIFT_UI_ACTOR
@@ -94,6 +104,42 @@
@param resumeData This data can be passed to WKWebView resumeDownloadFromResumeData: to attempt to resume this download.
*/
- (void)download:(WKDownload *)download didFailWithError:(NSError *)error resumeData:(nullable NSData *)resumeData;
+
+/* @abstract Invoked when the download needs a placeholder policy from the client.
+ @param download The download for which we need a placeholder policy
+ @param completionHandler The completion handler that should be invoked with the chosen policy.
+ If the client implements it's own placeholder, it can choose to provide an alternate placeholder
+ URL, which progress will be published against.
+ The download will not proceed until the completion handler is called.
+ @discussion The placeholder policy specifies whether a placeholder file should be created in
+ the Downloads directory when the download is in progress. This function is called after
+ the destination for the download has been decided, and before the download begins.
+ If the client opts into the placeholder feature, the system will create a placeholder file in
+ the Downloads directory, which is updated with the download's progress. When the download is
+ done, the placeholder file is replaced with the actual downloaded file. If the client opts
+ out of the placeholder feature, it can choose to provide a custom URL to publish progress
+ against. This is useful if the client maintains it's own placeholder file. If this delegate
+ is not implemented, the placeholder feature will be disabled.
+ */
+- (void)download:(WKDownload *)download decidePlaceholderPolicy:(WK_SWIFT_UI_ACTOR void (^)(WKDownloadPlaceholderPolicy, NSURL * _Nullable))completionHandler WK_SWIFT_ASYNC_NAME(placeholderPolicy(forDownload:)) API_AVAILABLE(ios(18.2), visionos(NA));
+
+/* @abstract Called when the download receives a placeholder URL
+ @param download The download for which we received a placeholder URL
+ @param completionHandler The completion handler that should be called by the client in response to this call.
+ The didReceiveFinalURL function will not be called until the completion handler has been called.
+ @discussion This function is called only if the client opted into the placeholder feature, and it is called
+ before receiving the final URL of the download. The placeholder URL will normally refer to a file in the
+ Downloads directory.
+ */
+- (void)download:(WKDownload *)download didReceivePlaceholderURL:(NSURL *)url completionHandler:(WK_SWIFT_UI_ACTOR void (^)(void))completionHandler API_AVAILABLE(ios(18.2), visionos(NA));
+
+/* @abstract Called when the download receives a final URL
+ @param download The download for which we received a final URL
+ @param url The URL of the final download location
+ @discussion This function is called after didReceivePlaceholderURL was called and after the download finished.
+ The final URL will normally refer to a file in the Downloads directory
+ */
+- (void)download:(WKDownload *)download didReceiveFinalURL:(NSURL *)url API_AVAILABLE(ios(18.2), visionos(NA));
@end
diff -ruN /Applications/Xcode_16.2.0-beta2.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/WebKit.framework/Headers/WKWebpagePreferences.h /Applications/Xcode_16.2.0-beta3.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/WebKit.framework/Headers/WKWebpagePreferences.h
--- /Applications/Xcode_16.2.0-beta2.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/WebKit.framework/Headers/WKWebpagePreferences.h 2024-10-31 08:42:04
+++ /Applications/Xcode_16.2.0-beta3.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/WebKit.framework/Headers/WKWebpagePreferences.h 2024-11-16 06:20:45
@@ -42,6 +42,22 @@
WKContentModeDesktop
} API_AVAILABLE(ios(13.0));
+/*! @enum WKWebpagePreferencesUpgradeToHTTPSPolicy
+ @abstract A secure navigation policy represents whether or not there is a
+ preference for loading a webpage with https, and how failures should be
+ handled.
+ @constant WKWebpagePreferencesUpgradeToHTTPSPolicyKeepAsRequested Maintains the current behavior without preferring https
+ @constant WKWebpagePreferencesUpgradeToHTTPSPolicyAutomaticFallbackToHTTP Upgrades http requests to https, and re-attempts the request with http on failure
+ @constant WKWebpagePreferencesUpgradeToHTTPSPolicyUserMediatedFallbackToHTTP Upgrades http requests to https, and shows a warning page on failure
+ @constant WKWebpagePreferencesUpgradeToHTTPSPolicyErrorOnFailure Upgrades http requests to https, and returns an error on failure
+ */
+typedef NS_ENUM(NSInteger, WKWebpagePreferencesUpgradeToHTTPSPolicy) {
+ WKWebpagePreferencesUpgradeToHTTPSPolicyKeepAsRequested,
+ WKWebpagePreferencesUpgradeToHTTPSPolicyAutomaticFallbackToHTTP,
+ WKWebpagePreferencesUpgradeToHTTPSPolicyUserMediatedFallbackToHTTP,
+ WKWebpagePreferencesUpgradeToHTTPSPolicyErrorOnFailure
+} NS_SWIFT_NAME(WKWebpagePreferences.UpgradeToHTTPSPolicy) API_AVAILABLE(macos(NA), ios(18.2), visionos(NA));
+
/*! A WKWebpagePreferences object is a collection of properties that
determine the preferences to use when loading and rendering a page.
@discussion Contains properties used to determine webpage preferences.
@@ -77,5 +93,14 @@
The default value depends on the system setting.
*/
@property (nonatomic, getter=isLockdownModeEnabled) BOOL lockdownModeEnabled API_AVAILABLE(macos(13.0), ios(16.0));
+
+/*! @abstract A WKWebpagePreferencesUpgradeToHTTPSPolicy indicating the desired mode
+ used when performing a top-level navigation to a webpage.
+ @discussion The default value is WKWebpagePreferencesUpgradeToHTTPSPolicyKeepAsRequested.
+ The stated preference is ignored on subframe navigation, and it may be ignored based on
+ system configuration. The upgradeKnownHostsToHTTPS property on WKWebViewConfiguration
+ supercedes this policy for known hosts.
+ */
+@property (nonatomic) WKWebpagePreferencesUpgradeToHTTPSPolicy preferredHTTPSNavigationPolicy API_AVAILABLE(macos(NA), ios(18.2), visionos(NA));
@end
- README
- xcode13.0 Binding Status
- xcode13.1 Binding Status
- xcode13.2 Binding Status
- xcode13.3 Binding Status
- xcode13.4 Binding Status
- xcode14.0 Binding Status
- xcode14.1 Binding Status
- xcode14.2 Binding Status
- xcode14.3 Binding Status
- xcode15.0 Binding Status
- xcode15.1 Binding Status
- xcode15.3 Binding Status
- xcode15.4 Binding Status
- xcode16.0 Binding Status
- xcode16.1 Binding Status
- xcode16.2 Binding Status