Looking for images. - Samsung Epic 4G Touch

I am looking for the ICS colored battery images to replace the percentage ones. The ones in ROM Toolbox won't work cause there is only ten of them and I need 100. I have no problem makeing the changes to the framework I just can't find them and before I fire up Adobe Fireworks and start switching green to blue I thought I would ask and see if anyone had them and would send em my way. Thanks in advance.

Just wanted to be clear ( I read my OP and it can be a little confusing). What I need is the no percentage battery icons to replace the percentage ones in the ICS blue. Thanks.

You have three options.
1). You can manually add another 10 icons per icon with renaming each one to "stat_battery_1, stat_battery_2, etc." until you get to 100 images. Or...
2). You can just drag the stat_battery.xml, stat_battery_charging.xml into your framework-res.apk's drawable folder from a stock EL29 framework-res.
3). You can post the framework-res.apk you're using and I'll make the modifications for you.
EDIT: The easiest way to get this to work is to edit the stat_battery.xmls.
For example. Here's the no% battery mod for my theme. This code is pulled directly from stat_sys_battery.xml in the drawable-hdpi.
<?xml version="1.0" encoding="utf-8"?>
<level-list
xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@drawable/stat_sys_battery_0" android:maxLevel="2" />
<item android:drawable="@drawable/stat_sys_battery_5" android:maxLevel="7" />
<item android:drawable="@drawable/stat_sys_battery_10" android:maxLevel="12" />
<item android:drawable="@drawable/stat_sys_battery_15" android:maxLevel="17" />
<item android:drawable="@drawable/stat_sys_battery_20" android:maxLevel="22" />
<item android:drawable="@drawable/stat_sys_battery_25" android:maxLevel="27" />
<item android:drawable="@drawable/stat_sys_battery_30" android:maxLevel="32" />
<item android:drawable="@drawable/stat_sys_battery_35" android:maxLevel="37" />
<item android:drawable="@drawable/stat_sys_battery_40" android:maxLevel="42" />
<item android:drawable="@drawable/stat_sys_battery_45" android:maxLevel="47" />
<item android:drawable="@drawable/stat_sys_battery_50" android:maxLevel="52" />
<item android:drawable="@drawable/stat_sys_battery_55" android:maxLevel="57" />
<item android:drawable="@drawable/stat_sys_battery_60" android:maxLevel="62" />
<item android:drawable="@drawable/stat_sys_battery_65" android:maxLevel="67" />
<item android:drawable="@drawable/stat_sys_battery_70" android:maxLevel="72" />
<item android:drawable="@drawable/stat_sys_battery_75" android:maxLevel="77" />
<item android:drawable="@drawable/stat_sys_battery_80" android:maxLevel="82" />
<item android:drawable="@drawable/stat_sys_battery_85" android:maxLevel="87" />
<item android:drawable="@drawable/stat_sys_battery_90" android:maxLevel="92" />
<item android:drawable="@drawable/stat_sys_battery_95" android:maxLevel="97" />
<item android:drawable="@drawable/stat_sys_battery_100" android:maxLevel="100" />
</level-list>
I have an image for each line, starting at 0, 5, 10, 15. So I would have images in the drawable-hdpi (no% images) that are called stat_sys_battery_0, stat_sys_battery_5, stat_sys_battery_10 and so on until you reach 100. This makes it very easy to use just 10-15 images to get the no% mod instead of copying over 100 images for charging and non charging. Same thing can be applied to the stat_sys_battery_charging.xml.

Honestly I'm all for doing step 1 and 2. But I am still learning. I have a flashable template I got from apk tool so I can flash the framework back. Here's the framework. Dude you're awesome and I am more than willing to help ya out anyway possible.
http://db.tt/QlXIeEHO

Okay, so I took a stock EL29 framework-res. Extracted the stat_sys_battery.xml, stat_sys_battery_charging.xml and dragged it into your framework-res.apk you supplied me. I then took the 15 ICS stock battery icons I had and threw them in the framework.
Here is your no% modded ICS framework-res.
Here are the battery icons I used.
P.S. You can find what code lies within the stat_sys_battery from a few posts up to get a better understanding of what I did.

Just read that addition to your post. Im starting to get the principle behind it. When I get home tonight I'm gonna have to play around with it. The pngs I'm good with. Its the xmls I'm still wrapping my head around. I'm not worried about messing things up as I can generally just Odin back. Just trying to learn what different codes mean and all that **** can make ya go crosseyed. Haha. Thanks again man for the info and for the framework edit. I hopefully can contribute some things in the near future. They maybe small contributions but hey anythings better then not in right.

