Introducing XDA:DevCon – A Conference For Developers By Developers
XDA Developers Android and Mobile Development Forum
Forgot your password?
 
Post Reply+
Tip us?
 
a12bd1
Old
(Last edited by a12bd1; 14th September 2012 at 11:34 AM.)
#1  
Member - OP
Thanks Meter 12
Posts: 56
Join Date: May 2012
Location: bandung
Default How to add on screen button at framework for ICS

I'm using Xperia arc s at stock rom 4.1.B.0.587 and locked bootloader.
I'm using few mods, and also custom systemui *Colored icons systemui
Few days ago I am starting curious how to add on screen button at my own, and I still cannot do it successfully (got bootloop after xperia title).

After trial and error I found the solution, I don't add original META-INF framework.apk to my modified framework.apk.

Now I'm only curious how to add crt off animation. *I found out that original framework.apk already has the setting to show crt animation. Anyone has an idea what to do??

How I successfully add on screen button:
Quote:
What I do: (following the tutorial from http://forum.xda-developers.com/show....php?t=1364757, and http://forum.xda-developers.com/show...43#post9126643 to mod the apk)
1. extract framework-res.apk from my system [framework-res.apk]
2. decompile it with 1.4.10 apktool by this command: java -jar apktool.jar d framework-res.apk framework-res
3. edit bools.xml to change show navigation bar to true
4. edit dimens.xml to change navigation bar height to (21.0dip)
5. rebuild the apk with this command: java -jar apktool.jar b framework-res out\framework-res.apk
6. <from this part I dont really understand> From the output apk [The name is outframework-res.apk] from apktool 1.4.10 (At first I use 1.4.3 and it always failed to compile, but It compiled successfully with 1.4.10), I add the extension to 7z [outframework-res.apk.7z], and unpack it. (i.e: it become outframework-res folder)
7. With 7zip app (actually I use total commander, with zero compression), I replace all files from outframework folder back to outframework.apk.7z
8. I also add resources.arsc from the outframework-res folder and also add it to the outframework-res.apk.7z. *The file size is the same before and after I put the resources.arsc.
9. I downloaded ics_sysbar.zip, then with total commander (7zip like program), I add those files to SystemUI.apk (/res/drawable-hdpi/) using 7-zip or other program. (replace original PNGs to these files).
10. I rename the outframework-res.apk.7z to framework-res.apk then push it to my device along with the SystemUI.apk.
The Following User Says Thank You to a12bd1 For This Useful Post: [ Click to Expand ]
 
soumya_digi
Old
#2  
soumya_digi's Avatar
Recognized Themer
Thanks Meter 1288
Posts: 1,021
Join Date: May 2011
Location: Kolkata
Adding "qemu.hw.mainkeys=0" to build.prop enables soft-keys in AOSP/CM10.. I don't use stock ICS so can't confirm this. Wait for few more replies from other users.
 
a12bd1
Old
#3  
Member - OP
Thanks Meter 12
Posts: 56
Join Date: May 2012
Location: bandung
Quote:
Originally Posted by soumya_digi View Post
Adding "qemu.hw.mainkeys=0" to build.prop enables soft-keys in AOSP/CM10.. I don't use stock ICS so can't confirm this. Wait for few more replies from other users.
Thanks for your reply.
By the way, I actually found what is my problem, from analyze other working on screen button.
It turns out the compiled framework don't add META-INF.
After I add that folder to my compiled framework, *with total commander, It works.
And editing the SystemUI turns out unnecessary.

What I still wonder is how to add menu button (the right key, beside back and home button), and also make holding home button show the ics style recent app (the one that you can swipe to remove it from recent app).
 
Post Reply+
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Go to top of page...