iOS 10: How to show incoming VOIP call notification when app is in background?

前端 未结 2 1791
春和景丽
春和景丽 2020-12-06 21:07

I\'m working on audio/video call and trying to get incoming call notification loop for 1 minute like WhatsApp shows in iOS when app is

相关标签:
2条回答
  • 2020-12-06 21:43

    iOS 10 CallKit is much better, no more notification but system call UI, just like the native call. There are some sample codes at Github, which are easier to read than apple's Speakerbox sample.

    0 讨论(0)
  • 2020-12-06 21:54

    What I would suggest is that the local notification is only visible for that particular time. What you have to do is set a local notification or notification at the time of call. When the notification fires, in the delegate method of the notification you will have to build a custom logic with help of NSTimer.

    Create a view similar to push notification/ or view which you want to show for the call. Add it to the Application Window so it is shown on top of all views. After 3 sec remove this view and in the logic you can show the same view for 1 min.

    0 讨论(0)
提交回复
热议问题