scarmon25 said:
Just read that addition to your post. Im starting to get the principle behind it. When I get home tonight I'm gonna have to play around with it. The pngs I'm good with. Its the xmls I'm still wrapping my head around. I'm not worried about messing things up as I can generally just Odin back. Just trying to learn what different codes mean and all that **** can make ya go crosseyed. Haha. Thanks again man for the info and for the framework edit. I hopefully can contribute some things in the near future. They maybe small contributions but hey anythings better then not in right.
Click to expand...
Click to collapse
Yeah, XMLs are a pain (even for me still), but the basic ones such as these are somewhat easy to follow. Once you get where everything goes, theming is a breeze from there.

Well I did some reading on XML. Also the images you sent are the ones I have been looking for but the framework seems to be the same. I downloaded it again to make sure I didn't get em messed up. Possible the wrong one got uploaded? Also thanks a ton man. I've learned me something today.

scarmon25 said:
Well I did some reading on XML. Also the images you sent are the ones I have been looking for but the framework seems to be the same. I downloaded it again to make sure I didn't get em messed up. Possible the wrong one got uploaded? Also thanks a ton man. I've learned me something today.
Click to expand...
Click to collapse
I only changed certain battery images (alot of the battery images are the same, only overwrote a few. The ones in the zip are the ones I uploaded in the framework-res. At least I think I did. Lol
Sent from my SPH-D710 using Tapatalk

Haha. Its still displaying in increments of 1. I know that feeling. I double checked a few times figuring j did something wrong. But it still displays like it did.

Just looked and it looks like the images are the right ones in the framework. But its displaying in 1 percent instead of fives. I'm using root explorer to look inside the apk. If I was at home I would drag the XML over like ya said

scarmon25 said:
Just looked and it looks like the images are the right ones in the framework. But its displaying in 1 percent instead of fives. I'm using root explorer to look inside the apk. If I was at home I would drag the XML over like ya said
Click to expand...
Click to collapse
Yeah I must've missed dragging the XMLs from drawable over. My bad. :X
...Or maybe this is a test to make sure you know your knowledge?

Overstew said:
Yeah I must've missed dragging the XMLs from drawable over. My bad. :X
...Or maybe this is a test to make sure you know your knowledge?
Click to expand...
Click to collapse
Hahaha. I'm learning. Seriously though man I soak up this type of knowledge like a sponge. I've been playing alot with themeing and ****. I almost had me a aospish styled from done and Dude dropped his which was way better and more detailed then mine. I'm learning though. I love android and would spend every waking minute tinkering if I could.

uhh, i think the issue is on my end, i dont think my flashable template was flashing it, it said it was but i dont think it was actually working, now that im at home im gonna play with it.
Thats exactly what it was, I repackaged the framework in the theme zip and it flashed and bam, perfecto. damn man IM sorry, I should have known something was on my end.
question. I can decompile a framework with apktool just fine but when i use it to recompile and then flash it i get errors lie force closes on certain things. Am i doing that right? or should I use a different tool for decompiling and recompiling the frameworks

Is it giving errors when you recompile? Decompile with twframework-res.apk dependencies.

Your still need to decompile the framework and edit the res/values/public.xml, it is still using each percentage. On mine if you look around line 4577 the rest of the battery percentages are added. You will need to remove all of the ones that you wont use.
I decompile framework 2 at a time. I use one that is edited, and one that I am editing. I open them up in 2 separate windows, that way I can copy and paste the changes. I name the edited one "editedframework-res.apk" that way I dont get them confused. After you recompile, copy the /res folder and resources.arsc from the new one to the old one.

Oh no, its working fine now. I didnt decompile it this time I just swapped the frameworks in the theme. But a while back when I was working on the AOSPish Theme I meantioned. I decompiled the framework to do something I cant remember what but I needed access to an xml that wasnt available through 7zip. when i recompiled it booted and worked but i would get random force closes on things. So I figured I messed something up. Long story short I ended up on stock deodexed and decompiled and then immediately recompiled the framework to rule that it was that causing it and still got the random force closes. so I assumed I was doing it wrong or I needed to use something else to decompile/recompile

xml's can be a ***** sometimes, you have to edit 5 things to get one thing done.

shiftr182 said:
xml's can be a ***** sometimes, you have to edit 5 things to get one thing done.
Click to expand...
Click to collapse
I'm starting to realize that. I used the framework he made me and of course it worked when I got it to flash. Then I took the original framework of the theme and did what he said an I was able to get it to work without decompiling by doing what he said. I made sure it flashed too. So that's one more thing under my belt. Sometimes not decompiling if possible is the best way to go I'm starting to realize. Most of the apk edits I have done I can do in 7zip without anymore then opening the archive and dragging and dropping the pngs into it. But when it comes to XML sometimes that's not possible. There are some folders and files hidden in 7zip and not visabke until its decompiled. Another thing I have found out.
I have to say its awesome that you guys are willing to help like this. One of the main reasons I love the android community.

Thanks for the information. So one would use Root Explorer to replace the framework apk? I am running Venom's TW/Sony ICS Rom and I want to use the stock battery icon as well. Would this work for me?

Related

[MOD] Touchwiz Speed

Hi Everyone,
I tried to find a lot on all sections and google for a good touchwiz Mod but to no avail. So i thought of asking u guys for some insight to Mod Touchwiz for our beloved Galaxy S.
So i extracted TouchWiz30Launcher.apk to a folder. Was checking the different resources and i came across \res\anim and i saw two files fade_in_fast.xml and fade_out_fast.xml. Now they are binary XML files. So the question is can we modify or delete some values and speed up touchwiz. I dont care about the fancy transition or effects. Just raw speed. Tried ADW and Launcher Pro but i personally didnt like it. Please forgive me if this is pretty simple. Here is the code for the files.
Guys we modify these values and recompile TouchWiz30Launcher with apk manager.
XML code for fade-in
<alpha fromAlpha="resource_id:0x0" duration="resource_id:0x10e0001" interpolator="resource_id:0x10a0005" toAlpha="resource_id:0x3f800000">
</alpha>
XML code for fadeout
<alpha fromAlpha="resource_id:0x3f800000" duration="resource_id:0x10e0001" interpolator="resource_id:0x10a0005" toAlpha="resource_id:0x0">
</alpha>
check attachment for the files.
Awaiting reply. Thanks in advance.
Come on guys. No one's intrested in tweaking touckwiz.
shawn_pro said:
Come on guys. No one's intrested in tweaking touckwiz.
Click to expand...
Click to collapse
wrong attitude
shawn_pro said:
Come on guys. No one's intrested in tweaking touckwiz.
Click to expand...
Click to collapse
the truth
shawn_pro said:
Come on guys. No one's intrested in tweaking touckwiz.
Click to expand...
Click to collapse
Attention whore?
I might be running Launcher Pro, but I support that you are doing this. Cheers!
Would be useful especially since i've seen Touchwiz drain less battery compared to other launchers. IMHO.
Sent from my GT-I9000 using XDA App
Thanks for your work, may i ask how to use your file? How could i combine it into the existing launcher application?
if it matters that much to you, try picking up how binary numbering works...
Anyways, if I were to try messing around with it - I'd change that last digit in the binary sequence from a 5 to a 3...
Firstly, it isn't binary, it is Hex.
I have not tested but I guess if you change the duration to a lower number, you may get lucky but I expect that these values actually point to another resource for the actual value.
nafem said:
Firstly, it isn't binary, it is Hex.
I have not tested but I guess if you change the duration to a lower number, you may get lucky but I expect that these values actually point to another resource for the actual value.
Click to expand...
Click to collapse
Sorry, I'm not really a programmer...I just offered an idea because nobody else seemed to at the time.
Also, I thought Hex was 6-digit ranging from 0-F/digit? Or is that for colors only?
Hey guys i tried changing the values for the duration but when i over written the modded touchwiz apk to system/app folder i keep on getting Force Closes. Guess i should take a different route. Thanks for the tips guys.
Sorry guys i didnt meant to be rude or show any attitute in the above post. I respect all XDA members. I just hope my findings would be useful to someone who be looking just for it.
Not really sure what you're trying to do with this. Are you trying to remove the fade-in/fade-out animation when using the home screen? Why would you? It looks cool!
I'm interested in removing the animation as well. It looks nice indeed, but it doesn't works smooth on my ZTE Blade. It used to work without lags on my T-Mobile pulse...
After changing the values in the XML file, is it possible to reinstall the file with those changes ?
If so, I can give it a try as well...

[Q] How do I edit my stock battery icon?

I'm fairly new at starting to create a custom feel for my evo, and I seem to be stuck on getting a custom battery icon to work.
this is what ive done so far to the framework-res.apk
1) edited the stat_sys_battery.xml and zzz_stat_sys_battery_1.xml to add the lines <item android:drawable="@drawable/stat_sys_battery_5" android:maxLevel="5" /> for each increment from 0 to 100
2) added a png file for each increment named stat_sys_battery_5.png
3) replaced my phones original apk with the new framework-res.apk.
now when i boot up my phone, where the battery icon is, i get the grey battery symbol (which is the stat_sys_battery_unknown.png image). is there another file i need to edit, or what step am i missing?
im currently using the stock gb 4.22 deodex rom, any help would be appreciated
You looking for battery percentage icon or just different color?
Sent from my PC36100 using XDA Premium App
either/or, currently im trying to change just the percentages to make sure i can get it to work properly, then ill work on a wider variety of icons. im not looking for a flashable zip, or someone elses modified apk, im looking for guidance on how to do it myself
Ok..I was going to go the zip route for you. Have no idea on doing it yourself. I'm sure someone will be along shortly to help you out. Good luck.
Sent from my PC36100 using XDA Premium App
After 3 hours of trial and error, finally solved the problem. Apparently, I also needed to update the original resources.arsc files. Thread can be closed now.

