Attend XDA's Second Annual Developer Conference, XDA:DevCon 2014!
5,728,832 Members 50,869 Now Online
XDA Developers Android and Mobile Development Forum

[Q] Mapping Camera on the back key

Tip us?
 
vbetts
Old
(Last edited by vbetts; 3rd April 2014 at 07:42 PM.)
#1  
vbetts's Avatar
Senior Member - OP
Thanks Meter 53
Posts: 975
Join Date: Jun 2010
Location: Toledo Ohio
Default [Q] Mapping Camera on the back key

I'm doing a few tweaks on my phone, mainly not using the capacitive keys as menu and back, and using the home key as the app switcher, and using the nav bar for those three tasks. Here's what I've got so far.

I edited a few files under system/usr/keylayout

The Menu and Search key layouts were found under sec_touchkey.kl(Home was also found under this, but I had to also edit sec_keys.kl and sec_key.kl to get the home key as the app switcher)

Here's the default settings.

key 139 MENU VIRTUAL
key 158 BACK VIRTUAL
key 102 HOME
key 217 SEARCH

Here's what I set them to.

key 139 CALL VIRTUAL
key 158 CAMERA VIRTUAL
key 102 APP_SWITCH
key 217 SEARCH

Changing the roles of keys 139 and 102 worked, but Camera does not open the camera. I've tried assigning different roles to key 158 and they've worked except for the camera role. So I'm thinking CAMERA is not the correct event name to open the camera up....

http://developer.android.com/referen...KEYCODE_CAMERA

That's where I got the keyEvent listings from.

Rom is in my signature.
xdadevelopers
Samsung Galaxy S3 i747
-AOSB 1.3.1 Kitkat 4.4.2
-3.4.79 cyanogenmod kernel
 
vbetts
Old
#2  
vbetts's Avatar
Senior Member - OP
Thanks Meter 53
Posts: 975
Join Date: Jun 2010
Location: Toledo Ohio
Bump!
xdadevelopers
Samsung Galaxy S3 i747
-AOSB 1.3.1 Kitkat 4.4.2
-3.4.79 cyanogenmod kernel
 
vbetts
Old
#3  
vbetts's Avatar
Senior Member - OP
Thanks Meter 53
Posts: 975
Join Date: Jun 2010
Location: Toledo Ohio
Help me out here guys!
xdadevelopers
Samsung Galaxy S3 i747
-AOSB 1.3.1 Kitkat 4.4.2
-3.4.79 cyanogenmod kernel
 
vbetts
Old
#4  
vbetts's Avatar
Senior Member - OP
Thanks Meter 53
Posts: 975
Join Date: Jun 2010
Location: Toledo Ohio
I'm just gonna keep bumping every day.
xdadevelopers
Samsung Galaxy S3 i747
-AOSB 1.3.1 Kitkat 4.4.2
-3.4.79 cyanogenmod kernel
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


XDA PORTAL POSTS

MaR-V-iN to Talk Google and Android APIs at XDA:DevCon 2014

Our international xda:devcon 14in Manchester, UK on the weekend of September … more

But First, Let Me Take a #Selfie

“Today while browsing XDA,I’m going tocheck to seeif my favorite ROM has been updated–but … more

Easily Combine Text and Manage Your Android Clipboard with StuffMerge

Android clipboard management has always been impractical without the … more