Title: [278834] trunk/Source/WebCore
Revision
278834
Author
jbed...@apple.com
Date
2021-06-14 10:34:25 -0700 (Mon, 14 Jun 2021)

Log Message

[Monterey] Support building WebKit (Part 2)
https://bugs.webkit.org/show_bug.cgi?id=226846
<rdar://problem/79095148>

Reviewed by Chris Dumez.

Source/WebCore:

Covered by exisiting tests.

* html/HTMLElement.cpp:
(WebCore::HTMLElement::updateWithTextRecognitionResult): Explicitly define second arugment
to avoid 'missing field' compilation error.

Source/WebCore/PAL:

* pal/spi/cf/CFNetworkSPI.h: Add nw_connection_privacy_stance_t.
* pal/spi/cocoa/PassKitSPI.h: Add PKPaymentCoupon.

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (278833 => 278834)


--- trunk/Source/WebCore/ChangeLog	2021-06-14 17:31:02 UTC (rev 278833)
+++ trunk/Source/WebCore/ChangeLog	2021-06-14 17:34:25 UTC (rev 278834)
@@ -1,3 +1,17 @@
+2021-06-14  Jonathan Bedard  <jbed...@apple.com>
+
+        [Monterey] Support building WebKit (Part 2)
+        https://bugs.webkit.org/show_bug.cgi?id=226846
+        <rdar://problem/79095148>
+
+        Reviewed by Chris Dumez.
+
+        Covered by exisiting tests.
+
+        * html/HTMLElement.cpp:
+        (WebCore::HTMLElement::updateWithTextRecognitionResult): Explicitly define second arugment
+        to avoid 'missing field' compilation error.
+
 2021-06-14  Chris Dumez  <cdu...@apple.com>
 
         Micro-optimize ResourceResponseBase::sanitizeHTTPHeaderFields()

Modified: trunk/Source/WebCore/PAL/ChangeLog (278833 => 278834)


--- trunk/Source/WebCore/PAL/ChangeLog	2021-06-14 17:31:02 UTC (rev 278833)
+++ trunk/Source/WebCore/PAL/ChangeLog	2021-06-14 17:34:25 UTC (rev 278834)
@@ -1,3 +1,14 @@
+2021-06-14  Jonathan Bedard  <jbed...@apple.com>
+
+        [Monterey] Support building WebKit (Part 2)
+        https://bugs.webkit.org/show_bug.cgi?id=226846
+        <rdar://problem/79095148>
+
+        Reviewed by Chris Dumez.
+
+        * pal/spi/cf/CFNetworkSPI.h: Add nw_connection_privacy_stance_t.
+        * pal/spi/cocoa/PassKitSPI.h: Add PKPaymentCoupon.
+
 2021-06-11  Wenson Hsieh  <wenson_hs...@apple.com>
 
         [Cocoa] Clean up some VisionKitCore soft linking code in WebKit

Modified: trunk/Source/WebCore/PAL/pal/spi/cf/CFNetworkSPI.h (278833 => 278834)


--- trunk/Source/WebCore/PAL/pal/spi/cf/CFNetworkSPI.h	2021-06-14 17:31:02 UTC (rev 278833)
+++ trunk/Source/WebCore/PAL/pal/spi/cf/CFNetworkSPI.h	2021-06-14 17:34:25 UTC (rev 278834)
@@ -122,6 +122,16 @@
     CFHTTPCookieStorageAcceptPolicyExclusivelyFromMainDocumentDomain = 3,
 };
 
+#if HAVE(NETWORK_CONNECTION_PRIVACY_STANCE)
+typedef enum {
+    nw_connection_privacy_stance_unknown = 0,
+    nw_connection_privacy_stance_not_eligible = 1,
+    nw_connection_privacy_stance_proxied = 2,
+    nw_connection_privacy_stance_failed = 3,
+    nw_connection_privacy_stance_direct = 4,
+} nw_connection_privacy_stance_t;
+#endif
+
 #if defined(__OBJC__)
 
 @interface NSURLSessionTask ()

Modified: trunk/Source/WebCore/PAL/pal/spi/cocoa/PassKitSPI.h (278833 => 278834)


--- trunk/Source/WebCore/PAL/pal/spi/cocoa/PassKitSPI.h	2021-06-14 17:31:02 UTC (rev 278833)
+++ trunk/Source/WebCore/PAL/pal/spi/cocoa/PassKitSPI.h	2021-06-14 17:34:25 UTC (rev 278834)
@@ -132,6 +132,10 @@
     PKPaymentShippingContactInvalidError = 1,
     PKPaymentBillingContactInvalidError,
     PKPaymentShippingAddressUnserviceableError,