[Q] De-TouchWizzing MusicPlayer.apk

hello guys,
i want to "de-touchwiz" the music player so i can use it on miui. i managed to merge the twframework styles and colors with the musicplayers' ones and looked for drawables in twframework that are referenced by these and put inside musicplayer. i looked through all the xmls and where i found some "touchwiz:color" or similar i changed it so it points now to the local color/style file not the twframework one
but i got stuck at some points: i have some layout files that refer to frame layout with com.sec.android.touchwiz.widget and inside these touchwiz properties, like for android:id or things like that but touchwiz:twIndexViewHandlePosition and xmlns:touchwiz="http://schemas.android.com/apk/res/touchwiz". what should i do with them?
and do i have to change the smali code, too? i guess so but i don't exactly know where to start with it.
thanks very much for your help
-picard
anyone?
-10char
instead of removing those tw attributes, you could try to merge the tw framework into the apk.
Just decompile the frameworks and copy their source folders into the music's app source folder.
that's what i try to do, i copied all referenced images and tw color attributes to the apk, but for these i don't know how to change (i guess i need to make it an android attribute, can i make it by simply merging those from the framework?)
but what is "com.sec.android.touchwiz.widget" referring to? what do i have to merge to my app?
I did not meant resources but code.^^
"com.sec.android.touchwiz.widget" is a class somewhere in one of the tw frameworks.
okay, my bad
trying it
How did you go with this apk? I'm working on the same thing at the moment, I'm interested to know what happened.
Thanks
interested) hope you can get something done
Sent from my GT-I9000 using Tapatalk 2
kage00 said:
How did you go with this apk? I'm working on the same thing at the moment, I'm interested to know what happened.
Thanks
Click to expand...
Click to collapse
actually i dropped the project due to lack of time and skills
picard666 said:
actually i dropped the project due to lack of time and skills
Click to expand...
Click to collapse
I know what you mean, this app is a nightmare - samsung really made sure this apk was bloody difficult to port, I dont know what else to try, I keep having errors and the apk wont start, I think it has something to do with the boot sequence not being the same on AOSP as on a samsung rom, it checks for a certain sequence and if it doesn't see it, the app won't start...

