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

Web and WebWorks Development

Reply
New Contributor
jkdhenry
Posts: 2
Registered: ‎03-12-2012
My Device: 9700

Handling back key events when the screen is off

Hi,

 

I have encountered an issue with handling back key events when the screen is off.  This can be easily reproducible in the BBUISamples app and the KitchenSink sample app. In the BBUISamples app when the screen turns off and you press the back key, the event will be fired in the app either causing a screen to be popped or exiting the app. In the kitchen sink app when the screen turns off and the back key is pressed the app will remain on the same screen.

 

Now is there anyway to prevent the back key event from triggering within an app when the screen is off? Or would I have to build a javascript extension for the Java SystemListener2 backlightStateChange then perform the check within the app itself? Just seeing if there are other options before building the javascript extension.

 

Thanks