mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-05-29 04:21:03 +08:00
coreaudio: Patched to compile, again, on iOS.
This commit is contained in:
@@ -406,7 +406,6 @@ static bool UpdateAudioSession(SDL_AudioDevice *device, bool open, bool allow_pl
|
|||||||
{
|
{
|
||||||
@autoreleasepool {
|
@autoreleasepool {
|
||||||
AVAudioSession *session = [AVAudioSession sharedInstance];
|
AVAudioSession *session = [AVAudioSession sharedInstance];
|
||||||
NSNotificationCenter *center = [NSNotificationCenter defaultCenter];
|
|
||||||
|
|
||||||
NSString *category = AVAudioSessionCategoryPlayback;
|
NSString *category = AVAudioSessionCategoryPlayback;
|
||||||
NSString *mode = AVAudioSessionModeDefault;
|
NSString *mode = AVAudioSessionModeDefault;
|
||||||
@@ -984,7 +983,7 @@ static bool COREAUDIO_OpenDevice(SDL_AudioDevice *device)
|
|||||||
[center addObserver:listener
|
[center addObserver:listener
|
||||||
selector:@selector(audioSessionInterruption:)
|
selector:@selector(audioSessionInterruption:)
|
||||||
name:AVAudioSessionInterruptionNotification
|
name:AVAudioSessionInterruptionNotification
|
||||||
object:session];
|
object:[AVAudioSession sharedInstance]];
|
||||||
|
|
||||||
/* An interruption end notification is not guaranteed to be sent if
|
/* An interruption end notification is not guaranteed to be sent if
|
||||||
we were previously interrupted... resuming if needed when the app
|
we were previously interrupted... resuming if needed when the app
|
||||||
|
|||||||
Reference in New Issue
Block a user