Fix MACCATALYST build failures
authorpeng.liu6@apple.com <peng.liu6@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 22 Apr 2020 01:54:13 +0000 (01:54 +0000)
committerpeng.liu6@apple.com <peng.liu6@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 22 Apr 2020 01:54:13 +0000 (01:54 +0000)
https://bugs.webkit.org/show_bug.cgi?id=210815

Reviewed by Tim Horton.

Source/JavaScriptCore:

* Configurations/FeatureDefines.xcconfig:

Source/WebCore:

No new tests, no functional change.

* Configurations/FeatureDefines.xcconfig:
* platform/ios/WebVideoFullscreenControllerAVKit.mm:

Source/WebCore/PAL:

* Configurations/FeatureDefines.xcconfig:

Source/WebKit:

* Configurations/FeatureDefines.xcconfig:
* UIProcess/API/ios/WKWebViewIOS.mm:
(-[WKWebView _isShowingVideoPictureInPicture]):
(-[WKWebView _mayAutomaticallyShowVideoPictureInPicture]):
* UIProcess/ios/WebPageProxyIOS.mm:
(WebKit::WebPageProxy::applicationDidBecomeActive):

Source/WebKitLegacy/mac:

* Configurations/FeatureDefines.xcconfig:

Source/WTF:

* wtf/PlatformEnable.h:

Tools:

* TestWebKitAPI/Configurations/FeatureDefines.xcconfig:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@260486 268f45cc-cd09-0410-ab3c-d52691b4dbfc

17 files changed:
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/Configurations/FeatureDefines.xcconfig
Source/WTF/ChangeLog
Source/WTF/wtf/PlatformEnable.h
Source/WebCore/ChangeLog
Source/WebCore/Configurations/FeatureDefines.xcconfig
Source/WebCore/PAL/ChangeLog
Source/WebCore/PAL/Configurations/FeatureDefines.xcconfig
Source/WebCore/platform/ios/WebVideoFullscreenControllerAVKit.mm
Source/WebKit/ChangeLog
Source/WebKit/Configurations/FeatureDefines.xcconfig
Source/WebKit/UIProcess/API/ios/WKWebViewIOS.mm
Source/WebKit/UIProcess/ios/WebPageProxyIOS.mm
Source/WebKitLegacy/mac/ChangeLog
Source/WebKitLegacy/mac/Configurations/FeatureDefines.xcconfig
Tools/ChangeLog
Tools/TestWebKitAPI/Configurations/FeatureDefines.xcconfig

index 7895df6..cd9652e 100644 (file)
@@ -1,3 +1,12 @@
+2020-04-21  Peng Liu  <peng.liu6@apple.com>
+
+        Fix MACCATALYST build failures
+        https://bugs.webkit.org/show_bug.cgi?id=210815
+
+        Reviewed by Tim Horton.
+
+        * Configurations/FeatureDefines.xcconfig:
+
 2020-04-21  Keith Miller  <keith_miller@apple.com>
 
         JSC's options should be case insensitive
