From 749be04f11e1befabbed306790f783b2c9e208a4 Mon Sep 17 00:00:00 2001 From: Alexandr Viniychuk Date: Tue, 24 Apr 2018 10:57:52 -0400 Subject: [PATCH 1/5] save last uuid to fix End Call --- ios/RNCallKit/RNCallKit.m | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ios/RNCallKit/RNCallKit.m b/ios/RNCallKit/RNCallKit.m index fb6d793..b116149 100644 --- a/ios/RNCallKit/RNCallKit.m +++ b/ios/RNCallKit/RNCallKit.m @@ -30,6 +30,7 @@ @implementation RNCallKit NSMutableDictionary *_settings; NSOperatingSystemVersion _version; BOOL _isStartCallActionEventListenerAdded; + NSUUID *_lastUUID; } // should initialise in AppDelegate.m @@ -107,6 +108,7 @@ - (void)dealloc #endif int _handleType = [self getHandleType:handleType]; NSUUID *uuid = [[NSUUID alloc] initWithUUIDString:uuidString]; + _lastUUID = uuid; CXCallUpdate *callUpdate = [[CXCallUpdate alloc] init]; callUpdate.remoteHandle = [[CXHandle alloc] initWithType:_handleType value:handle]; callUpdate.supportsDTMF = YES; @@ -194,6 +196,7 @@ - (void)dealloc RCT_EXPORT_METHOD(reportConnectedOutgoingCallWithUUID:(NSString *)uuidString) { NSUUID *uuid = [[NSUUID alloc] initWithUUIDString:uuidString]; + _lastUUID = uuid; [self.callKitProvider reportOutgoingCallWithUUID:uuid connectedAtDate:[NSDate date]]; } From 75c4bcdac759c260de4092f9a343ed9966f99f76 Mon Sep 17 00:00:00 2001 From: Ivan Date: Wed, 25 Apr 2018 18:45:28 +0300 Subject: [PATCH 2/5] Update RNCallKit.m --- ios/RNCallKit/RNCallKit.m | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ios/RNCallKit/RNCallKit.m b/ios/RNCallKit/RNCallKit.m index b116149..0628a0c 100644 --- a/ios/RNCallKit/RNCallKit.m +++ b/ios/RNCallKit/RNCallKit.m @@ -303,7 +303,7 @@ - (void)configureAudioSession AVAudioSession* audioSession = [AVAudioSession sharedInstance]; [audioSession setCategory:AVAudioSessionCategoryPlayAndRecord error:nil]; - [audioSession setMode:AVAudioSessionModeVoiceChat error:nil]; + [audioSession setMode:AVAudioSessionModeVideoChat error:nil]; double sampleRate = 44100.0; [audioSession setPreferredSampleRate:sampleRate error:nil]; @@ -443,6 +443,7 @@ - (void)provider:(CXProvider *)provider performSetHeldCallAction:(CXSetHeldCallA #ifdef DEBUG NSLog(@"[RNCallKit][CXProviderDelegate][provider:performSetHeldCallAction]"); #endif + [action fulfill]; } - (void)provider:(CXProvider *)provider timedOutPerformingAction:(CXAction *)action From 28b66acadb5c3245493192699f23837496ac4d37 Mon Sep 17 00:00:00 2001 From: Ivan Tkachenko Date: Mon, 11 Jun 2018 16:02:29 +0300 Subject: [PATCH 3/5] Added includesinRecents option --- ios/RNCallKit/RNCallKit.m | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ios/RNCallKit/RNCallKit.m b/ios/RNCallKit/RNCallKit.m index 0628a0c..2e6b7c8 100644 --- a/ios/RNCallKit/RNCallKit.m +++ b/ios/RNCallKit/RNCallKit.m @@ -291,6 +291,11 @@ - (CXProviderConfiguration *)getProviderConfiguration if (_settings[@"ringtoneSound"]) { providerConfiguration.ringtoneSound = _settings[@"ringtoneSound"]; } + if (@available(iOS 11.0, *)) { + if (_settings[@"includesInRecents"]) { + providerConfiguration.includesCallsInRecents = [_settings[@"includesInRecents"] boolValue]; + } + } return providerConfiguration; } From 2345934a512d268cf1edf9ac8fa28430cfa05e06 Mon Sep 17 00:00:00 2001 From: Ivan Tkachenko Date: Mon, 11 Jun 2018 16:05:15 +0300 Subject: [PATCH 4/5] Updated versions to 1.3.3.1 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 9cc4618..008f747 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "react-native-callkit", - "version": "1.3.3", + "version": "1.3.3.1", "description": "iOS 10 CallKit Framework For React Native", "main": "index.js", "scripts": { From c291bd6c3b023e10738996f981d57dc288b39307 Mon Sep 17 00:00:00 2001 From: Ivan Tkachenko Date: Mon, 11 Jun 2018 16:06:52 +0300 Subject: [PATCH 5/5] Updated versions to 1.3.4 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 008f747..8eb61f0 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "react-native-callkit", - "version": "1.3.3.1", + "version": "1.3.4", "description": "iOS 10 CallKit Framework For React Native", "main": "index.js", "scripts": {