+#if HAVE(PASSKIT_COUPON_CODE)
+    PKPaymentCouponCodeInvalidError,
+    PKPaymentCouponCodeExpiredError,
+#endif
 };
 
 typedef NS_OPTIONS(NSUInteger, PKAddressField) {
@@ -242,11 +246,29 @@
 @property (nonatomic, copy) NSDecimalNumber *amount;
 @end
 
+#if HAVE(PASSKIT_SHIPPING_METHOD_DATE_COMPONENTS_RANGE)
+@interface PKDateComponentsRange : NSObject <NSCopying, NSSecureCoding>
+- (nullable instancetype)initWithStartDateComponents:(NSDateComponents *)startDateComponents endDateComponents:(NSDateComponents *)endDateComponents;
+@property (copy, readonly, nonatomic) NSDateComponents *startDateComponents;
+@property (copy, readonly, nonatomic) NSDateComponents *endDateComponents;
+@end
+#endif
+
 @interface PKShippingMethod : PKPaymentSummaryItem
 @property (nonatomic, copy, nullable) NSString *identifier;
 @property (nonatomic, copy, nullable) NSString *detail;
+#if HAVE(PASSKIT_SHIPPING_METHOD_DATE_COMPONENTS_RANGE)
+@property (nonatomic, copy, nullable) PKDateComponentsRange *dateComponentsRange;
+#endif
 @end
 
+#if HAVE(PASSKIT_SHIPPING_CONTACT_EDITING_MODE)
+typedef NS_ENUM(NSUInteger, PKShippingContactEditingMode) {
+    PKShippingContactEditingModeEnabled = 1,
+    PKShippingContactEditingModeStorePickup
+};
+#endif
+
 @interface PKPaymentRequest : NSObject
 + (NSArray<PKPaymentNetwork> *)availableNetworks;
 @property (nonatomic, copy) NSString *countryCode;
@@ -264,6 +286,16 @@
 @property (nonatomic, copy, nullable) NSSet<NSString *> *supportedCountries;
 @property (nonatomic, strong) NSSet<PKContactField> *requiredShippingContactFields;
 @property (nonatomic, strong) NSSet<PKContactField> *requiredBillingContactFields;
+
+#if HAVE(PASSKIT_COUPON_CODE)
+@property (nonatomic, assign) BOOL supportsCouponCode;
+@property (nonatomic, copy, nullable) NSString *couponCode;
+#endif
+
+#if HAVE(PASSKIT_SHIPPING_CONTACT_EDITING_MODE)
+@property (nonatomic, assign) PKShippingContactEditingMode shippingContactEditingMode;
+#endif
+
 @end
 
 @interface PKPaymentAuthorizationViewController : NSViewController
@@ -417,6 +449,10 @@
 @interface PKPaymentRequestUpdate : NSObject
 - (instancetype)initWithPaymentSummaryItems:(NSArray<PKPaymentSummaryItem *> *)paymentSummaryItems;
 @property (nonatomic, copy) NSArray<PKPaymentSummaryItem *> *paymentSummaryItems;
+#if HAVE(PASSKIT_COUPON_CODE)
+@property (nonatomic, copy) NSArray<PKShippingMethod *> *shippingMethods;
+#endif
+
 @end
 
 @interface PKPaymentRequestPaymentMethodUpdate : PKPaymentRequestUpdate
@@ -430,6 +466,12 @@
 @interface PKPaymentRequestShippingMethodUpdate : PKPaymentRequestUpdate
 @end
 
+#if HAVE(PASSKIT_COUPON_CODE)
+@interface PKPaymentRequestCouponCodeUpdate : PKPaymentRequestUpdate
+- (instancetype)initWithErrors:(nullable NSArray<NSError *> *)errors paymentSummaryItems:(NSArray<PKPaymentSummaryItem *> *)paymentSummaryItems shippingMethods:(NSArray<PKShippingMethod *> *)shippingMethods;
+@end
+#endif
+
 NS_ASSUME_NONNULL_END
 
 #endif

Modified: trunk/Source/WebCore/html/HTMLElement.cpp (278833 => 278834)


--- trunk/Source/WebCore/html/HTMLElement.cpp	2021-06-14 17:31:02 UTC (rev 278833)
+++ trunk/Source/WebCore/html/HTMLElement.cpp	2021-06-14 17:34:25 UTC (rev 278834)
@@ -1374,7 +1374,7 @@
                 continue;
 
             if (lineOrDataDetector.classList().contains(imageOverlayLineClass)) {
-                TextRecognitionLineElements lineElements { lineOrDataDetector };
+                TextRecognitionLineElements lineElements { lineOrDataDetector, { } };
                 for (auto& text : childrenOfType<HTMLDivElement>(lineOrDataDetector))
                     lineElements.children.append(text);
                 textRecognitionElements.lines.append(WTFMove(lineElements));
@@ -1427,7 +1427,7 @@
             auto lineContainer = HTMLDivElement::create(document());
             lineContainer->classList().add(imageOverlayLineClass);
             rootContainer->appendChild(lineContainer);
-            TextRecognitionLineElements lineElements { lineContainer };
+            TextRecognitionLineElements lineElements { lineContainer, { } };
             lineElements.children.reserveInitialCapacity(line.children.size());
             for (size_t childIndex = 0; childIndex < line.children.size(); ++childIndex) {
                 auto& child = line.children[childIndex];
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to