Related
Hi! I noticed this bug in ock's theme originally and then when I was trying to make my own theme banged heads with it myself.
The issue is that in the browser the combobox button seems to spill over into the text and generally is stretched poorly.
Like this:
I tried at first simply creating a .9.png version and removing the originals and replacing with the .9s. This made the bar vanish completely.
Eventually I got it working with a bit of a work-around, by compiling the .apk twice and extracting the images.
Having to explain that process recently lead me to the real answer though.
combobox_disabled.png and combobox_nohighlight.png ARE .9.pngs even though they do not have the .9.png extension.
apkmanager won't decompile (or compile) them as .9's because they don't have the right extension (and the right extension 'breaks' the theme).
Attatched are my .9.png versions of both images. I added the guidelines from scratch, but they seem to be correct. If your theme has this issue and you need to fix it, just drop the 'compiled' versions into your res/drawable-hdpi and apk-manager should happily compile it and the issue should be resolved.
tried both versions to just replace the ones in my framework-res.apk (didn't decompile the file but just replaced the files) and both didn't solve the problem.
XlAfbk said:
tried both versions to just replace the ones in my framework-res.apk (didn't decompile the file but just replaced the files) and both didn't solve the problem.
Click to expand...
Click to collapse
That -may- not work. That was one of the first things I tried to do - replace with .pngs straight from stock without a decompile/recompile of the whole apk.
The format of the zip file might be slightly ambiguous.
9s - are the raw pngs with draw9patch guidelines.
compiled - are the compiled draw9patch pngs. If you use a draw9patch compiler on the files in the 9s directory you get these.
Even though the pngs are compiled you still need to go through the decompile/recompile procedure with apk manager. (using the 'compiled' pngs).
sargorn, I've tried several times to decompile and recompile the framework with no luck. The new framework is ok, except this damn combo box rendering.
I personally gave up trying :|.
Toss me the framework and I'll give it a shot.
here's mine, based on JVB. thx fo giving it a try
XlAfbk said:
here's mine, based on JVB. thx fo giving it a try
Click to expand...
Click to collapse
Hi,
I tried decompiling and then recompiling your framework and it does not recompile.
zzzzz_tw_quickcontact_slider_btn_pressed.9.png and zzzzz_tw_quickcontact_slider_btn_selected.9.png were both 0 bytes.
If you've just been replacing images this probably won't work
Here it is decompiled and recompiled with stock copies of those two files and the combo box 'fix'.
The filesize seems very 'off' so I'm not sure if it'll work or not.
ro_explorer said:
sargorn, I've tried several times to decompile and recompile the framework with no luck. The new framework is ok, except this damn combo box rendering.
I personally gave up trying :|.
Click to expand...
Click to collapse
I've just de/recompiled JVH's framework-res and the combobox fix still seems to work. (Although maybe it's not needed in JVH, didn't test it!).
I tried it again with JVH and failed again. What I did:
1. decompile framework-res.apk with apkmanager
(2. make some of my changes to some xml files)
3. place the 2 files from compiled in drawable-hdpi-v4
4. recompile the apk
Everything but the comboboxes works as expected.
I'm attaching the apk, maybe you could have a look at it. If you can make it work please tell me what I did wrong. Many thx
XlAfbk said:
I tried it again with JVH and failed again. What I did:
1. decompile framework-res.apk with apkmanager
(2. make some of my changes to some xml files)
3. place the 2 files from compiled in drawable-hdpi-v4
4. recompile the apk
Everything but the comboboxes works as expected.
I'm attaching the apk, maybe you could have a look at it. If you can make it work please tell me what I did wrong. Many thx
Click to expand...
Click to collapse
As im here looking for the fix for my dhd I thought I might be able to help
Looking at your framework I can clearly see that those images in there are not fixed.
Try simply dragging and dropping the fixed pngs straight into your framework
liamstears said:
Try simply dragging and dropping the fixed pngs straight into your framework
Click to expand...
Click to collapse
that won't work, was said before, needs to be compiled in
Try out the jvo rom - I think this issue may be resolved in that framework.
Sent from my GT-I9000 using XDA Premium App
I still have that issue with my JVO theme
What's the best way or program to recompile xmls. Im able to use apk manager and apktool to decompile and make my edits but I can never be able to recompile successfully. So is there any other way it can be done?
suwu10 said:
What's the best way or program to recompile xmls. Im able to use apk manager and apktool to decompile and make my edits but I can never be able to recompile successfully. So is there any other way it can be done?
Click to expand...
Click to collapse
For just XML ? Are you running Linux/Mac/Win ?
Greetz to Burque !
suwu10 said:
What's the best way or program to recompile xmls. Im able to use apk manager and apktool to decompile and make my edits but I can never be able to recompile successfully. So is there any other way it can be done?
Click to expand...
Click to collapse
If there is nothing wrong with your edits apk manager should be able to recomiple without a problem. What error are you getting?
suwu10 said:
What's the best way or program to recompile xmls. Im able to use apk manager and apktool to decompile and make my edits but I can never be able to recompile successfully. So is there any other way it can be done?
Click to expand...
Click to collapse
Im aware you stating making your edits is not the issues, but just making sure you made your changes using Notepad++ and not just Notepad....
Sorry I didn't post but i figured it out. I was using a themed framework and system ui so that's why I was getting errors when decompiling and recompiling. I just used as close to stock as possible framework and system ui then dragged over to my theme and it worked
I am interested in changing the color of the text of the status bar. I have already modified all the images I need, now just need to modify the xml.
I am modifying the framework-res.apk colors xml. After I have made the change I recompile the apk. Switch out the Meta-INF and AndroidManifest.xml with the ones from the original apk but when I push to my phone the color of the status bar text isn't changing. These are the lines I have changed:
<color name="status_bar_text">#ff73cd68</color>
<color name="status_bar_clock_text">#ff73cd68</color>
You might find better luck actually pming a themer or posting it in the theme section. Not much Turner's drop by here
Sent from my SPH-D710 using XDA App
davidc23 said:
You might find better luck actually pming a themer or posting it in the theme section. Not much Turner's drop by here
Sent from my SPH-D710 using XDA App
Click to expand...
Click to collapse
yeah I was thinking that, I might just check on the irc channel. Thanks for looking out.
Hmmm did you reboot the phone?
Sent from my Epicâ„¢ 4G Touch
globalninja said:
Hmmm did you reboot the phone?
Sent from my Epicâ„¢ 4G Touch
Click to expand...
Click to collapse
Yeah, I didn't actually push the framework. I created a flashable zip.
dtm_stretch said:
Yeah, I didn't actually push the framework. I created a flashable zip.
Click to expand...
Click to collapse
If you got the framework-res.apk to recompile without errors then the changes you made should definitely work. There is no need to sawp anything owhen recompiling, just edit the xml, recompile it as a system app and push it to system/app via root explorer or any equivalent.
Which ROM framework are you trying to modify?
fnut6969 said:
If you got the framework-res.apk to recompile without errors then the changes you made should definitely work. There is no need to sawp anything owhen recompiling, just edit the xml, recompile it as a system app and push it to system/app via root explorer or any equivalent.
Which ROM framework are you trying to modify?
Click to expand...
Click to collapse
Thanks ill give that I try.
I am actually modifying the ICS theme for Cakulin's rom.
**Doesn't seem to work either. I should be changing the colors.xml in the framework-res.apk right?
Got it: Make sure to delete the stupid resources.arsc!
dtm_stretch said:
Thanks ill give that I try.
I am actually modifying the ICS theme for Cakulin's rom.
**Doesn't seem to work either. I should be changing the colors.xml in the framework-res.apk right?
Click to expand...
Click to collapse
Yes, and although you won't find the values folder when you recompile you'll still need to delete the resources.arsc when recompiling, if you'd like, you can attach the framework-res.apk you're trying to modify and I can change it for you.
I also, stated inadvertently, to place it in system/app that is incorrect it goes in system/framework which may actually be part of the problem.
fnut6969 said:
Yes, and although you won't find the values folder when you recompile you'll still need to delete the resources.arsc when recompiling, if you'd like, you can attach the framework-res.apk you're trying to modify and I can change it for you.
I also, stated inadvertently, to place it in system/app that is incorrect it goes in system/framework which may actually be part of the problem.
Click to expand...
Click to collapse
I got it figured out, just before you posted about the resources. Now I just got to figure out why my launcher keeps restarting.
Can anyone edit a framework-res.apk with no mods other than adding the crt animation? I've found guides on how to edit the bools file in the res/values filder inside the apk, but I can't get it to recompile the apk correctly. Can someone tell me how or send me an edited apk or something?
If you want to post your framework file, I'll do it for you and send it back.
I just posted several of these for Caulkulin's 3.0 rom. What are you using now? His framework, but with a stock battery look.
Sent from my SPH-D710 using XDA
kyamora said:
Can anyone edit a framework-res.apk with no mods other than adding the crt animation? I've found guides on how to edit the bools file in the res/values filder inside the apk, but I can't get it to recompile the apk correctly. Can someone tell me how or send me an edited apk or something?
Click to expand...
Click to collapse
You need to check the error and see whats wrong with the framework file. Also you just want a stock framework file with crt on? Also what are you using to compile and decompile
playya said:
You need to check the error and see whats wrong with the framework file. Also you just want a stock framework file with crt on? Also what are you using to compile and decompile
Click to expand...
Click to collapse
I was using apk manager 4.9, and I have no idea how to read the log.
I attached my framework-res. It's stock from FD19, I probably should have specified.
If no one gets to it, I'll mod it when I get home.
Sent from my SPH-D710 using xda premium
All done. I tested on my phone. After I replaced the apk, I had to manually restart the phone for it to work. I placed your apk in a zip file before I uploaded, so make sure you unzip your apk before putting it back on your phone.
Thank you so much, it works very well.
Now I'd just like to know how you did it. Coming from a clean computer with nothing installed, what would I need to decompile an apk, edit it, and compile it again? I'm trying to get a handle on the whole thing to do some development myself.
Try and upgrade to Apk Manager 5.02 since I just de-compiled and then compiled your apk file without an issue. Also try and update everything associated with it like your java... But it seems quite fine to me
Edit: just tried yours again as well as removing animation I lowered autobrightness which is something I do on all my roms for better battery life.. Try that mod next
playya said:
Try and upgrade to Apk Manager 5.02 since I just de-compiled and then compiled your apk file without an issue. Also try and update everything associated with it like your java... But it seems quite fine to me
Edit: just tried yours again as well as removing animation I lowered autobrightness which is something I do on all my roms for better battery life.. Try that mod next
Click to expand...
Click to collapse
Do I have to do anything to set it up or is it good to go from install? Should I restart my computer?
Also where can I find 5.02? I had a lot of trouble finding 4.9 in the first place.
I've never used apk manager, so I'll check that out also. I used apktool to mod your framework along with all the java runtime files it needed to work.
Sent from my SPH-D710 using xda premium
&roid said:
I've never used apk manager, so I'll check that out also. I used apktool to mod your framework along with all the java runtime files it needed to work.
Sent from my SPH-D710 using xda premium
Click to expand...
Click to collapse
Apktool confused me so I used apk manager. I can't figure out how to get apktool to work. Do you have a link to a good guide or anything?
There are some good ones on xda. I'll link you one when I get home.
Sent from my SPH-D710 using xda premium
I was apparently using the gingerbread method for an ICS build. Would that have kept it from compiling correctly?
kyamora said:
I was apparently using the gingerbread method for an ICS build. Would that have kept it from compiling correctly?
Click to expand...
Click to collapse
YES
&roid said:
YES
Click to expand...
Click to collapse
Haha, at least I'm learning.
To be fair, no one specified. Thanks for all the help guys.
Hi. Any help me to on crt effect in this framework ? I try apk menager and apk edit, and always some problem when compile, program loop and only exit work
http://db.tt/W2DKqulN
I was just wondering if anyone with the UAMDL software has been able to decompile and recompile the framework on here yet.
I have tried with the APK multi tool and the decompile works fine but when I try to recompile it errors our right away.
Anyone have any luck with this?
If so what tool did you use?
Yes I have.
Sent from my SGH-M919 using Tapatalk 2
I'd like to know this as well, and how people have been successful. I haven't had any luck installing framework-res.apk or recompiling a modified app. From my understanding, it's an issue with apktool and aapt that needs to be updated.
TheArtiszan said:
I was just wondering if anyone with the UAMDL software has been able to decompile and recompile the framework on here yet.
I have tried with the APK multi tool and the decompile works fine but when I try to recompile it errors our right away.
Anyone have any luck with this?
If so what tool did you use?
Click to expand...
Click to collapse
That and SystemUI.apk are both missing files needed for them to decompile and recompile right
evil..............out
elesbb said:
Yes I have.
Sent from my SGH-M919 using Tapatalk 2
Click to expand...
Click to collapse
Can you elaborate on what tools you used and how to set it up please?
I have been stuck trying to get this to work for over a week now.
Sent using xda premium.
evil1art said:
That and SystemUI.apk are both missing files needed for them to decompile and recompile right
evil..............out
Click to expand...
Click to collapse
There are ways for making it work though
TheArtiszan said:
Can you elaborate on what tools you used and how to set it up please?
I have been stuck trying to get this to work for over a week now.
Sent using xda premium.
Click to expand...
Click to collapse
I used the tool in my signature and you have to remove some layout paramaters in the xml files then recompile and copy the originals over to the newly compiled apk.
elesbb said:
There are ways for making it work though
I used the tool in my signature and you have to remove some layout paramaters in the xml files then recompile and copy the originals over to the newly compiled apk.
Click to expand...
Click to collapse
Im the one who figured out the missing style for the systemui
evil..............out
evil1art said:
Im the one who figured out the missing style for the systemui
evil..............out
Click to expand...
Click to collapse
Yeah so did I lol. Ive ran into that issue before and thats all you have to do to get around it.
elesbb said:
There are ways for making it work though
I used the tool in my signature and you have to remove some layout paramaters in the xml files then recompile and copy the originals over to the newly compiled apk.
Click to expand...
Click to collapse
We have our own modified apk manger works good
evil..............out
evil1art said:
We have our own modified apk manger works good
evil..............out
Click to expand...
Click to collapse
Ahhh. That makes life a lot easier lol. How did you modify it? Build it from source or edit the jar file?
elesbb said:
Ahhh. That makes life a lot easier lol. How did you modify it? Build it from source or edit the jar file?
Click to expand...
Click to collapse
Modified the original files and changed memory heap etc
evil..............out
Oh okay that makes sense.
I am editing the framework res apk
Making changes only to the arrays.xml file in the values folder.
Which styles should I be commenting out and then which file should I copy to the original?
I tried putting a + in front of a few lines based on the errors I was getting but that seemed to make it worse.
Sent using xda premium.
I think the arrays and other values xml get compiled into the resources file no?
Sent using xda premium.
TheArtiszan said:
I think the arrays and other values xml get compiled into the resources file no?
Sent using xda premium.
Click to expand...
Click to collapse
Everything in the values directory is found in your resources.arsc file in the apk.
Sent from my SGH-M919 using Tapatalk 2
Ah that makes sense.
The changes made for layouts, does that go into the same area though?
Just wondering if that might cause a problem since that is what I would want to move over.
Sent from my HTC VLE_U using xda premium
That is odd.
I can get this to decompile in apk multi tool but not Elesbb's GUI
I get the following error:
Tue 06/25/2013
0:46:56.39
Decompiling.. "C:\Users\Bill\APK GUI\framework-res.apk"
I: Loading resource table...
Exception in thread "main" brut.androlib.AndrolibException: Multiple resources: spec=0x010802f4 drawable/ic_ab_back_holo_dark, config=-hdpi
at brut.androlib.res.data.ResConfig.addResource(ResConfig.java:65)
at brut.androlib.res.data.ResConfig.addResource(ResConfig.java:58)
at brut.androlib.res.decoder.ARSCDecoder.readEntry(ARSCDecoder.java:197)
at brut.androlib.res.decoder.ARSCDecoder.readConfig(ARSCDecoder.java:166)
at brut.androlib.res.decoder.ARSCDecoder.readType(ARSCDecoder.java:131)
at brut.androlib.res.decoder.ARSCDecoder.readPackage(ARSCDecoder.java:106)
at brut.androlib.res.decoder.ARSCDecoder.readTable(ARSCDecoder.java:83)
at brut.androlib.res.decoder.ARSCDecoder.decode(ARSCDecoder.java:49)
at brut.androlib.res.AndrolibResources.getResPackagesFromApk(AndrolibResources.java:390)
at brut.androlib.res.AndrolibResources.loadMainPkg(AndrolibResources.java:56)
at brut.androlib.res.AndrolibResources.getResTable(AndrolibResources.java:48)
at brut.androlib.Androlib.getResTable(Androlib.java:48)
at brut.androlib.ApkDecoder.getResTable(ApkDecoder.java:166)
at brut.androlib.ApkDecoder.decode(ApkDecoder.java:99)
at brut.apktool.Main.cmdDecode(Main.java:131)
at brut.apktool.Main.main(Main.java:68)
-----------------------------------------------------------------
Did I miss something.
Made some progress and decompiling ok now on a different computer.
If I add the + before the layouts would that cause operation issues?
I would like to know too.
Still having trouble.
What did you do too decompile?
Okay I can now get it to recompile adding the +layout to the xml files that were erroring in the compile log and only other change was made was to the arrays.xml file to enable bluetooth tethering like on the GS3 did.
however when I push it to the phone and chmod and try it I get a boot loop.
Did I do something wrong?
Am I supposed to copy out the resource.asrc from the file I compiled like a zip then add it to the original that I pulled using 7zip or something?
Any input would be greatly appreciated.
TheArtiszan said:
Okay I can now get it to recompile adding the +layout to the xml files that were erroring in the compile log and only other change was made was to the arrays.xml file to enable bluetooth tethering like on the GS3 did.
however when I push it to the phone and chmod and try it I get a boot loop.
Did I do something wrong?
Am I supposed to copy out the resource.asrc from the file I compiled like a zip then add it to the original that I pulled using 7zip or something?
Any input would be greatly appreciated.
Click to expand...
Click to collapse
Move the AndroidManifest.xml and Meta-INF folder from the original apk to the modified one.
Sent from my SGH-M919 using xda premium