BlackBerry Forums Support Community               

Closed Thread
 
LinkBack Thread Tools
Old 03-24-2009, 03:39 AM   #1 (permalink)
Thumbs Must Hurt
 
Join Date: Jan 2009
Model: 7100T
PIN: N/A
Carrier: -
Posts: 73
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default how to simulate key?

Please Login to Remove!

hi,

i know that there are functions which represents down and up positions of key-keyUp and keyDown. but they do not work as should. in api it is written that keyDown "Represents a constant indicating that the key is in the down position." but as i try to use it in my application, i realized that keyDown does not represent only a key in a down position but fully click- so down and up..

is there any way that i could simulate key in a down position?

kind regards
Offline  
Old 03-24-2009, 03:45 AM   #2 (permalink)
Thumbs Must Hurt
 
Join Date: Jan 2009
Model: 7100T
PIN: N/A
Carrier: -
Posts: 73
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

what i need to do is simulate shortcut of two keys pressed-> alt + arrow.

So, i must at first simulate alt in a down position, hold it, then simulate arrow click and then release alt key.

is there any chance i can do it?
Offline  
Old 03-24-2009, 07:59 AM   #3 (permalink)
Thumbs Must Hurt
 
Join Date: Jan 2009
Model: 7100T
PIN: N/A
Carrier: -
Posts: 73
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

it looks like such a code may work:

EventInjector.KeyCodeEvent _e = new EventInjector.KeyCodeEvent(
EventInjector.KeyCodeEvent.KEY_DOWN,
(char)Keypad.KEY_ESCAPE,
KeypadListener.STATUS_ALT,
500
);

_e.post();

but, when i'm in my application it works only as 'escape'. when i'm in foreground (main screen of my device) this code works as i wanted-as a shortcut of alt+escape(arrow).

Can anyone know why? how can i do that this shortcut works also in my application?

kind regards
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

Enerhy Savings T8 Ballast GEB 10 Instant Start
$4.99
Enerhy Savings T8 Ballast GEB 10 Instant Start pictureRADIONIC RT452ZTP BALLAST 120V/60Hz FOR (1) 14/16/20W STRAIGHT TRIGGER START
$14.25
RADIONIC RT452ZTP BALLAST 120V/60Hz FOR (1) 14/16/20W STRAIGHT TRIGGER START  pictureFLUORESCENT LIGHT BALLAST F96, F84, F72, F64, F60, or F48 stock #42
$0.01
FLUORESCENT LIGHT BALLAST F96, F84, F72, F64, F60, or F48 stock #42 pictureLutron H3dt540gu210 Electronic Fluorescent Dimming Ballast
$50.0
Lutron H3dt540gu210 Electronic Fluorescent Dimming Ballast pictureIcn4P32N 120-277V 4 Lamp T8 Electronic Ballast Electrical Ballasts
$1000.0
Icn4P32N 120-277V 4 Lamp T8 Electronic Ballast Electrical Ballasts picture






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