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
Highlighted
Developer
Posts: 71
Registered: ‎06-26-2009
My Device: Curve 8310

Capture key during phone call

Hi,

 

I'm looking for a way to trigger a function in my background application (UiApplication that has been sent to the background) if the Space key is pressed during a phone call.

 

I know there's default behavior for it, but I'd like to override that somehow.

 

Any suggestions would be welcome.

 

Regards

 

Lionel

Give kudos if somebody helps you, also mark accepted if it solves your problem. Search first, then post. Please respect RFC-1855 when posting on forums.

BlackBerry Development Advisor
Posts: 15,723
Registered: ‎07-09-2008
My Device: BlackBerry PRIV
My Carrier: Bell

Re: Capture key during phone call

An application can only capture key events when it is in the foreground.  This means you wouldn't not be able to capture a key press made from within the phone application.  You could use the ApplicationMenuItem class to add a menu item to the phone application.

Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Problem solved? Click the Accept As Solution button.
Found a bug? Report it using Issue Tracker