Answer an incoming phone call from my application

I want my application to answer phone calls, so I can be able to do some processing before allowing the user to answer, maybe just display my activity on InCallScreen, but I cannot do this. when I used aimFilter with <action android:name="android.intent.action.ANSWER"></action> when the incoming call is launched by InCallScreen and not my activity, and when using broadcastReciever with <action android:name="android.intent.action.PHONE_STATE"></action> I cannot use the abortBroadcast () method because it is non-standard broadcast.
Any help please

EDIT 1
I managed to show my activity on InCallScreen, wait 1 second before starting my activity on the onReceive broadcastReceiver method, but first InCallScreen will be displayed for some time, which can allow the user to respond before processing, and if I cut the time to wait, it may cause InCallScreen to appear above my activity. Any other solution would be appreciated.

+7
source share
1 answer

Check out the Droid Tedds Tools . It talks about programmatically answering calls. In particular, you want to see a part of the Features Readme.

+1
source

All Articles