summaryrefslogtreecommitdiff
path: root/src/ios.m
diff options
context:
space:
mode:
Diffstat (limited to 'src/ios.m')
-rw-r--r--src/ios.m3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/ios.m b/src/ios.m
index b82d54a7..c493e4f9 100644
--- a/src/ios.m
+++ b/src/ios.m
@@ -264,7 +264,6 @@ void setupApplication_iOS(void) {
264 selector:@selector(keyboardOffScreen:) 264 selector:@selector(keyboardOffScreen:)
265 name:UIKeyboardWillHideNotification 265 name:UIKeyboardWillHideNotification
266 object:nil]; 266 object:nil];
267 [[AVAudioSession sharedInstance] setCategory:AVAudioSessionCategoryPlayback error:nil];
268 /* Media player remote controls. */ 267 /* Media player remote controls. */
269 MPRemoteCommandCenter *commandCenter = [MPRemoteCommandCenter sharedCommandCenter]; 268 MPRemoteCommandCenter *commandCenter = [MPRemoteCommandCenter sharedCommandCenter];
270 [[commandCenter pauseCommand] addTargetWithHandler:^MPRemoteCommandHandlerStatus(MPRemoteCommandEvent * _Nonnull event) { 269 [[commandCenter pauseCommand] addTargetWithHandler:^MPRemoteCommandHandlerStatus(MPRemoteCommandEvent * _Nonnull event) {
@@ -487,6 +486,8 @@ void init_AVFAudioPlayer(iAVFAudioPlayer *d) {
487 d->player = NULL; 486 d->player = NULL;
488 d->volume = 1.0f; 487 d->volume = 1.0f;
489 d->state = initialized_AVFAudioPlayerState; 488 d->state = initialized_AVFAudioPlayerState;
489 /* Playback is imminent. */
490 [[AVAudioSession sharedInstance] setCategory:AVAudioSessionCategoryPlayback error:nil];
490} 491}
491 492
492void deinit_AVFAudioPlayer(iAVFAudioPlayer *d) { 493void deinit_AVFAudioPlayer(iAVFAudioPlayer *d) {