[Q] Change Function of Screenshot-Button on Dock - Asus Eee Pad Transformer Prime

Hi there,
I just got my Keyboard-Dock and saw the Screenshot-Button (above the '6').
Since I dont take very much Screenshots but read Mails often Im trying to change the buttons function.
in /system/usr/keylayout/asusdec.kl I found the following line:
Code:
key 212 CAPTURE WAKE UNLOCK
I think this line handles the Buttons function. I changed CAPTURE to MAIL and rebooted, but it did not work. I also tried changing it to E-MAIL....
Do you know what to insert inead of CAPTURE to open the MAIL-Program?

I just found this page explaining the android-keycodes:
http://developer.android.com/reference/android/view/KeyEvent.html
So you need to change the line like this:
Code:
key 212 ENVELOPE WAKE UNLOCK
After that, safe and reboot your tablet.
When you now press the key you can choose the Mail-Application to launch

Related

Remapping hardware keys

I was looking a way to remap the camera key to Toshiba settings through registry without having other progs like AEbutton Plus (which is not free btw) or other software running on the back. Found an article here, this method probably applies to all keys.
Made a shortcut of \Windows\settings.exe (shows only in totalcommander cause it's hidden) and put it in \Windows\AppButtons\settings.lnk (the folder probably doesn't mean anything).
In HKLM\Software\Microsoft\Shell\Keys you'll find 6 folders 40C1-6. Those correspond to the hardware buttons.
Camera key is the 40C3 folder. I didn't care to find which folder is vol up/down etc. but don't think many people will want to change the volume keys. The article explains some of the folder's contents:
1 HKLM\Software\Microsoft\Shell\Keys\40C3", (Default)
set it to point to the location of the program you want to start.
(e.g. \Windows\AppButoons\settings.lnk for my purpose)
2 HKLM\Software\Microsoft\Shell\Keys\40C3", "Flags"
set this to 0
3 HKLM\Software\Microsoft\Shell\Keys\40C3", "Name"
the name of this button, this is what you will see in Settings\Buttons
4 HKLM\Software\Microsoft\Shell\Keys\40C3", "Icon"
set it to point the location of your program again, or any other resource containing an icon (dll, exe file) so you will have a nice icon in the Settings\Buttons window.
That's it you're done. The program you've mapped opens with long press of the camera button. I don't know if and how you can change the short press action, If someone knows or finds out please let us know.
--------------------------
Hmm after posting I found out that when the phone is restarted the string "Flags" resets back to value 4 and the button doesn't launch the mapped app. Any thoughts?
a solution for this: http://forum.xda-developers.com/showthread.php?p=13028244#post13028244
enjoy
work well,thanks
work well,thanks
Jonous said:
I was looking a way to remap the camera key to Toshiba settings through registry without having other progs like AEbutton Plus (which is not free btw) or other software running on the back. Found an article here, this method probably applies to all keys.
Made a shortcut of \Windows\settings.exe (shows only in totalcommander cause it's hidden) and put it in \Windows\AppButtons\settings.lnk (the folder probably doesn't mean anything).
In HKLM\Software\Microsoft\Shell\Keys you'll find 6 folders 40C1-6. Those correspond to the hardware buttons.
Camera key is the 40C3 folder. I didn't care to find which folder is vol up/down etc. but don't think many people will want to change the volume keys. The article explains some of the folder's contents:
1 HKLM\Software\Microsoft\Shell\Keys\40C3", (Default)
set it to point to the location of the program you want to start.
(e.g. \Windows\AppButoons\settings.lnk for my purpose)
2 HKLM\Software\Microsoft\Shell\Keys\40C3", "Flags"
set this to 0
3 HKLM\Software\Microsoft\Shell\Keys\40C3", "Name"
the name of this button, this is what you will see in Settings\Buttons
4 HKLM\Software\Microsoft\Shell\Keys\40C3", "Icon"
set it to point the location of your program again, or any other resource containing an icon (dll, exe file) so you will have a nice icon in the Settings\Buttons window.
That's it you're done. The program you've mapped opens with long press of the camera button. I don't know if and how you can change the short press action, If someone knows or finds out please let us know.
--------------------------
Hmm after posting I found out that when the phone is restarted the string "Flags" resets back to value 4 and the button doesn't launch the mapped app. Any thoughts?
Click to expand...
Click to collapse
AE Button Plus can do this and is free now, i cannot get camera button to work on it in mirom8 but it definately can remap the soft buttons of the tg01
soft buttons, aebuttons should do it
hard buttons, only registry hacking, which this thread explains
for how to make the registry setting persistent, i gave a solution in a separate thread (check my post above for the link)

Assign a button to hang up!

