forked from react-native-webrtc/react-native-incall-manager
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.d.ts
64 lines (41 loc) · 1.34 KB
/
index.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
declare class InCallManager {
vibrate: boolean;
audioUriMap: {
ringtone: { _BUNDLE_: null; _DEFAULT_: null };
ringback: { _BUNDLE_: null; _DEFAULT_: null };
busytone: { _BUNDLE_: null; _DEFAULT_: null };
};
constructor();
start(setup?: {
auto?: boolean;
media?: "video" | "audio";
ringback?: string;
}): void;
stop(setup?: { busytone?: string }): void;
turnScreenOff(): void;
turnScreenOn(): void;
getIsWiredHeadsetPluggedIn(): Promise<{ isWiredHeadsetPluggedIn: boolean }>;
setFlashOn(enable: boolean, brightness: number): void;
setKeepScreenOn(enable: boolean): void;
setSpeakerphoneOn(enable: boolean): void;
setForceSpeakerphoneOn(flag: boolean): void;
setMicrophoneMute(enable: boolean): void;
startRingtone(
ringtone: string,
vibrate_pattern: number | number[],
ios_category: string,
seconds: number
): void;
stopRingtone(): void;
startProximitySensor(): void;
stopProximitySensor(): void;
startRingback(ringback: string): void;
stopRingback(): void;
pokeScreen(timeout: number): void;
getAudioUri(audioType: string, fileType: string): Promise<string | null>;
chooseAudioRoute(route: string): Promise<any>;
requestAudioFocus(): Promise<any>;
abandonAudioFocus(): Promise<any>;
}
declare const inCallManager: InCallManager;
export default inCallManager;