index 50318a4..b4f7879 100644 (file)
@@ -376,6 +376,7 @@ ENABLE_VIDEO_PRESENTATION_MODE = $(ENABLE_VIDEO_PRESENTATION_MODE_$(WK_PLATFORM_
 ENABLE_VIDEO_PRESENTATION_MODE_iphoneos = ENABLE_VIDEO_PRESENTATION_MODE;
 ENABLE_VIDEO_PRESENTATION_MODE_watchos = ENABLE_VIDEO_PRESENTATION_MODE;
 ENABLE_VIDEO_PRESENTATION_MODE_macosx = ENABLE_VIDEO_PRESENTATION_MODE;
+ENABLE_VIDEO_PRESENTATION_MODE_maccatalyst = ENABLE_VIDEO_PRESENTATION_MODE;
 
 ENABLE_VIDEO_TRACK = ENABLE_VIDEO_TRACK;
 
index 66e4b92..61afde5 100644 (file)
@@ -1,3 +1,12 @@
+2020-04-21  Peng Liu  <peng.liu6@apple.com>
+
+        Fix MACCATALYST build failures
+        https://bugs.webkit.org/show_bug.cgi?id=210815
+
+        Reviewed by Tim Horton.
+
+        * wtf/PlatformEnable.h:
+
 2020-04-19  Darin Adler  <darin@apple.com>
 
         [Cocoa] Use createNSArray in many more places that build NSArray objects from C++ collections
index ad6ff0e..f08df87 100644 (file)
 #define ENABLE_FULLSCREEN_API 0
 #endif
 
-#if ((PLATFORM(IOS) || PLATFORM(WATCHOS)) && HAVE(AVKIT)) || PLATFORM(MAC)
+#if ((PLATFORM(IOS) || PLATFORM(WATCHOS) || PLATFORM(MACCATALYST)) && HAVE(AVKIT)) || PLATFORM(MAC)
 #if !defined(ENABLE_VIDEO_PRESENTATION_MODE)
 #define ENABLE_VIDEO_PRESENTATION_MODE 1
 #endif
index 44ec699..d46d048 100644 (file)
@@ -1,3 +1,15 @@
+2020-04-21  Peng Liu  <peng.liu6@apple.com>
+
+        Fix MACCATALYST build failures
+        https://bugs.webkit.org/show_bug.cgi?id=210815
+
+        Reviewed by Tim Horton.
+
+        No new tests, no functional change.
+
+        * Configurations/FeatureDefines.xcconfig:
+        * platform/ios/WebVideoFullscreenControllerAVKit.mm:
+
 2020-04-19  Darin Adler  <darin@apple.com>
 
         [Cocoa] Use createNSArray in many more places that build NSArray objects from C++ collections
index 50318a4..b4f7879 100644 (file)
@@ -376,6 +376,7 @@ ENABLE_VIDEO_PRESENTATION_MODE = $(ENABLE_VIDEO_PRESENTATION_MODE_$(WK_PLATFORM_
 ENABLE_VIDEO_PRESENTATION_MODE_iphoneos = ENABLE_VIDEO_PRESENTATION_MODE;
 ENABLE_VIDEO_PRESENTATION_MODE_watchos = ENABLE_VIDEO_PRESENTATION_MODE;
 ENABLE_VIDEO_PRESENTATION_MODE_macosx = ENABLE_VIDEO_PRESENTATION_MODE;
+ENABLE_VIDEO_PRESENTATION_MODE_maccatalyst = ENABLE_VIDEO_PRESENTATION_MODE;
 
 ENABLE_VIDEO_TRACK = ENABLE_VIDEO_TRACK;
 
index 50ec279..8b2400e 100644 (file)
@@ -1,3 +1,12 @@
+2020-04-21  Peng Liu  <peng.liu6@apple.com>
+
+        Fix MACCATALYST build failures
+        https://bugs.webkit.org/show_bug.cgi?id=210815
+
+        Reviewed by Tim Horton.
+
+        * Configurations/FeatureDefines.xcconfig:
+
 2020-04-20  Peng Liu  <peng.liu6@apple.com>
 
         Fix build failures when video fullscreen and picture-in-picture is disabled
index 50318a4..b4f7879 100644 (file)
@@ -376,6 +376,7 @@ ENABLE_VIDEO_PRESENTATION_MODE = $(ENABLE_VIDEO_PRESENTATION_MODE_$(WK_PLATFORM_
 ENABLE_VIDEO_PRESENTATION_MODE_iphoneos = ENABLE_VIDEO_PRESENTATION_MODE;
 ENABLE_VIDEO_PRESENTATION_MODE_watchos = ENABLE_VIDEO_PRESENTATION_MODE;
 ENABLE_VIDEO_PRESENTATION_MODE_macosx = ENABLE_VIDEO_PRESENTATION_MODE;
+ENABLE_VIDEO_PRESENTATION_MODE_maccatalyst = ENABLE_VIDEO_PRESENTATION_MODE;
 
 ENABLE_VIDEO_TRACK = ENABLE_VIDEO_TRACK;
 
index fe8d6d0..7a9120f 100644 (file)
@@ -47,7 +47,7 @@
 
 using namespace WebCore;
 
-#if !HAVE(AVKIT)
+#if !(ENABLE(VIDEO_PRESENTATION_MODE) && HAVE(AVKIT))
 
 @implementation WebVideoFullscreenController
 - (void)setVideoElement:(NakedPtr<WebCore::HTMLVideoElement>)videoElement
index 06dd1cc..4e8d742 100644 (file)
@@ -1,3 +1,17 @@
+2020-04-21  Peng Liu  <peng.liu6@apple.com>
+
+        Fix MACCATALYST build failures
+        https://bugs.webkit.org/show_bug.cgi?id=210815
+
+        Reviewed by Tim Horton.
+
+        * Configurations/FeatureDefines.xcconfig:
+        * UIProcess/API/ios/WKWebViewIOS.mm:
+        (-[WKWebView _isShowingVideoPictureInPicture]):
+        (-[WKWebView _mayAutomaticallyShowVideoPictureInPicture]):
+        * UIProcess/ios/WebPageProxyIOS.mm:
+        (WebKit::WebPageProxy::applicationDidBecomeActive):
+
 2020-04-19  Darin Adler  <darin@apple.com>
 
         [Cocoa] Use createNSArray in many more places that build NSArray objects from C++ collections
index 50318a4..b4f7879 100644 (file)
@@ -376,6 +376,7 @@ ENABLE_VIDEO_PRESENTATION_MODE = $(ENABLE_VIDEO_PRESENTATION_MODE_$(WK_PLATFORM_
 ENABLE_VIDEO_PRESENTATION_MODE_iphoneos = ENABLE_VIDEO_PRESENTATION_MODE;
 ENABLE_VIDEO_PRESENTATION_MODE_watchos = ENABLE_VIDEO_PRESENTATION_MODE;
 ENABLE_VIDEO_PRESENTATION_MODE_macosx = ENABLE_VIDEO_PRESENTATION_MODE;
+ENABLE_VIDEO_PRESENTATION_MODE_maccatalyst = ENABLE_VIDEO_PRESENTATION_MODE;
 
 ENABLE_VIDEO_TRACK = ENABLE_VIDEO_TRACK;
 
index 5af17e6..9ac89ee 100644 (file)
@@ -177,25 +177,25 @@ static int32_t deviceOrientationForUIInterfaceOrientation(UIInterfaceOrientation
 
 - (BOOL)_isShowingVideoPictureInPicture
 {
-#if !HAVE(AVKIT)
-    return false;
-#else
+#if ENABLE(VIDEO_PRESENTATION_MODE)
     if (!_page || !_page->videoFullscreenManager())
         return false;
 
     return _page->videoFullscreenManager()->hasMode(WebCore::HTMLMediaElementEnums::VideoFullscreenModePictureInPicture);
+#else
+    return false;
 #endif
 }
 
 - (BOOL)_mayAutomaticallyShowVideoPictureInPicture
 {
-#if !HAVE(AVKIT)
-    return false;
-#else
+#if ENABLE(VIDEO_PRESENTATION_MODE)
     if (!_page || !_page->videoFullscreenManager())
         return false;
 
     return _page->videoFullscreenManager()->mayAutomaticallyShowVideoPictureInPicture();
+#else
+    return false;
 #endif
 }
 
index cde3c14..b922ee5 100644 (file)
@@ -741,7 +741,7 @@ void WebPageProxy::applicationWillEnterForegroundForMedia()
 
 void WebPageProxy::applicationDidBecomeActive()
 {
-#if HAVE(AVKIT)
+#if ENABLE(VIDEO_PRESENTATION_MODE)
     if (m_videoFullscreenManager)
         m_videoFullscreenManager->applicationDidBecomeActive();
 #endif
index 28e1c4a..e7e5afa 100644 (file)
@@ -1,3 +1,12 @@
+2020-04-21  Peng Liu  <peng.liu6@apple.com>
+
+        Fix MACCATALYST build failures
+        https://bugs.webkit.org/show_bug.cgi?id=210815
+
+        Reviewed by Tim Horton.
+
+        * Configurations/FeatureDefines.xcconfig:
+
 2020-04-19  Darin Adler  <darin@apple.com>
 
         [Cocoa] Use createNSArray in many more places that build NSArray objects from C++ collections
index 50318a4..b4f7879 100644 (file)
@@ -376,6 +376,7 @@ ENABLE_VIDEO_PRESENTATION_MODE = $(ENABLE_VIDEO_PRESENTATION_MODE_$(WK_PLATFORM_
 ENABLE_VIDEO_PRESENTATION_MODE_iphoneos = ENABLE_VIDEO_PRESENTATION_MODE;
 ENABLE_VIDEO_PRESENTATION_MODE_watchos = ENABLE_VIDEO_PRESENTATION_MODE;
 ENABLE_VIDEO_PRESENTATION_MODE_macosx = ENABLE_VIDEO_PRESENTATION_MODE;
+ENABLE_VIDEO_PRESENTATION_MODE_maccatalyst = ENABLE_VIDEO_PRESENTATION_MODE;
 
 ENABLE_VIDEO_TRACK = ENABLE_VIDEO_TRACK;
 
index e3bd23f..76b078f 100644 (file)
@@ -1,3 +1,12 @@
+2020-04-21  Peng Liu  <peng.liu6@apple.com>
+
+        Fix MACCATALYST build failures
+        https://bugs.webkit.org/show_bug.cgi?id=210815
+
+        Reviewed by Tim Horton.
+
+        * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
+
 2020-04-19  Darin Adler  <darin@apple.com>
 
         [Cocoa] Use createNSArray in many more places that build NSArray objects from C++ collections
index 50318a4..b4f7879 100644 (file)
@@ -376,6 +376,7 @@ ENABLE_VIDEO_PRESENTATION_MODE = $(ENABLE_VIDEO_PRESENTATION_MODE_$(WK_PLATFORM_
 ENABLE_VIDEO_PRESENTATION_MODE_iphoneos = ENABLE_VIDEO_PRESENTATION_MODE;
 ENABLE_VIDEO_PRESENTATION_MODE_watchos = ENABLE_VIDEO_PRESENTATION_MODE;
 ENABLE_VIDEO_PRESENTATION_MODE_macosx = ENABLE_VIDEO_PRESENTATION_MODE;
+ENABLE_VIDEO_PRESENTATION_MODE_maccatalyst = ENABLE_VIDEO_PRESENTATION_MODE;
 
 ENABLE_VIDEO_TRACK = ENABLE_VIDEO_TRACK;