Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: ada9edd4a1898e2870f3d09f50f1aefd3cbd039c
      
https://github.com/WebKit/WebKit/commit/ada9edd4a1898e2870f3d09f50f1aefd3cbd039c
  Author: Jean-Yves Avenard <j...@apple.com>
  Date:   2024-05-30 (Thu, 30 May 2024)

  Changed paths:
    M 
Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm
    M 
Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h
    M 
Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm
    M Source/WebCore/platform/ios/VideoPresentationInterfaceIOS.mm
    M Source/WebKit/UIProcess/WebPageProxy.cpp

  Log Message:
  -----------
  [visionOS] In Firefox, YouTube videos immediately exit full screen
https://bugs.webkit.org/show_bug.cgi?id=274458
rdar://127777214

Reviewed by Jer Noble.

The primary cause for fullscreen to immediately exit was a typo in the use of 
the PLATFORM
macro which caused requestHideAndExitFullscreen() to be immediately called once 
we had entered
fullscreen.
Then we had two issues that were revealed once the primary issue was fixed. 
When running in
iOS compatibility mode, once we entered fullscreen we would either remove the 
player from the
video layer (CRABS) or teardown the video layer (MSE).
To avoid this, we check if a FigVideoTargetRef is set, which indicate that the 
application
isn't running in iOS compatibility mode and a LMK isn't in use.

Manually tested MSE and CRABS, for both app in both native (Safari) and 
compatibility mode (Firefox)

* 
Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
* 
Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::acceleratedVideoMode const):
(WebCore::MediaPlayerPrivateAVFoundationObjC::isInFullscreenOrPictureInPictureChanged):
* 
Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::isInFullscreenOrPictureInPictureChanged):
* Source/WebCore/platform/ios/VideoPresentationInterfaceIOS.mm:
(WebCore::VideoPresentationInterfaceIOS::doSetup):
* Source/WebKit/UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::viewDidLeaveWindow): Fix typo and replace with 
PLATFORM(VISION). This caused to immediately
exit fullscreen as soon as we entered fullscreen.

Canonical link: https://commits.webkit.org/279558@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to