Add notifiers for when the audio session will be activated/deactivated, did activate/deactivate and failed to activate/deactivate.

Bug: webrtc:9191
Change-Id: I68a71701dd4c3660331080495b5be4408493aa86
Reviewed-on: https://webrtc-review.googlesource.com/72262
Commit-Queue: JT Teh <jtteh@webrtc.org>
Reviewed-by: Kári Helgason <kthelgason@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23028}
This commit is contained in:
JT Teh
2018-04-25 09:19:35 -07:00
committed by Commit Bot
parent dc872b6be1
commit c1f083d143
2 changed files with 44 additions and 0 deletions

View File

@ -84,6 +84,20 @@ RTC_EXPORT
- (void)audioSession:(RTCAudioSession *)audioSession
didDetectPlayoutGlitch:(int64_t)totalNumberOfGlitches;
/** Called when the audio session is about to change the active state.
*/
- (void)audioSession:(RTCAudioSession *)audioSession willSetActive:(BOOL)active;
/** Called after the audio session sucessfully changed the active state.
*/
- (void)audioSession:(RTCAudioSession *)audioSession didSetActive:(BOOL)active;
/** Called after the audio session failed to change the active state.
*/
- (void)audioSession:(RTCAudioSession *)audioSession
failedToSetActive:(BOOL)active
error:(NSError *)error;
@end
/** This is a protocol used to inform RTCAudioSession when the audio session