iOS 13 Incoming Call UI goes to Recents

梦想与她 提交于 2020-02-28 08:02:52

问题


I'm developing VoIP based audio call in my application. I have a strange issue for which I couldn't find a solution.

For iOS 13+ devices, sometimes incoming CallKit UI goes in Background. That means incoming CallKit UI doesn't show upfront, but I'm able to hear the call ringtone audio and vibration. When I double-tap on the Home button, I'm able to see my app with the IncomingCall UI in Recents. When I tap on it, it shows the CallKit UI and then I'm not able to move to other applications via double-tapping the home button.

It's inconsistently happening on iOS 13+ versions. Is there any way to show CallKit UI prominently while receiving incoming calls?

I'm using the method below to show an incoming call.

let update = CXCallUpdate()
update.remoteHandle = CXHandle(type: .generic, value: callObj.name ?? "")
update.hasVideo = false

provider.reportNewIncomingCall(with: newUUID, update: update) { error in

    if error == nil {
        let call = Call(uuid: newUUID, handle: callObj.name ?? "", roomID: self.callObj?.roomId ?? "")
        self.callManager.add(call: call)
    }

    completion?(error as NSError?)
}

来源:https://stackoverflow.com/questions/59840370/ios-13-incoming-call-ui-goes-to-recents

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!