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

  Changed paths:
    M Source/WebCore/platform/ios/PlaybackSessionInterfaceAVKitLegacy.mm
    M Source/WebCore/platform/ios/WebAVPlayerController.h
    M Source/WebCore/platform/ios/WebAVPlayerController.mm

  Log Message:
  -----------
  REGRESSION(306638@main): [iOS] Fullscreen mode cannot change caption language
rdar://169458486
https://bugs.webkit.org/show_bug.cgi?id=308275

Reviewed by Andy Estes.

In 306638@main, the "On" and "Auto" menu items were filtered out from the
list of media selection options given to AVPlayerController, however the
index used when those options were selected were not similarly adjusted,
so selecting the first language would result in the missing "On" menu item
being selected.

Instead of using the index of the filtered selection option, attach the index
of the original option as the WebAVMediaSelectionOption's "tag" property.
That tag can be read when the option is selected by AVKit and passed along
to the WebContent process as the original media selection option's index.

* Source/WebCore/platform/ios/PlaybackSessionInterfaceAVKitLegacy.mm:
(WebCore::mediaSelectionOptions):
(WebCore::mediaSelectionOptionWithTag):
(WebCore::PlaybackSessionInterfaceAVKitLegacy::audioMediaSelectionOptionsChanged):
(WebCore::PlaybackSessionInterfaceAVKitLegacy::legibleMediaSelectionOptionsChanged):
* Source/WebCore/platform/ios/WebAVPlayerController.h:
* Source/WebCore/platform/ios/WebAVPlayerController.mm:
(-[WebAVPlayerController setCurrentLegibleMediaSelectionOption:]):
(-[WebAVMediaSelectionOption 
initWithMediaType:displayName:extendedLanguageTag:tag:]):
(-[WebAVMediaSelectionOption copyWithZone:]):
(-[WebAVMediaSelectionOption 
initWithMediaType:displayName:extendedLanguageTag:]): Deleted.

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



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to