Transparent Status Bar--Instructions for DIY

Disclaimer: I do not have any formal training with anything I'm covering here and it's entirely possible….dare I say probable…that I may state something incorrectly either partially or wholly (hopefully I’m not that far off). So this is just how I've come to understand things from my own self study as well as staring smali for countless hours (although I have to say the more I learn, the more I learn I don't know ). Hopefully there’s another beginning android hobbyist that finds this useful and/or inspires him to try some new things.
**These instructions apply to Mac and Linux only, due to the fact we're working with aosp source and building in windows is not supported at this time**
Enabling Translucency
I approached this a little different than I’m used to seeing in terms of a mod. Normally we start off by decompiling an apk and go from there. Since this is for an aosp rom, we have easy access to the source code and can make changes there. Now, I don’t proclaim to know java. I have very, very little programming experience, and even that is limited to an introductory C++ class I just took. But even without knowing java, you’ll have a much easier time reading java source code than you will smali. So, yes, you need to sync with aosp to use this guide. It's not hard, and there's good instructions HERE. As an aside, my personal opinion is that anyone that a true-blue xda'er should have aosp syned...even if you have no intention of building roms. It's like an android encyclopedia. I've learned A TON just from poking around/reading though some parts. I probably comprehend < 10%, but it's easily been one of the most beneficial things I've done to further my understanding.​
So now you have the source code. What we need to change is the PixelFormat for the statusbar. In froyo and gingerbread this was done in StatusBarService. It’s been changed a little in ics, although the edits remain in SystemUI. The two files I changed were StatusBar and PhoneStatusBar.
Starting in the root of your aosp working directory, the absolute path of the first file I edited is
Code:
frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/StatusBar.java
Open this in a good text editor. The PixelFormat parameter is specified in the getStatusBarHeight function. In the version I edited it is easily found on lne 124. Just search for “PixelFormat” and you’ll find it. (ignore the search return that’s part of the import statement at the beginning of the file) As soon as you get there you’ll see the problem. PixelFormat.OPAQUE. Replace OPAQUE with TRANSLUCENT. Save
Next you make similar edit in PhoneStatusBar.java. From the same directory that StatusBar.java is in, go to the phone directory and open PhoneStatusBar.java in your text editor. Now this file is much, much longer to read through. Rather than doing that (of course you can if you want) just performa search for that same text again “PixelFormat” You’ll get several returns, some of them will already have TRANSLUCENT set.
BUT...Don’t get carried away and change all the OPAQUE values. One of the search returns will be part of the function getRecentsLayoutParams (starts on line 378). The portion of code that you might be temted to change checks the PixelFormat by way of a boolean test
Code:
(opaque ? PixelFormat.OPAQUE : PixelFormat.TRANSLUCENT)
I left this alone.Edit: After reading the entire code a little bit more, I think we could change it to
Code:
PixelFormat.TRANSLUCENT
without any ill effects, although I'm not sure what, if any, additional benefit we'd see. I have not tried.​
The exact places I did change OPAQUE to TRANSLUCENT were in lines 311, and 481. That’s it for the code portion. Make sure to save your changes. Now go back to the res directory and we need to edit some xml files.
From the root of the SystemUI directory, open res/values/colors.xml. Find the entry for “status_bar_background” and change it’s value to whatever you want. In mine I’ve set it to “a6000000” which black but 35% translucent. The first 2 characters control the opacity on a scale from 0-255 where 0 is completely transparent and 255 is fully opaque. That value is then stated in hexadecimal format; e.g. 0=00, 255=ff.
*if you also want a translucent bottom menu bar, it is set in res/layout/navigation_bar.xml. Change the hex value of android:background=”ff000000” to your desired value for opacity.*
Now you should have all the edits in place for a translucent statusbar. All that’s left is to compile the apk. Before you compile SystemUI, you need to have ran the extract-files script. Only needs to be done once. Connect your phone to the computer(making sure that usb debugging is turned on) then in terminal, starting from the root of your aosp working directory:
Code:
cd device/samsung/maguro/
./extract-files.sh
Let the script finish. It will create a new vendor directory in the root of your working directory and copy several files from your phone.
Now cd back to the root of your working directory and run
Code:
. build/envsetup.sh
Note the period and space before build. This is an important step which initialized the build environment. Several new commands will be available now such as "mm" "mmm" "croot" amongst others. Type "help" (without the quotes) for a full list of the new commands available.
Next step to build your SystemUI is to run lunch. Just type "lunch" and press enter:
Code:
pendo:master pendo$ lunch
You're building on Darwin
Lunch menu... pick a combo:
1. full-eng
2. full_x86-eng
3. vbox_x86-eng
4. full_stingray-userdebug
5. full_wingray-userdebug
6. full_crespo-userdebug
7. full_crespo4g-userdebug
8. full_maguro-userdebug
9. full_toro-userdebug
10. full_panda-eng
Which would you like? [full-eng]
It will list the available builds. Number 8 should be for maguro-user debug. Select it and press enter. And lastly, type
Code:
make SystemUI
It will take several minutes to build, especially the first time. But once it’s done, your new SystemUI will be in out/target/product/maguro/system/app/SystemUI.apk.
Here is a SystemUI that I built that has a translucent statusbar. It also has a circle battery mod I recently made in ics blue. This was built on 4.0.3 sources.
Here's a flashable zip:
TransStatusbar-SmoothCircleMod_4.0.3.maguro-signed.zip
Smali edits
OK...here's some instructions as a smali edit. Things to keep in mind here....smali is, for me at least, challenging to follow and fully comprehend what you are looking at. Also, this set of instructions is based off of working on a SystemUI for 4.0.3. My goal here is to give precise enough steps so that the right edits are made, while also trying to be "universal" in that this will hopefully work on other SystemUI's going forward. If we discover that tweaks need to be made, I'll edit this list.
Pixel format is stored as a integer constant. To review, here are some values of interest for this thread. (blue text is value)
OPAQUE(no alpha bit): -0x1
RGB_565(also no alpha): 0x4
TRANSLUCENT(many alpha bits) -0x3
First file to edit is StatusBar.smali. Open in your preferred text editor and search for this text:
Code:
Landroid/view/WindowManager$LayoutParams;-><init>(IIIII)V
Go to the line above it and change the last value from -0x1 to -0x3.
Next open PhoneStatusBar.smali. Search for this text:
Code:
const v4, 0x4800068
replace the 2 lines underneath with this:
Code:
const/4 v5, -0x3
move v2, v1
Next search for this text:
Code:
Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPixelFormat:I
Once again we're going to edit the line above and change the last value to -0x3.
You can see the pattern of changing -0x1 to -0x3. However, you may notice that it's a 0x4 that your're replacing. You won't ever be replacing anything vastly different. So when following these instructions if you find that you're replacing something other than -0x1 or a 0x4, that should raise a red flag that it might not be the right thing to edit. *The first edit in PhoneStatusBar is a little different than the others and I think there is more than one way to do that, but this is how I did.
You may notice that I haven't listed the entire line for the search criteria ....this is because there may be differences with the local variables associated. Your file may be assigning the pixel format to local variable v8 and the next guys v9. *The first search in PhoneStatusBar I did give the whole line.
That's it for smali edits. Now you still have the res directory edits. With an aosp based rom, you need to change the hex value for status_bar_background in drawables.xml. Also, you now have translucency available for the softkey area.....it's background is set via hex color in res/layout/navigation_bar.xml.
I've been wanting a smooth circle battery mod! Only problem is, on Roman's AOKP rom flashing it makes the statusbar and virtual buttons disappear Happens with the other circle battery mod as well :/
Same here, soft buttons and status bar dissapear
Sent from my Galaxy Nexus using xda premium
This may just be me, but I got the battery only circle mod going on Romano's rom with the apex 4 kernel. Didn't work with the other kernel I was on.
awesome instructions im going to download asop on my linux pc tonight and have at the systemui on boxing day or something. ive got the softkeys themed but thats as far as i can get without a ton of fc's when decompiling and editing xml's and some pngs, so hopefully this will help me learn a bit more.
thanks for the awesome write up!
edit: i get the same problem as the above people when flashing this on the rom in my sig
pendo, thanks so much for this. its very educational and I appreciate the time you took to help all of us.
my question is...
in the cyanogenmod source instead of stating "opaque" or "translucent" it shows PixelFormat.RGB_565 which (I think) means it's 16bit and opaque. do you think it would have to then be changed to ARGB_8888, or something different? here's the link to the info I found: http://developer.android.com/reference/android/graphics/Bitmap.Config.html
I'm just unsure how to apply this info.
thanks man, love your work, glad to see you here!
Sent from my Galaxy Nexus using xda premium
I used apktool to decompile the systemui.apk. I found the status bar files. But they are smali. When I edit them with notepad+ I cannot find the PixelFormat line. Sucks.
Sent from my Galaxy Nexus using XDA App
joshnichols189 said:
I've been wanting a smooth circle battery mod! Only problem is, on Roman's AOKP rom flashing it makes the statusbar and virtual buttons disappear Happens with the other circle battery mod as well :/
Click to expand...
Click to collapse
My bad, I left out one VERY IMPORTANT detail. Whether or not you build your own or use the one I compiled it is a deodexed SystemUI.apk. If you previously had an odexed SystemUI then you MUST delete SystemUI.odex
I have been told that my apk works with this 4.0.3 IML74K rom.
gn00my said:
Same here, soft buttons and status bar dissapear
Sent from my Galaxy Nexus using xda premium
Click to expand...
Click to collapse
Please see above note.
Also, these instructions as well as the provided apk DO NOT have Paul's softkey mod. I'm hesitant to say this, but I am tinkering a bit trying to replicate the edits in source form. I know I posted a SystemUI that had those edits for 4.0.2 but I did them as smali edits. I wish to add them to the source code which would make it much easier for updates. But I have no progress report on that. The *main* purpose of this thread was informational. I wanted to offer some help for someone to either do it themselves, or help someone who has the capacity/desire to update the apk as needed.
EkostonS said:
awesome instructions im going to download asop on my linux pc tonight and have at the systemui on boxing day or something. ive got the softkeys themed but thats as far as i can get without a ton of fc's when decompiling and editing xml's and some pngs, so hopefully this will help me learn a bit more.
thanks for the awesome write up!
edit: i get the same problem as the above people when flashing this on the rom in my sig
Click to expand...
Click to collapse
This is built purely from aosp sources, not CM. I would not expect what I compiled to work on anything other than aosp 4.0.3. However, the information in the first post should help you make a translucent statusbar if the CM9 source code is available somewhere.
allofusjw said:
pendo, thanks so much for this. its very educational and I appreciate the time you took to help all of us.
my question is...
in the cyanogenmod source instead of stating "opaque" or "translucent" it shows PixelFormat.RGB_565 which (I think) means it's 16bit and opaque. do you think it would have to then be changed to ARGB_8888, or something different? here's the link to the info I found: http://developer.android.com/reference/android/graphics/Bitmap.Config.html
I'm just unsure how to apply this info.
thanks man, love your work, glad to see you here!
Sent from my Galaxy Nexus using xda premium
Click to expand...
Click to collapse
Yes, I actually had some information regarding that in the first draft I had made, however I was getting concerned with the length as it was so I trimmed it down a bit.
Yes, RGB_565 is 16bit opaque. You should just change it to TRANSLUCENT. I've done this before, but in smali. One thing that I haven't figured out is why it's called RGBA vs ARGB. The hex values are done in ARGB. Go figure.
Also, here's some info that will help when trying to do this edit backwards, aka decompiling with apktool Obviously when aapt compiles it doesn't store the code as TRANSLUCENT....but here's some of the values that it does store of what you'll most commonly see:
TRANSLUCENT = -0x3
OPAQUE = 0x1
RGBA_8888 = 0x1
RGBX_8888 = 0x2
RGB_565 = 0x4
fatsix said:
I used apktool to decompile the systemui.apk. I found the status bar files. But they are smali. When I edit them with notepad+ I cannot find the PixelFormat line. Sucks.
Sent from my Galaxy Nexus using XDA App
Click to expand...
Click to collapse
No....you cannot edit with Notepad.
my bad, I missed the "+"
Make your search for "mPixelFormat" and you should get better results. But it isn't as straight forward in smali. I'm still getting better at, but it is definitely more difficult to decipher what's happening in smali. Something that I've done to help is to compare source code with decompiled smali (making sure it's the same file).
I decompiled the classes.dex before with something else. Was easier to edit. Can't remember which or find the directions. Java - jar I think.
Sent from my Galaxy Nexus using XDA App
pendo said:
The *main* purpose of this thread was informational. I wanted to offer some help for someone to either do it themselves, or help someone who has the capacity/desire to update the apk as needed.
-Yes, I actually had some information regarding that in the first draft I had made, however I was getting concerned with the length as it was so I trimmed it down a bit.
-Yes, RGB_565 is 16bit opaque. You should just change it to TRANSLUCENT. I've done this before, but in smali. One thing that I haven't figured out is why it's called RGBA vs ARGB. The hex values are done in ARGB. Go figure.
Click to expand...
Click to collapse
-mission accomplished!
-isn't that how things always work out?
great, thank you very much! i hate having to reapply my theme edits with every rom flash. this is very helpful.
one more question...
will this edit "stick" in my local cyanogenmod workspace after a repo sync, or, would that require setting up my own github repo to view changes to cm framework vs my edited framework? please don't feel obligated to give an in depth explanation if that's what this question requires. I'd just like to know if my thinking is on the right path. thank you!
Sent from my Galaxy Nexus using xda premium
ahh that would make sense, but cm is built off asop and your last transparancy mod worked on cm9
Would anyone please show a pic with the final result? I am most interested in this mod once i get my GNex by new year.
Here you go mind of small but not a problem at all.
Sent from my Galaxy Nexus using xda premium
Neat trick. Many thanks!
did you noticed dialer status bar isn't black?..How can l fix taht?Thanks!
fatsix said:
I decompiled the classes.dex before with something else. Was easier to edit. Can't remember which or find the directions. Java - jar I think.
Sent from my Galaxy Nexus using XDA App
Click to expand...
Click to collapse
If you're including the need to download aosp source, you would be correct. But the mod itself I feel is easier in source, solely based on the fact that it's easier to read. Sure, if you're familiar with the edit and have done it before you can decompile and search for whatever key terms you wish and then make the "-0x3" edits. But by viewing the source, it's pretty obvious on where/how to make the edits.
allofusjw said:
-mission accomplished!
-isn't that how things always work out?
great, thank you very much! i hate having to reapply my theme edits with every rom flash. this is very helpful.
one more question...
will this edit "stick" in my local cyanogenmod workspace after a repo sync, or, would that require setting up my own github repo to view changes to cm framework vs my edited framework? please don't feel obligated to give an in depth explanation if that's what this question requires. I'd just like to know if my thinking is on the right path. thank you!
Sent from my Galaxy Nexus using xda premium
Click to expand...
Click to collapse
It should, or at least it does with aosp and repo. Unless the package is updated.....(I think...)
EkostonS said:
ahh that would make sense, but cm is built off asop and your last transparancy mod worked on cm9
Click to expand...
Click to collapse
Yes, CM is based off aosp but I can assure you there are some significant differences...at least for gingerbread. I would anticipate there are less differences between CM9 and ics at this stage of the game. I didn't know that my last one worked on CM9.....my guess is that whatever changed in 4.0.3 hasn't made it's way into CM9's source.
manager77 said:
did you noticed dialer status bar isn't black?..How can l fix taht?Thanks!
Click to expand...
Click to collapse
No, I didn't notice anything....I have no way to view what I built! Lol...
Well, I'm not exactly sure off the top of my head. Does anyone know if my previous SystemUI had a translucent statusbar? I should be able to figure it out pretty easily if it was...
Thanks for the info. You really got me interested in this stuff!
For Windows users (like me), I believe somebody posted a VMWare images ready to do these kind of things.
Might give it a try when I'm back from holiday.
Sent from my Galaxy Nexus using xda premium

[Q] Launcher2.apk image file edits?

Hi all,
I am trying to make a simple change to the Launcher2 desktop, I can't stand the divider line above the app drawer launcher button, which image file do I need to make transparent to achieve this?
Or is it not that simple??
Many thanks
Haven't tested, but check out res/drawable-xhdpi/divider_launcher_holo.9.png. I believe 9-patches have to be recompiled before replacing them in the APK, but I could be mistaken.
EDIT: Actually, might be hotseat_scrubber_holo.9.png and hotseat_track_holo.9.png instead.
copkay said:
Haven't tested, but check out res/drawable-xhdpi/divider_launcher_holo.9.png. I believe 9-patches have to be recompiled before replacing them in the APK, but I could be mistaken.
EDIT: Actually, might be hotseat_scrubber_holo.9.png and hotseat_track_holo.9.png instead.
Click to expand...
Click to collapse
Many thanks for this.
I am bringing this thread back to life folks as I would like to perform the same edit in Jelly Bean, but I would actually like to learn how to do it.
What are .9.png's and how do I edit them and are the files mentioned above still the same in Jelly Bean??
As I said I want to learn rather than rely on others to create mods so any help or a quick tutorial in how to remove the dock divider would be much appreciated!
Again, many thanks all!
wilskywalker said:
Many thanks for this.
I am bringing this thread back to life folks as I would like to perform the same edit in Jelly Bean, but I would actually like to learn how to do it.
What are .9.png's and how do I edit them and are the files mentioned above still the same in Jelly Bean??
As I said I want to learn rather than rely on others to create mods so any help or a quick tutorial in how to remove the dock divider would be much appreciated!
Again, many thanks all!
Click to expand...
Click to collapse
.9.png's are PNG image files that android recognizes as being stretchable, and it knows where to stretch them via the black outline around the image that can only be seen when decompiled.
.9.png's can only be edited when an apk has been decompiled, not just unzipped.
After decompilation you can use draw9patch, which is included with the Android SDK, to edit the border.
However, if you're just them(e)ing the image, you don't touch the border, as it could possibly mess things up. You really only use draw9patch to create a border on a new image.
Sent from my Galaxy Nexus using Tapatalk 2

Categories

Resources