Skip to content

Disable native CC button in AVPlayerViewController during AirPlay - #6

Merged
Ludevv merged 1 commit into
ds-custom-forkfrom
disable-cc-button-during-airplay
Feb 24, 2026
Merged

Disable native CC button in AVPlayerViewController during AirPlay#6
Ludevv merged 1 commit into
ds-custom-forkfrom
disable-cc-button-during-airplay

Conversation

@Ludevv

@Ludevv Ludevv commented Feb 19, 2026

Copy link
Copy Markdown

Problem
When AirPlay is active, the user can change subtitle language both in the app (via the native CC button) and on the
AirPlay device, which can lead to conflicts. Subtitle selection should only be possible through the AirPlay device
controls (when AirPlay connected with non Apple devices).

Solution

  • Disable the native CC button in AVPlayerViewController when AirPlay is active
  • Restore the button when AirPlay disconnects
  • Find the CC button by matching the captions.bubble SF Symbol

Considerations

  • Apple does not provide a public API to selectively hide or disable the CC button in AVPlayerViewController.
  • On other Apple device works well

Demo:
non Apple device:

IMG_1346

with Apple device:

IMG_1347

@mobily mobily left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Ludevv
Ludevv merged commit bc4e797 into ds-custom-fork Feb 24, 2026
0 of 5 checks passed
@Ludevv
Ludevv deleted the disable-cc-button-during-airplay branch February 24, 2026 11:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants