Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: c1124e4e8f4c4e7282afba3960ac02126b1fa8fc
      
https://github.com/WebKit/WebKit/commit/c1124e4e8f4c4e7282afba3960ac02126b1fa8fc
  Author: Jer Noble <[email protected]>
  Date:   2024-02-23 (Fri, 23 Feb 2024)

  Changed paths:
    M Source/WebKit/UIProcess/ios/fullscreen/WKFullScreenWindowControllerIOS.mm

  Log Message:
  -----------
  [iOS] Flash of black while exiting fullscreen on youtube.com
https://bugs.webkit.org/show_bug.cgi?id=269969
rdar://117708957

Reviewed by Jean-Yves Avenard.

A single frame of black is sometimes shown when exiting fullscreen, after the 
fullscreen
animation completes, but before the WKWebView is visible in its full inline 
state.

Debugging shows this is due to the call to -makeKeyAndVisible in 
-_reinsertWebViewUnderPlaceholder.
It's not clear why making the WKWebView's parent window key and visible causes 
a black flash, but
it's also unnecessary at this point in the animation. Additionally, none of the 
operations in
-_completedExitFullScreen are wrapped in a CATransaction, so add one that 
commits once the
WKWebView has finished the repaint after re-inserting it in its original window.

Additionally, Safari will steal the WKWebView out of its fullscreen 
presentation during layout,
so long as -[WKFullScreenWindowController isFullScreen] returns false. So 
modify the meaning of
that property to include "WaitingToExit" and "ExitingFullscreen", preventing 
Safari from stealing
the view until the fullscreen animation completes.

* Source/WebKit/UIProcess/ios/fullscreen/WKFullScreenWindowControllerIOS.mm:
(-[WKFullScreenWindowController _reinsertWebViewUnderPlaceholder]):
(-[WKFullScreenWindowController _completedExitFullScreen]):

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



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

Reply via email to