Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
New Developer
Posts: 3
Registered: ‎08-01-2010
My Device: Not Specified

Incoming Call Reject Notification

[ Edited ]

Hi,

I'm new to Blackberry development. I hope my question is not so trivial.

 

I want to develop a call management application. My application needs to monitor incoming call reject events. Unlike call blocker applications, I don't want to reject incoming calls automatically. Rather, I want my application to be triggerred when the user pressed the Reject button. Is it possible to different the scenarios?

  1. Calling user gave up ringing (disconnect).
  2. Called user rejected the call.

 

I tried the PhoneListener. I triggers the same callDisconnected method for both scenarios. I also tried PhoneCallLogListener. It also specifies the same missed call type for both scenario.

 

I also saw NotificationsManager. But I couldn't figure how to use the api, which sourceId / consequenceId to use.

 

Thanks,

Haldun ALIMLI
Developer
Posts: 4,764
Registered: ‎07-21-2008
My Device: Not Specified

Re: Incoming Call Reject Notification

There is no API to reject a call.

 

However, there is the "reject" or "ignore" button already on the call screen. Most folks use event injection to push the "redphone" key programmatically.

New Developer
Posts: 3
Registered: ‎08-01-2010
My Device: Not Specified

Re: Incoming Call Reject Notification

Hi RexDoug, thanks for your reply. But this does not answer my question. I don't want to reject the incoming call. Rather, somehow figure out the user rejected the incoming call.

Haldun ALIMLI
Developer
Posts: 4,764
Registered: ‎07-21-2008
My Device: Not Specified

Re: Incoming Call Reject Notification

OK -understand better now.

 

AFAIK, there is no way to detect this event. Only the app with focus can monitor the key pressess, In the case above, the phone app has the focus.

 

Maybe you can get *your* screen to come up over the phone app - not sure if this is possible, but I seem to recall several discussions along these lines on the forum.

 

 

 

 

Highlighted
Developer
Posts: 148
Registered: ‎11-16-2009
My Device: Not Specified

Re: Incoming Call Reject Notification

[ Edited ]

Hi

You can use the PhoneLogListener. When a call is added check if it is inbound or outbound call, and the duration, if it is inbound (PhoneCallLog.TYPE_RECEIVED_CALL) and the duration is 0 then it is a rejected call.

 

Edited: It behaves same to missed and rejected calls.