how can I use keyevents in this app? Keyevents coming from this link for Jelly Bean. Thanks
http://grepcode.com/file/repository.grepcode.com/java/ext/com.google.android/android/4.1.1_r1/android/view/KeyEvent.java#KeyEvent
Edit: Nvm above. I got it figured out by editing manually /data/data/com.apedroid.hwkb../files/custom.txt. I was trying to map recent apps to one of the keyboard keys but using keycode 187 or 214 didnt work with CM10 Jelly Bean rom. So I got an idea but dunno if it is possible to get it to work with this app.
So here is the scenario.
As an alternative to using "input keyevent <code>", it is also possible to inject key press events and even choose the delay between the press and the release to simulate long presses using scripts.
Example for a HOME key long press:
Code:
sendevent /dev/input/event1 1 102 1
sendevent /dev/input/event1 0 0 0
usleep 500000
sendevent /dev/input/event1 1 102 0
sendevent /dev/input/event1 0 0 0
102 is the scan code for the HOME key and it will have a delay of 500ms between pressing and releasing.
Possible scan codes (for the physical buttons):
102 - Home
116 - Power
So, my point is. keycode for recent apps doesnt work with CM10 JB. And that there are keycodes that has to be hold to show for example holding power brings power options such as reboot shut down etc. Is there any way that we can execute/run this code/script for it to be able to be used with ext kb helper? Thanks
If there isn't then I suggest this to be a feature on the next release. Why? Because if the app can execute codes then theres no limit to what this app can execute. It can even execute services such as calling a number
"service call phone 2 s16 "123456789""
Toggling between the last 2 applications / windows and many more!