Title: [242746] trunk/Source/WebCore
Revision
242746
Author
[email protected]
Date
2019-03-11 15:31:14 -0700 (Mon, 11 Mar 2019)

Log Message

Soft linking to Reveal framework should be optional
https://bugs.webkit.org/show_bug.cgi?id=195576
<rdar://problem/46822452>

Reviewed by Megan Gardner.

Source/WebCore:

Systems exist with ENABLE(REVEAL) true and the Reveal framework does not exist.

* editing/cocoa/DictionaryLookup.mm:
(WebCore::showPopupOrCreateAnimationController):

Source/WebCore/PAL:

* pal/spi/cocoa/RevealSPI.h:

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (242745 => 242746)


--- trunk/Source/WebCore/ChangeLog	2019-03-11 22:15:51 UTC (rev 242745)
+++ trunk/Source/WebCore/ChangeLog	2019-03-11 22:31:14 UTC (rev 242746)
@@ -1,3 +1,16 @@
+2019-03-11  Alex Christensen  <[email protected]>
+
+        Soft linking to Reveal framework should be optional
+        https://bugs.webkit.org/show_bug.cgi?id=195576
+        <rdar://problem/46822452>
+
+        Reviewed by Megan Gardner.
+
+        Systems exist with ENABLE(REVEAL) true and the Reveal framework does not exist.
+
+        * editing/cocoa/DictionaryLookup.mm:
+        (WebCore::showPopupOrCreateAnimationController):
+
 2019-03-11  Yusuke Suzuki  <[email protected]>
 
         [JSC] Reduce # of structures in JSGlobalObject initialization

Modified: trunk/Source/WebCore/PAL/ChangeLog (242745 => 242746)


--- trunk/Source/WebCore/PAL/ChangeLog	2019-03-11 22:15:51 UTC (rev 242745)
+++ trunk/Source/WebCore/PAL/ChangeLog	2019-03-11 22:31:14 UTC (rev 242746)
@@ -1,3 +1,13 @@
+2019-03-11  Alex Christensen  <[email protected]>
+
+        Soft linking to Reveal framework should be optional
+        https://bugs.webkit.org/show_bug.cgi?id=195576
+        <rdar://problem/46822452>
+
+        Reviewed by Megan Gardner.
+
+        * pal/spi/cocoa/RevealSPI.h:
+
 2019-03-07  Andy Estes  <[email protected]>
 
         [Apple Pay] Untangle PKPaymentAuthorizationViewController from WebPaymentCoordinatorProxy

Modified: trunk/Source/WebCore/PAL/pal/spi/cocoa/RevealSPI.h (242745 => 242746)


--- trunk/Source/WebCore/PAL/pal/spi/cocoa/RevealSPI.h	2019-03-11 22:15:51 UTC (rev 242745)
+++ trunk/Source/WebCore/PAL/pal/spi/cocoa/RevealSPI.h	2019-03-11 22:31:14 UTC (rev 242746)
@@ -29,13 +29,6 @@
 #endif // PLATFORM(MAC)
 #import <wtf/SoftLinking.h>
 
-SOFT_LINK_PRIVATE_FRAMEWORK(Reveal)
-SOFT_LINK_PRIVATE_FRAMEWORK(RevealCore)
-SOFT_LINK_CLASS_OPTIONAL(Reveal, RVPresenter)
-SOFT_LINK_CLASS_OPTIONAL(Reveal, RVPresentingContext)
-SOFT_LINK_CLASS_OPTIONAL(RevealCore, RVItem)
-SOFT_LINK_CLASS_OPTIONAL(RevealCore, RVSelection)
-
 #if ENABLE(REVEAL)
 
 #if USE(APPLE_INTERNAL_SDK)

Modified: trunk/Source/WebCore/editing/cocoa/DictionaryLookup.mm (242745 => 242746)


--- trunk/Source/WebCore/editing/cocoa/DictionaryLookup.mm	2019-03-11 22:15:51 UTC (rev 242745)
+++ trunk/Source/WebCore/editing/cocoa/DictionaryLookup.mm	2019-03-11 22:31:14 UTC (rev 242746)
@@ -68,6 +68,15 @@
 
 #endif // PLATFORM(IOSMAC)
 
+#if ENABLE(REVEAL)
+SOFT_LINK_PRIVATE_FRAMEWORK_OPTIONAL(Reveal)
+SOFT_LINK_PRIVATE_FRAMEWORK_OPTIONAL(RevealCore)
+SOFT_LINK_CLASS_OPTIONAL(Reveal, RVPresenter)
+SOFT_LINK_CLASS_OPTIONAL(Reveal, RVPresentingContext)
+SOFT_LINK_CLASS_OPTIONAL(RevealCore, RVItem)
+SOFT_LINK_CLASS_OPTIONAL(RevealCore, RVSelection)
+#endif
+
 #if PLATFORM(MAC)
 
 @interface WebRevealHighlight <RVPresenterHighlightDelegate> : NSObject {
@@ -266,7 +275,7 @@
 {
     BEGIN_BLOCK_OBJC_EXCEPTIONS;
     
-    if (!getRVItemClass())
+    if (!RevealLibrary() || !RevealCoreLibrary() || !getRVItemClass())
         return { nullptr, nil };
     
     auto selectedRange = selection.toNormalizedRange();
@@ -301,7 +310,7 @@
 {
     BEGIN_BLOCK_OBJC_EXCEPTIONS;
     
-    if (!getRVItemClass())
+    if (!RevealLibrary() || !RevealCoreLibrary() || !getRVItemClass())
         return { nullptr, nil };
     
     auto* node = hitTestResult.innerNonSharedNode();
@@ -392,7 +401,7 @@
 {
     BEGIN_BLOCK_OBJC_EXCEPTIONS;
     
-    if (!getRVItemClass())
+    if (!RevealLibrary() || !RevealCoreLibrary() || !getRVItemClass())
         return { nullptr, nil };
 
     // Don't do anything if there is no character at the point.
@@ -436,7 +445,7 @@
     
 #if PLATFORM(MAC)
     
-    if (!getRVItemClass() || !getRVPresenterClass())
+    if (!RevealLibrary() || !RevealCoreLibrary() || !getRVItemClass() || !getRVPresenterClass())
         return nil;
 
     RetainPtr<NSMutableDictionary> mutableOptions = adoptNS([[NSMutableDictionary alloc] init]);
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to