I don't know about everyone else, but I've found that I instinctively want to push the home button on my phone when I want to end a call. It's burned me SOOOOO many times. I think it's funny how many Android devices seem to have their buttons mapped wrong! For example, I just bought a Coby Kyros 7015A tablet and it has a "rocker" style button on the top that just logically seems like it should be a volume up/down rocker, but for some odd reason they decided to assign "home" and "Menu" to the two sides of the rocker. In addition, the big silver button in the middle seems like it should logically be the Home button, but it is the back button instead.
After a little fiddling around with my Kyros tablet I discovered where the keymapping files are located:
Code:
/system/usr/keylayout/
there are two plain text files in this directory which need to be modified in order to make changes to keymapping, "qwerty.kl" and the other one is going to be named something to do with your particular device. You will need to edit them with a Unix compatible editor like Notepad++ on Window$, but Gedit or Kate will do just fine on Linux.
After successfully remapping the "back" button as "home" and the home/menu as volume up/down on my Kyros, I decided to tackle setting a button to hang up on my Optimus. Of course the first thing I did was make a backup in the recovery.
NOTE! This may not be a great idea for every ROM. Make sure that before you proceed, your ROM has "Spare Parts" and you can change the default behavior of the "end" button. The default behavior of the End button is to shut the screen off and it can not be changed on some ROMs.
This goes without saying, but you are editing files in /system/ so you will need to be rooted.
On the Optimus running CM7, the two files you need to edit are "qwerty.kl" and the other file is called "thunder_keypad.kl"
Code:
adb pull /system/usr/keylayout/
* make sure you put that last / at the end! it tells it to pull all of the files in the directory.
Editing these files is a pretty straightforward process. Basically, after you pull the files from your phone, you open the files and replace the instances of "HOME" with "ENDCALL". Save the files and push them back to the device, and then reboot. That's it!
Code:
adb push qwerty.kl /system/usr/keylayout/qwerty.kl
adb push thunder_keypad.kl /system/usr/keylayout/thunder_keypad.kl
adb reboot
Now you can hit the home button to hang up during a phone call instead of having to hit one of the hardware buttons to wake up the phone, which usually puts you at your homescreen or somewhere else just to have to get back into the phone call and hit the soft button hopefully before the screen goes black because of the proximity sensor (it's designed to do that!)
Like I had mentioned earlier, you're going to want to go into spare parts and change the default "End" button behavior to "Go to Home". Basically you remapped the end call button to where your home button is and then you're telling the Android OS that the end call button will emulate the normal behavior of the home button. Make sense? Didn't think so...
Works great on Mik's CM7. The only "bug" i've found so far is that when you're in the app drawer, hitting home doesn't take you back to your homescreen.
Here are my edited .kl files
Just in case you're really REALLY lazy and don't want to take the time to edit the files yourself (or if you don't have a Unix compatible editor)
Just remount and push them to /system/usr/keylayout/

[Q] Long-press home,search key and back

Hellou,
i spend much time with remaping hw buttons but still without succesfully. I try everything what i know and what i found here. In es209ra_keypad.kl are just normal buttons (non long-press). For search key may be there a key 217 but it isn´t there and when i added nothing happened. Search key is for me priority, becasue i want use it for CALL (exactly for Call log). In CM this works.I tried menu long press and it works for another app, but I can´t find there app Call log and why ? I don´t know...Search key long-press isn´t work for any apps...so have somebody idea how can I do that? Just touch for long search key and execute Call log no search and for short normal menu.
any idea??? developers please help

[Q] Remapping video or camera button?

I don't even have my Amaze yet, but one of the things I know I'm interested in is remapping the dedicated video button. I know I'll probably love the dedicated camera button, but I doubt I'll use the video button- mapping the button to either an app to it or a more useful function would be nice.
That said, has anyone decided to change the button functions and if so what did you use? What function did you give it?
I found a thread here that sounds like it could work except it makes a big deal out of needing "for full rooted devices. (NAND unlocked. Full, permanent write access to the system dir is needed)" and the functions it can provide don't seem all that helpful..
I did a fair amount of searching and couldn't find a better app, I'm not sure if the root the amaze has would be considered "full root", or if anyone here has really played with this.
check out Tasker from the market. It's basically a simple programming environment.
Think of it as writing a IF-THEN statements..
IF this THEN that....
IF i press the X button THEN open program y
If I press the Z button THEN send my girlfriend a text message with body of 'i just clicked my record button and it sent you a text message'
IF its 4o'clock on tuesday and i clicked the camera button then open angry birds
etc
etc
etc
jo093142 said:
check out Tasker from the market. It's basically a simple programming environment.
Think of it as writing a IF-THEN statements..
IF this THEN that....
IF i press the X button THEN open program y
If I press the Z button THEN send my girlfriend a text message with body of 'i just clicked my record button and it sent you a text message'
IF its 4o'clock on tuesday and i clicked the camera button then open angry birds
etc
etc
etc
Click to expand...
Click to collapse
Haha, you know, that really does seem like the simplest answer. I tried tasker but was a little frustrated that you had to manually follow steps to re-create the same function someone else has gotten, and there was nothing I wanted my phone to do I felt like was worth that kind of time investment.. but simple tasks like this it totally makes sense!(And just curious, did I miss something, and there was a way to copy someone's script/code into tasker rather than input it manually?)
Thanks for the idea, I'm definitely going to give it a try!
Edit: And I just noticed that you only have two posts, welcome to XDA! If by your second post you've already helped a semi-veteran, you're definitely going to be a great addition to the community
Silentbtdeadly said:
Haha, you know, that really does seem like the simplest answer. I tried tasker but was a little frustrated that you had to manually follow steps to re-create the same function someone else has gotten, and there was nothing I wanted my phone to do I felt like was worth that kind of time investment.. but simple tasks like this it totally makes sense!(And just curious, did I miss something, and there was a way to copy someone's script/code into tasker rather than input it manually?)
Thanks for the idea, I'm definitely going to give it a try!
Edit: And I just noticed that you only have two posts, welcome to XDA! If by your second post you've already helped a semi-veteran, you're definitely going to be a great addition to the community
Click to expand...
Click to collapse
been looking for the same thing, however I could find a camcorder button in Tasker, only the camera button.
bummer
mikeschevelle said:
been looking for the same thing, however I could find a camcorder button in Tasker, only the camera button.
bummer
Click to expand...
Click to collapse
I don't have the phone yet or I would already be playing with this, but I imagine you could remap the button to a key that tasker does support.
Of course back up the original file, then use adb(or even root explorer for such a small text edit) to pull/push adb pull /system/usr/keylayout/ruby-keypad.kl
You should see:
Code:
key 116 POWER WAKE_DROPPED
key 114 VOLUME_DOWN WAKE
key 115 VOLUME_UP WAKE
key 102 HOME
key 139 MENU
key 158 BACK
key 217 SEARCH
key 107 ENDCALL WAKE_DROPPED
# CAMCORDER
key 248 [B]CAMCORDER[/B] WAKE
# CAMERA
key 211 FOCUS
key 212 CAMERA WAKE
Change just the bolded part above that says CAMCORDER to something our phone doesn't have that tasker recognizes(I don't know what options it has, something like "DPAD_CENTER" might work)
At least that is the first thing I was going to try.
Silentbtdeadly said:
I don't have the phone yet or I would already be playing with this, but I imagine you could remap the button to a key that tasker does support.
Of course back up the original file, then use adb(or even root explorer for such a small text edit) to pull/push adb pull /system/usr/keylayout/ruby-keypad.kl
You should see:
Code:
key 116 POWER WAKE_DROPPED
key 114 VOLUME_DOWN WAKE
key 115 VOLUME_UP WAKE
key 102 HOME
key 139 MENU
key 158 BACK
key 217 SEARCH
key 107 ENDCALL WAKE_DROPPED
# CAMCORDER
key 248 [B]CAMCORDER[/B] WAKE
# CAMERA
key 211 FOCUS
key 212 CAMERA WAKE
Change just the bolded part above that says CAMCORDER to something our phone doesn't have that tasker recognizes(I don't know what options it has, something like "DPAD_CENTER" might work)
At least that is the first thing I was going to try.
Click to expand...
Click to collapse
.......appreciate it......over my head though

[Q] Using menu button to pick up call

Hi there. The topic says it all. Does there a way exist for me to use my menu button (the physical button) to pick up a call? I looked around in the settings, (I'm on ICS Final Mod, kevinlekiller's) couldn't find it.
Tried to look for it, but turned up empty handed. So, does it exist?
Nope it doesn't. Never heard of such a thing.
You can edit /system/usr/keylayout/sec_key.kl .
ketut.kumajaya said:
You can edit /system/usr/keylayout/sec_key.kl .
Click to expand...
Click to collapse
sec_key.kl is not present. The following files are present
Code:
AVRCP.kl
qwerty.kl
sec_touchscreen.kl
I looked around but it seems to me that remapping would change the keys behavior for the entire time, but the key mapping should change only when there is an incoming call.
Okay so there is no key state as such for picking up a call. The nearest key state being ENDCALL (ironically).
Code:
HOME #Launches "Home"
MENU #Launches "Menu"
BACK #Takes you back to the last activity
SEARCH #Launches "Universal Search"
CALL #Launches the "Phone" activity and corresponding .apk or initiates a call
ENDCALL #Ends a call
CAMERA #Launches "Camera" activity and corresponding .apk
FOCUS #Initiates Auto-Focus while using the Camera
VOLUME_UP #Self explanatory
VOLUME_DOWN #^
The above is from the here
In the above link, Decad3nce puts forward the idea of custom app launching inspired by BuglessPete's How to make script run by using hardware keys
After reading both, I think might be a way of enabling the menu key/home key to pick up a call.

Categories

Resources