FORUMS

OnePlus Addresses Reservation List Cheating

Jake Cooper figured out how to bump his place up on OnePlus’ reservation list and … more

OnePlus 2 Benchmark Scores Show Its Muscle

This video by FoneArena contains all the popular benchmarks being tested on the OnePlus 2, … more

Sony’s Emergence in The Middle: Is The Price Right?

Sony’s Electronics Division is not in its best days, and its smartphone … more

HTC Delivering Ads Straight to Sense Home

HTC’s 2015 has been a year marked by a desperate search for revenue.The HTC One M9 … more

Remapping the Physical Buttons

433 posts
Thanks Meter: 81
 
By idiotzach15, Senior Member on 13th February 2013, 05:29 AM
Post Reply Subscribe to Thread Email Thread
well, recently I've been trying to remap the softkeys on the note II, and I'm just not making progress. My goal is to create a small mod that turns the softkey lights off, and remaps the menu key for the back key, and the back key to recents, as well as somehow changing the home button longpress to a google now shortcut.

After doing some research, I figured changing the Generic.kl (/system/usr/keylayout/) lines 139 and 158 would make progress. However, all I've accomplished so far is disabling the softkeys.

Any help or information on this subject would be greatly appreciated.

Thanks in advance.


- and yes, I tried the ButtonRemapper apk
The Following User Says Thank You to idiotzach15 For This Useful Post: [ View ]
 
 
13th February 2013, 04:43 PM |#2  
Senior Member
Thanks Meter: 315
 
More
Re: Remapping the Physical Buttons
I made this file months ago, and it's worked on every TW rom I've had, since I HATE the backwards button layout Samsung chose. Download this file, go to your /system/usr/keylayout folder, rename your existing sec_touchkey.kl to sec_touchkey.kl.bak, then move the file I gave you into that folder. Set permissions and reboot, and you'll have the setup you want.

Obviously, just turn the backlights off in the Display settings. Do note that you won't have a menu button after you do this, I just use Button Savior to put a little shortcut off to the side. But if you come up with a more elegant solution, please feel free to let me know.

That file should do what you want, all I ask is that you credit me if you share it with anyone, put it in a rom, or whatever.

http://db.tt/RzSutNxL

Sent from my SCH-I535 using Tapatalk 2
The Following 3 Users Say Thank You to Cruiserdude For This Useful Post: [ View ]
13th February 2013, 05:37 PM |#3  
OP Senior Member
Thanks Meter: 81
 
More
Quote:
Originally Posted by Cruiserdude

I made this file months ago, and it's worked on every TW rom I've had, since I HATE the backwards button layout Samsung chose. Download this file, go to your /system/usr/keylayout folder, rename your existing sec_touchkey.kl to sec_touchkey.kl.bak, then move the file I gave you into that folder. Set permissions and reboot, and you'll have the setup you want.

Obviously, just turn the backlights off in the Display settings. Do note that you won't have a menu button after you do this, I just use Button Savior to put a little shortcut off to the side. But if you come up with a more elegant solution, please feel free to let me know.

That file should do what you want, all I ask is that you credit me if you share it with anyone, put it in a rom, or whatever.

http://db.tt/RzSutNxL

Sent from my SCH-I535 using Tapatalk 2

Thanks a bunch!
13th February 2013, 06:41 PM |#4  
OP Senior Member
Thanks Meter: 81
 
More
Quote:
Originally Posted by idiotzach15

Thanks a bunch!

I'll be creating a flash zip for this "fix" soon. Does anyone know where I'd change the longpress on the homebutton action?
16th February 2013, 05:36 PM |#5  
elesbb's Avatar
Senior Member
Thanks Meter: 4,697
 
Donate to Me
More
Quote:
Originally Posted by idiotzach15

I'll be creating a flash zip for this "fix" soon. Does anyone know where I'd change the longpress on the homebutton action?

/system/framework/android.policy.jar/PhoneWindowManager.java

At leasts thats what i can remember lol. Thats what i had to edit on my Tablet to make long press on home function as long press search.
16th February 2013, 10:23 PM |#6  
Senior Member
Thanks Meter: 315
 
More
Re: Remapping the Physical Buttons
Yeah, I'd love to find a way to enable a long press of the right hand capacitive button (back button stock, but it's the task switcher with that file I posted) to act as a menu button. That would be awesome.

Alternatively, I'd love to figure out how to change the TW soft keys to AOSP theme and layout. I love using soft keys, but I can't stand the backwards layout Samsung has chosen, and can't bring myself to using it if I can help it.

Sent from my SCH-I535 using Tapatalk 2
17th February 2013, 03:10 AM |#7  
elesbb's Avatar
Senior Member
Thanks Meter: 4,697
 
Donate to Me
More
Re: Remapping the Physical Buttons
Quote:
Originally Posted by Cruiserdude

Yeah, I'd love to find a way to enable a long press of the right hand capacitive button (back button stock, but it's the task switcher with that file I posted) to act as a menu button. That would be awesome.

Alternatively, I'd love to figure out how to change the TW soft keys to AOSP theme and layout. I love using soft keys, but I can't stand the backwards layout Samsung has chosen, and can't bring myself to using it if I can help it.

Sent from my SCH-I535 using Tapatalk 2

You can add your own methods to the android.policy.jar file to handle different on hold actions.

Sent from my SGH-T999

"So I put my phone into airplane mode and threw it... worst transformer ever. -.-" -My friend
30th March 2013, 11:40 PM |#8  
Member
Thanks Meter: 11
 
More
Quote:
Originally Posted by elesbb

/system/framework/android.policy.jar/PhoneWindowManager.java

At leasts thats what i can remember lol. Thats what i had to edit on my Tablet to make long press on home function as long press search.

Every file editor I try is unable to open/edit the android.policy.jar file. How do I edit it?
3rd April 2013, 03:36 PM |#9  
Notorious's Avatar
Senior Member
Flag Sydney
Thanks Meter: 5,146
 
Donate to Me
More
Re: Remapping the Physical Buttons
Quote:
Originally Posted by tonyf7

Every file editor I try is unable to open/edit the android.policy.jar file. How do I edit it?

Have to decompile it using apktool

Sent from my SPH-L710 using xda app-developers app
22nd April 2013, 06:02 AM |#10  
Senior Member
Thanks Meter: 55
 
More
Quote:
Originally Posted by elesbb

You can add your own methods to the android.policy.jar file to handle different on hold actions.

Sent from my SGH-T999

"So I put my phone into airplane mode and threw it... worst transformer ever. -.-" -My friend

Is it possible to add a method that when back is pressed twice it launches an app? Or can I modify long press to launch an app like voice commands?
21st June 2013, 02:58 PM |#11  
iba21's Avatar
Senior Member
Flag Venice
Thanks Meter: 1,544
 
Donate to Me
More
hi guyz.. one question.. i'd want to remap the buttons with this logoc

1 press mený -> multitasking tab
long press mený -> mený
long press home buttons -> gvoice

any idea how to use it?

i'm on swift rom v3 + perseus kernel and, i don't have the sec_touchkey file! o.o

how to?

i'd want to use the stock tw launcher, not another one..

thanks

---------- Post added at 03:58 PM ---------- Previous post was at 03:21 PM ----------

Ok i edited the file and puted it in right folder.. now i have the multitasking in normal mený press, but NOT the mený in the hold.. what could i do?

Read More
Post Reply Subscribe to Thread

Tags
capacitive button, capacitive buttons not working
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes