Title: [233182] trunk/Source/WebCore
Revision
233182
Author
wenson_hs...@apple.com
Date
2018-06-25 16:54:25 -0700 (Mon, 25 Jun 2018)

Log Message

[iPad apps on macOS] Web process crashes when attempting to play embedded YouTube video in News
https://bugs.webkit.org/show_bug.cgi?id=187011
<rdar://problem/40906808>

Reviewed by Tim Horton.

Disable remote media commands when running iOS WebKit on macOS. The iOS flavor of RemoteCommandListener
currently throws an exception when attempting to soft-link the MediaPlayer framework, which prevents video from
being played altogether. For a followup tracking touch bar integration in iOS WebKit on macOS, see:
<rdar://problem/39164732>.

Manually tested by playing a YouTube video in News.

* platform/RemoteCommandListener.cpp:
* platform/ios/RemoteCommandListenerIOS.h:
* platform/ios/RemoteCommandListenerIOS.mm:

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (233181 => 233182)


--- trunk/Source/WebCore/ChangeLog	2018-06-25 23:40:52 UTC (rev 233181)
+++ trunk/Source/WebCore/ChangeLog	2018-06-25 23:54:25 UTC (rev 233182)
@@ -1,3 +1,22 @@
+2018-06-25  Wenson Hsieh  <wenson_hs...@apple.com>
+
+        [iPad apps on macOS] Web process crashes when attempting to play embedded YouTube video in News
+        https://bugs.webkit.org/show_bug.cgi?id=187011
+        <rdar://problem/40906808>
+
+        Reviewed by Tim Horton.
+
+        Disable remote media commands when running iOS WebKit on macOS. The iOS flavor of RemoteCommandListener
+        currently throws an exception when attempting to soft-link the MediaPlayer framework, which prevents video from
+        being played altogether. For a followup tracking touch bar integration in iOS WebKit on macOS, see:
+        <rdar://problem/39164732>.
+
+        Manually tested by playing a YouTube video in News.
+
+        * platform/RemoteCommandListener.cpp:
+        * platform/ios/RemoteCommandListenerIOS.h:
+        * platform/ios/RemoteCommandListenerIOS.mm:
+
 2018-06-25  Keith Rollin  <krol...@apple.com>
         Unreviewed, rolling out r233087.
 

Modified: trunk/Source/WebCore/platform/RemoteCommandListener.cpp (233181 => 233182)


--- trunk/Source/WebCore/platform/RemoteCommandListener.cpp	2018-06-25 23:40:52 UTC (rev 233181)
+++ trunk/Source/WebCore/platform/RemoteCommandListener.cpp	2018-06-25 23:54:25 UTC (rev 233182)
@@ -28,7 +28,7 @@
 
 namespace WebCore {
 
-#if !PLATFORM(IOS) && !PLATFORM(MAC)
+#if (!PLATFORM(IOS) && !PLATFORM(MAC)) || !HAVE(MEDIA_PLAYER)
 std::unique_ptr<RemoteCommandListener> RemoteCommandListener::create(RemoteCommandListenerClient& client)
 {
     return std::make_unique<RemoteCommandListener>(client);

Modified: trunk/Source/WebCore/platform/ios/RemoteCommandListenerIOS.h (233181 => 233182)


--- trunk/Source/WebCore/platform/ios/RemoteCommandListenerIOS.h	2018-06-25 23:40:52 UTC (rev 233181)
+++ trunk/Source/WebCore/platform/ios/RemoteCommandListenerIOS.h	2018-06-25 23:54:25 UTC (rev 233182)
@@ -27,7 +27,7 @@
 
 #include "RemoteCommandListener.h"
 
-#if PLATFORM(IOS)
+#if PLATFORM(IOS) && HAVE(MEDIA_PLAYER)
 
 #include <wtf/RetainPtr.h>
 #include <wtf/WeakPtr.h>
@@ -56,4 +56,4 @@
 
 }
 
-#endif // PLATFORM(IOS)
+#endif // PLATFORM(IOS) && HAVE(MEDIA_PLAYER)

Modified: trunk/Source/WebCore/platform/ios/RemoteCommandListenerIOS.mm (233181 => 233182)


--- trunk/Source/WebCore/platform/ios/RemoteCommandListenerIOS.mm	2018-06-25 23:40:52 UTC (rev 233181)
+++ trunk/Source/WebCore/platform/ios/RemoteCommandListenerIOS.mm	2018-06-25 23:54:25 UTC (rev 233182)
@@ -26,7 +26,7 @@
 #import "config.h"
 #import "RemoteCommandListenerIOS.h"
 
-#if PLATFORM(IOS)
+#if PLATFORM(IOS) && HAVE(MEDIA_PLAYER)
 
 #import <MediaPlayer/MPRemoteCommand.h>
 #import <MediaPlayer/MPRemoteCommandCenter.h>
@@ -151,4 +151,4 @@
 
 }
 
-#endif // PLATFORM(IOS)
+#endif // PLATFORM(IOS) && HAVE(MEDIA_PLAYER)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to