View Single Post
Old 04-04-2022, 07:42 AM   #2
Renate
Onyx-maniac
Renate ought to be getting tired of karma fortunes by now.Renate ought to be getting tired of karma fortunes by now.Renate ought to be getting tired of karma fortunes by now.Renate ought to be getting tired of karma fortunes by now.Renate ought to be getting tired of karma fortunes by now.Renate ought to be getting tired of karma fortunes by now.Renate ought to be getting tired of karma fortunes by now.Renate ought to be getting tired of karma fortunes by now.Renate ought to be getting tired of karma fortunes by now.Renate ought to be getting tired of karma fortunes by now.Renate ought to be getting tired of karma fortunes by now.
 
Posts: 4,176
Karma: 19000001
Join Date: Feb 2012
Device: Nook NST, Glow2, 3, 4, '21, Kobo Aura2, Poke3, Poke5, Go6
I had previously disabled all this long press stuff and key mapping.
I ran into problems before when I just deleted res/raw/keypad.json and res/raw/bt_keypad.json from /system/framework/framework-res.apk
The least intrusive way to disable access to these two files is to rename the filenames in the .zip (.apk) in the local header.

These numbers are from the Poke3 but other models will have stuff in approximately the same place.
Code:
C:\>findtext framework-res.apk keypad.json
00B2BCBD  res/raw/bt_keypad.json // manifests
00B2BD91     res/raw/keypad.json
01539DDE  res/raw/bt_keypad.json // zip local headers
0153A5A1     res/raw/keypad.json
016A3844  res/raw/bt_keypad.json // zip global headers
016A39E5     res/raw/keypad.json
C:\>modfile framework-res.apk 1539DDE 7a // k -> z
C:\>modfile framework-res.apk 153A5A1 7a // k -> z
(Your tools are probably named something else, but you get the idea.)

Then you'll need to put the modified file in a Magisk module.
You should probably make a module just for yourself that you can throw in odds and ends.
Making a module like this is easier than a packaged module for distribution.
Just make your own directory:
Code:
# cd /data/adb/modules
# mkdir -p MyModule/system/framework
Then you'll need to make the MyModule/module.prop file. It's nothing critical, just give your module some names. It's all documented here: https://topjohnwu.github.io/Magisk/guides.html
Renate is offline   Reply With Quote