1
0
mirror of https://github.com/danog/Telegram.git synced 2024-12-12 09:29:55 +01:00
Telegram/Telegraph/TGAudioSessionManager.h
2015-10-01 19:19:52 +03:00

27 lines
656 B
Objective-C

#import <Foundation/Foundation.h>
#import <SSignalKit/SSignalKit.h>
typedef enum {
TGAudioSessionTypePlayVoice,
TGAudioSessionTypePlayMusic,
TGAudioSessionTypePlayVideo,
TGAudioSessionTypePlayAndRecord,
TGAudioSessionTypePlayAndRecordHeadphones
} TGAudioSessionType;
typedef enum {
TGAudioSessionRouteChangePause,
TGAudioSessionRouteChangeResume
} TGAudioSessionRouteChange;
@interface TGAudioSessionManager : NSObject
+ (TGAudioSessionManager *)instance;
- (id<SDisposable>)requestSessionWithType:(TGAudioSessionType)type interrupted:(void (^)())interrupted;
- (void)cancelCurrentSession;
+ (SSignal *)routeChange;
@end