且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

iOS 10:当应用程序在后台时如何显示传入的 VOIP 呼叫通知?

更新时间:2022-12-27 10:47:45

我的建议是本地通知仅在特定时间可见.您要做的是设置本地通知或通话时通知.当通知触发时,在通知的委托方法中,您必须在 NSTimer.

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.

创建一个类似于推送通知的视图/或要为呼叫显示的视图.将其添加到应用程序窗口,使其显示在所有视图的顶部.3 秒后移除此视图,在逻辑中您可以显示相同的视图 1 分钟.

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.