You should set
self.player.appliesMediaSelectionCriteriaAutomatically = FALSE;
Instead of this, which is deprecated.
[self.player setClosedCaptionDisplayEnabled:enable];
By default, AVPlayer applies selection criteria based on system preferences. To override the default criteria for any media selection group, use -[AVPlayer setMediaSelectionCriteria:forMediaCharacteristic:].
EDIT
This method will be used:
@method setMediaSelectionCriteria:forMediaCharacteristic:
@abstract Applies automatic selection criteria for media that has the specified media characteristic.
@param criteria
An instance of AVPlayerMediaSelectionCriteria.
@param mediaCharacteristic
The media characteristic for which the selection criteria are to be applied. Supported values include AVMediaCharacteristicAudible, AVMediaCharacteristicLegible, and AVMediaCharacteristicVisual.
@discussion Criteria will be applied to an AVPlayerItem when:
a) It is made ready to play
b) Specific media selections are made by -[AVPlayerItem selectMediaOption:inMediaSelectionGroup:] in a different group. The automatic choice in one group may be influenced by a specific selection in another group.
c) Underlying system preferences change, e.g. system language, accessibility captions.
Specific selections made by -[AVPlayerItem selectMediaOption:inMediaSelectionGroup:] within any group will override automatic selection in that group until -[AVPlayerItem selectMediaOptionAutomaticallyInMediaSelectionGroup:] is received.
- (void)setMediaSelectionCriteria:(nullable AVPlayerMediaSelectionCriteria *)criteria
forMediaCharacteristic:(AVMediaCharacteristic)mediaCharacteristic
NS_AVAILABLE(10_9, 7_0);
Documentation for the same is here