callkit default UI for outgoing call - ios

I use outgoing call only in the app on iOS 10.3.3. If I do not have connected headphones to iPhone then pressing on lock button will end the call. But what if I have connected headphones?
Sometimes (after lock) I see native UI. Sometimes I see just time counter without any buttons (like speaker, mute, etc). Is there any special flag (or I should implement some delegate?) to allow see native callkit screen after pressing lock button? It looks like I tried everything here...
P.S. I know this screen could be showed while user take a call while iphone locked. But I would like (and I got it several times at least) to get this screen on lock device.
Did I miss something?

I hope that is the native iOS behaviour, callkit works similar to the native calls.
So customisation can't be done on call screens in lock mode.

Related

How to detect non-intrusive phone call

In iOS 14 you can now accept phone calls that do not take up the entire screen (the new non-intrusive phone call UI looks like a push notification). If you accept the call, but do not open up the full screen call UI, the app remains open. This is true even if you pick up the phone and put it to your ear the app remains active.
What would the best way be to detect an incoming call, or that the user began the call?
You can’t detect it. If the user just takes the call direct from the banner, your app remains active and there is nothing to detect. That is the whole point of this feature: a call need not interrupt your app in any way.

When to use native CallKit UI and when your own custom telephone UI?

I integrated CallKit successfully in my app, but I'm kind of confused how to use it correctly. When the phone is in locked state, I get the native Call UI like this:
When my app is in background and it receives an incoming call, the following interface I get:
By the way, after I accept the call, it opens my app and brings it to the foreground.
While I'm expecting the native Call UI (CallKit) to stay in the foreground when accepted the call.
However, if my app is brought to the foreground by CallKit, the native Call UI is not gone, but stays in memory. When I double press on the home button to get a list of opened apps, I can see the native Call UI as follows:
So the native Call UI is still there and I can get it to the foreground and control the call. So, what happens is, I get 2 UI's, one is the native Call UI and the other is my own app.
Also, the examples and demos I found about CallKit is confusing, because I only see native Call UI and no custom VoIP app UI. So what's the deal with Call UI? When should it be displayed and when should a custom app UI be displayed?
I know that it seems a bit confusing at first, but it's just the way it works. You don't have control on whether to show the system UI or your custom UI.
While the phone is ringing only the system UI is shown. As soon as you answer, if the phone is locked then the system UI is shown; if the phone is unlocked then your app will become active and your custom UI is shown.

CallKit: Launch app when screen is locked

I have implemented callkit to receive the VoIP notification.
On accept the call I am managing calls through another third party ForzenMountain which has my custom screen to show the status of calls.
1) When screen is not locked: Call comes then it shows two button. On accept it goes into the app itself and I can manage all.
Problem:
2) When screen is locked: It show another transition which has multiple option like (speaker/keypad/mute/addcall) rather than to go into app.
I need to land on my app even my device is locked (if passcode enable then ask to enter it) so that I can manage FM and my custom calls screen.
Unfortunately, there's no way to go directly into your app if the phone is locked. The system will only display the native CallKit UI and from there you can tap on the bottom right button to go into your app.

How to programmatically control iPhone or device speaker in iOS

I am creating a conference app for iOS 9, which makes a call. Once call is made it takes user to native iPhone screen. Later user can come back to our app to do various tasks, when call is running in background. We need to give a user option to control that iPhone speakers On/Off from our app itself.
But unfortunately, we are not able to find any document or sample on ths.
Kindly advice us how to achieve ths functionality.

Monodroid: wake application

How is it possible to wake the application from code?
I am writing a simple timer and when time goes out it displays picture on main activity. But this means that application should stay on screen all the time. If user switches to another app (or simply presses Home) my Activity is no longer visible and I need to show it on screen again (switch back to my application) in the way similar to standard Android Phone or Timer pops up.
So there actually are 2 questions:
How to get application on "top" of screen?
How to correctly display application when screen is locked?
For that you would need a service that starts your activity when that timer triggers.
You can take a look at the Android Alarm Clock source code for how to have an Activity Shown even on the lock screen: https://github.com/android/platform_packages_apps_alarmclock/blob/master/src/com/android/alarmclock/AlarmAlertFullScreen.java
Note especially lines 85 to 90, here flags are added so that it is allowed to be shown on the Lock Screen. This should of course work with Mono for Android as well.
There is also a nice answer here to your questions: Wake Android Device up
It should be fairly easy to port to Mono for Android.

Resources