BlackBerry Forums Support Community               

Closed Thread
 
LinkBack Thread Tools
Old 07-19-2009, 06:32 PM   #1 (permalink)
Knows Where the Search Button Is
 
Join Date: Mar 2009
Location: Bilbao
Model: 8900
PIN: N/A
Carrier: Vodafone
Posts: 29
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default Backlight and key listener

Please Login to Remove!

Hi,

in my application i need to control every key pressed.

Everything is ok until the blackberry change the backlight state.
If the backlight is off and i press a key, my application can't intercept it (is the end key)

Any suggestion?

Thank
Offline  
Old 07-19-2009, 09:26 PM   #2 (permalink)
BlackBerry Extraordinaire
 
Join Date: Jan 2006
Model: LEZ10
OS: 10.0.10
Carrier: Rogers CA
Posts: 1,704
Post Thanks: 20
Thanked 77 Times in 68 Posts
Default

Your application will only be able to get key strokes when in the foreground. When the backlight is turned off the OS takes the foreground so the first keystroke can turn the light back on.
__________________
My other Blackberry is a PlayBook.
Offline  
Old 07-20-2009, 06:48 AM   #3 (permalink)
Knows Where the Search Button Is
 
Join Date: Mar 2009
Location: Bilbao
Model: 8900
PIN: N/A
Carrier: Vodafone
Posts: 29
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

thanks for answer!

yes, is it. But the problem is that the first key that i press when the bb is "obscured" is not consumed and bb use it.

I have my application in the top of stack when the "light turn off" and if i press the END char to "turn on the light", the system close the screen (as it must do if i don't intercept the event).
Is the only key that do it, the others doesn't do nothing (i think becouse i can intercept them)...

p.d. sorry for spanglish
Offline  
Old 07-20-2009, 07:39 AM   #4 (permalink)
BlackBerry Extraordinaire
 
Join Date: Jan 2006
Model: LEZ10
OS: 10.0.10
Carrier: Rogers CA
Posts: 1,704
Post Thanks: 20
Thanked 77 Times in 68 Posts
Default

You may find under certain circumstances that other keys do not get intercepted. The Start key for example when the phone is ringing.
__________________
My other Blackberry is a PlayBook.
Offline  
Old 07-20-2009, 08:49 AM   #5 (permalink)
Knows Where the Search Button Is
 
Join Date: Mar 2009
Location: Bilbao
Model: 8900
PIN: N/A
Carrier: Vodafone
Posts: 29
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default



this means that there aren't any solution?

The event must be generate and a listener must be listen for it...

Any idea?

Thank!!!
Offline  
Old 07-20-2009, 10:21 AM   #6 (permalink)
BlackBerry Extraordinaire
 
Join Date: Jan 2006
Model: LEZ10
OS: 10.0.10
Carrier: Rogers CA
Posts: 1,704
Post Thanks: 20
Thanked 77 Times in 68 Posts
Default

Re-examine the use you want to make of the buttons. Why do you want to remap the End Key function?
__________________
My other Blackberry is a PlayBook.
Offline  
Old 07-21-2009, 02:09 AM   #7 (permalink)
Knows Where the Search Button Is
 
Join Date: Mar 2009
Location: Bilbao
Model: 8900
PIN: N/A
Carrier: Vodafone
Posts: 29
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

In the application i have different user level.
One of them is a low privilege user, that can only use this.

To do this, i need that the application stay foreground ever (i know that is a little bit forced, but is the requirement ).

So, I need to control every key, and this is the only moment that i lost it.

And i think that is not so good that if I have an open application, when i can't see the content of display and I press a key, it disappear...

p.d. thank for help
Offline  
Old 07-21-2009, 07:57 AM   #8 (permalink)
BlackBerry Extraordinaire
 
Join Date: Jan 2006
Model: LEZ10
OS: 10.0.10
Carrier: Rogers CA
Posts: 1,704
Post Thanks: 20
Thanked 77 Times in 68 Posts
Default

Quote:
Originally Posted by egirotto View Post
In the application i have different user level.
One of them is a low privilege user, that can only use this.

To do this, i need that the application stay foreground ever (i know that is a little bit forced, but is the requirement ).
Blackberry OS does not have support for multiple users. Even if you could solve this problem (which I doubt), the security would be dubious at best.

However if you are required to go down this road, you could keep the device on, at the expense of increase battery usage. Read this article.
__________________
My other Blackberry is a PlayBook.

Last edited by hrbuckley : 07-21-2009 at 08:00 AM. Reason: Add KB article
Offline  
Old 07-21-2009, 12:49 PM   #9 (permalink)
Knows Where the Search Button Is
 
Join Date: Mar 2009
Location: Bilbao
Model: 8900
PIN: N/A
Carrier: Vodafone
Posts: 29
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
Blackberry OS does not have support for multiple users. Even if you could solve this problem (which I doubt), the security would be dubious at best.
is different thing, the multiple user is for application.
The bb is a work device and there are many people that use the same.
One is administrator of application, others are simple users.
When the application start ask for user and psw (of itself) and only if is an administrator, he can esc.

The problem of battery is a big problem, so i think that i need another solution.

Thank for help hrbuckley!
Offline  
Closed Thread


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On





Copyright 2004-2014 BlackBerryForums.com.
The names RIM and BlackBerry are registered Trademarks of BlackBerry Inc.