Skip to content

Commit e56f79c

Browse files
author
Kyle Kurz
committed
Recent calls setting
Mark Corner provided a nice PR previously that added this functionality, but then stopped working on the project and never rebased to allow it to merge. This just takes that work and applies it to the current tree so we can bring it inline.
1 parent 916cbce commit e56f79c

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,8 @@ RNCallKeep.setup(options).then(accepted => {});
6262
If provided, it will be displayed on system UI during the call
6363
- `ringtoneSound`: string (optional)
6464
If provided, it will be played when incoming calls received; the system will use the default ringtone if this is not provided
65+
- `includesCallsInRecents`: boolean (optional)
66+
If provided, calls will be shown in the recent calls when true and not when false (ios 11 and above)
6567
- `maximumCallGroups`: string (optional)
6668
If provided, the maximum number of call groups supported by this application (Default: 3)
6769
- `maximumCallsPerCallGroup`: string (optional)

ios/RNCallKeep/RNCallKeep.m

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -429,6 +429,11 @@ + (CXProviderConfiguration *)getProviderConfiguration:(NSDictionary*)settings
429429
if (settings[@"ringtoneSound"]) {
430430
providerConfiguration.ringtoneSound = settings[@"ringtoneSound"];
431431
}
432+
if (@available(iOS 11.0, *)) {
433+
if (_settings[@"includesCallsInRecents"]) {
434+
providerConfiguration.includesCallsInRecents = [_settings[@"includesCallsInRecents"] boolValue];
435+
}
436+
}
432437
return providerConfiguration;
433438
}
434439

0 commit comments

Comments
 (0)