Introducing XDA:DevCon – A Conference For Developers By Developers
XDA Developers Android and Mobile Development Forum
Forgot your password?
View Poll Results: Was this helpful?
YES!!!! Exactly what i wanted 79 81.44%
NOOO!!!! YOU SUCK 18 18.56%
Voters: 97. You may not vote on this poll

 
Post Reply+
Tip us?
 
ÜBER™
Old
(Last edited by ÜBER™; 18th July 2012 at 09:21 PM.)
#1  
ÜBER™'s Avatar
Recognized Themer - OP
Thanks Meter 7166
Posts: 12,867
Join Date: Nov 2011
Location: Marble Falls, TX

 
DONATE TO ME
Tutorial [TUTORIAL]How to Theme Your MMS

There is a pretty good guide on Rootzwiki but not one here that i have found. Also the one on Rootzwiki seems to be dated for ICS. JB has a little bit different setup. Not by much but the guide on Rootz did miss a few things. So i though i would break it down a little further and add some pictures and under linings to clear things out. This guide will assume you know how to use apktool to decompile and recompile apk's.

Requirements :
  • Android SDK
  • Apktool
  • Notepad++ or Equivalent
  • MMS.apk from your ROM

Instructions :

First Your going to want to decompile the APK. To do this you will need Apktool or some other equivalent like APK-Multi-tool.
If using Apktool use this command :
Code:
 apktool d Mms.apk
NOTE that you will need to be in your SDK folder if you do not have your SDK linked in your PATH$.

Now into the editing

Open up Res/Values/Colors.xml with Notepad++ Should look like something similar to this

The codes will not be the same as this one is already edited.

Code:
 name="text_hairline">#ff000000
This will change the color of the Send and Recvieve time stamp or any other xml that calls for this. However i will tell you how to make Send and Recieve other colors later in the tutorial.

Code:
 name="message_count_color">#ff33b5e5
Changes the Color of the Little Number next to your contacts Name on the first screen such as this.


Code:
name="unread_bgcolor">#ff33b5e5
Changes the Color of the Highlight you get when a New message is present. Same goes for the read_bgcolor.

The other xml's control the widget which i havent done yet. Now save that and close it.

Next Res/Values/Styles.xml

Look for
Code:
 name="MmsHoloTheme" parent="@android:style/Theme.Holo" />
where it says Theme.Holo you will have something like Theme.Holo.Light..... delete all that and make it reflect what my line looks like. This will get rid of the Gray bar dividers on the first screen. See second screenshot.
Save and Close it.

Next /Res/Drawable/listitem_background.xml

Look at the last line
Code:
 <item android:state_selected="false" android:drawable="@android:color/white"
Here you can either change White to Black or you can specify the color
Code:
 "#ff33b5e5"
instead of android:color/white.
If you would like a special background you will need to direct it to that Background in drawable like so
Code:
 "@drawable:name_of_background"
Once done save it and close it.

Next /Res/Layout/message_list_item_send.xml and recv.xml

These xml's control the Text color of the messages in the conversations.

This Applies to both Send and Recieve, so look for
Code:
 android:textSize="16.0sp" android:textColor="#ffffffff"
This will be right under this
Code:
 android:background="@drawable/listitem_background"
Which controls the Actual text message its self. So go ahead and change that to whatever you like i have it set for White. Now look for
Code:
 android:textColor="#ffffffff" android:id="@id/date_view" android:background="#00000000"
This will control the Timestamp you get under each text message. I have the background transparent (#00000000) and the textColor as white. Change these accordingly. Then look for
Code:
 class="com.android.mms.ui.QuickContactDivot" position="right_middle"
Yours will display right_upper and left_upper for recieve and send. Change them accordingly. Save that and close it.

Next /Res/Layout/recipients_editor.xml

Here you will want to look for this line
Code:
 <com.android.mms.ui.RecipientsEditor android:textColor="#ff33b5e5"
The text color will change the color of the text you get when editing what contact you're sending your message to. Since it will be black you will need to change it from #ff000000 to Something else.

Next /Res/Layout/Conversation_list_screen.xml

Look for this
Code:
 android:id="@android:id/list" android:background="@android:color/black"
Yours will say white and not black. You can change it to just black or you can define a color you would like.

Next /Res/Layout/Conversation_list_item.xml

Here You will need to add a textColor to lines 5, 6, and 9. It doesnt matter where but i put them at the beginning.

Should look like this
Code:
 <TextView android:textColor="@android:color/white"
Make sure to have a space between TextView and android. As well as the " and the next line. You can either use @android:color/white or define it #ffxxxxxxx.

Next /Res/Layout/Compose_message_activity.xml

This xml edits the background and text color when actually composing a message. The little box at the bottom.

Look for
Code:
android:id="@id/bottom_panel" android:background="#ff000000"
yours will be white. You can change it accordingly. This is the background of the little box where you type your message

Then
Code:
android:textSize="16.0sp" android:textColor="#ff33b5e5"
Yours will be white. Change it accordingly. This controls the color of the text when your typing.

As well as the other textColor under it
Code:
 android:textColor="#ff33b5e5"
Not too sure what it edits.. but changed it for good measure.

Save it and YOUR DONE!

recompile the apk by
Code:
 apktool b Mms
Then put it in a flashable and flash it.

For those that need a flashble you can use mine here : Empty Flashable

Just take your MMS and put it inside the /system/app folder in the flashable. Place it on your sdcard and flash it!
Nexus 4: RasSaber / Franco.Kernel
___________________________



The Following 56 Users Say Thank You to ÜBER™ For This Useful Post: [ Click to Expand ]
 
ÜBER™
Old
(Last edited by ÜBER™; 21st July 2012 at 07:14 PM.)
#2  
ÜBER™'s Avatar
Recognized Themer - OP
Thanks Meter 7166
Posts: 12,867
Join Date: Nov 2011
Location: Marble Falls, TX

 
DONATE TO ME
How to Make a Bubble MMS

This Tutorial will add-on to the other one, this will be for those a little more advanced or would like some help making their MMS all that much more better. So the instructions and requirements still apply.

So first thing you going to need to is decompile your MMS.

Code:
 apktool d Mms.apk
First /Res/Drawable/listitem_background.xml

You're going to take that xml and copy it in the same folder so you should have listitem_background.xml and listitem_background-copy.xml. Then take the listitem_background-copy.xml and rename it listitem_backgroundsend.xml needs to be this exactly.

Then open up each and take the listitem_background.xml and find the last line of code
Code:
<item android:state_selected="false" android:drawable="@drawable/recv_bg"/>
Yours will say @android:color/black you will need to change it to reflect what mine says exactly. Then go to the listitem_backgroundsend.xml and find the same line of code and make it say this
Code:
<item android:state_selected="false" android:drawable="@drawable/sent_bg" />
Yours will again say something similar to the last line, make sure to name it exactly. Save those and close em.

Next /Res/Layout/message_list_item_recv.xml and send.xml

You're going to open these two up and this will change the actual block that it uses and direct it to the new xml's. So open up recv first this one will only require one edit.

Look for
Code:
android:layout_height="@dimen/avatar_width_height" android:layout_alignParentLeft="true"
You will need to change the "true" to "false" this will keep the picture from stretching all the way to the other side of the screen and only wrap the text.
Then go ahead and open the send.xml, here we will make it direct the send image to the new xml that we made in the beginning.

Look for
Code:
android:id="@id/message_block" android:background="@drawable/listitem_background" android:layout_width="wrap_content"
You will want to rename "@drawable/listitem_background" to "@drawable/listitem_backgroundsend" this will direct it to that new xml to tell it where to grab the image. make sure to make the same edit from before changing the alightParentRight="false" . You will also want to MAKE SURE that android:layout_width="wrap_content" and not anything else, otherwise things get messy. Then save those and exit.

Now comes to the more involved part. Making the .9.png for recieve and send.

Go ahead and open up drawable-xhdpi and find the main messaging app icon. And select to edit with Gimp. IF you have gimp otherwise this part wont be very useful.. sorry.

Once thats done go ahead and go to Filters > Alpha to Logo > 3D outline. Once on that go ahead and make every number 1. By default it should be 5 10 5 make those all ones. Then make sure to hit the browse button and choose the very first box which should be white and title "clipboard". Hit okay and let it do its work. Then you will be left with a white outline and a white background. Then go up to Layers > Merge Down. Then Layers > Delete Layer. YES I KNOW IT WILL DELETE IT. Dont worry, just hit CTRL+Z twice. Then Once more hit Layers > Delete Layer and you should be left with JUST the white outline of the messaging icon. Save that or color it or whatever you want to do with it.

Now your going to need to go to your "tools" directory in the android-sdk. C:\android-sdk\tools then open select to run the draw9patch.bat it will open up a terminal then open up this giant Down arrow. Your going to want to drag and drop that image your created.


Now comes the fun part patching. This is way i do most of mine so feel free to just copy that.


I fill the bottom and the right side with a complete line on the boarder keeping in mind of where the context is on the right. And just a simple dot on the top and the left in the middle. Save that png and do it with the other one you should have made for send.

I have attached two sample's .9.pngs make sure to rename them properly.

Now rename both .9.pngs to recv_bg.9.png and sent_bg.9.png then keep those in the drawable-xhdpi folder. Close out of that folder and now build the APK.
Code:
 apktool b Mms
If everything was done correctly it will build and you should be good to go!
Attached Images
  
Nexus 4: RasSaber / Franco.Kernel
___________________________



The Following 11 Users Say Thank You to ÜBER™ For This Useful Post: [ Click to Expand ]
 
chugger93
Old
#3  
chugger93's Avatar
Senior Member
Thanks Meter 83
Posts: 1,172
Join Date: Nov 2009
Location: Michigan
This is really cool UBER, thanks for this. I flashed a theme on here, but I wanna make some slight alterations to it. Is there a way to customize the actual message when it says "SENDING" ? Its too dark blue for me. Or maybe that code fits into another bit of code that I'd have to change.

I guess in the meantime, I'll download what I need and go from there. Also, how do you make the APK flashable? You just zip the APK, or what? Thanks again
Jon
- Samsung Galaxy Nexus | JellyBro/Franco Kernel
- Google Nexus 10 | Sentinel Rom w/Trinity
 
ÜBER™
Old
#4  
ÜBER™'s Avatar
Recognized Themer - OP
Thanks Meter 7166
Posts: 12,867
Join Date: Nov 2011
Location: Marble Falls, TX

 
DONATE TO ME
Quote:
Originally Posted by chugger93 View Post
This is really cool UBER, thanks for this. I flashed a theme on here, but I wanna make some slight alterations to it. Is there a way to customize the actual message when it says "SENDING" ? Its too dark blue for me. Or maybe that code fits into another bit of code that I'd have to change.

I guess in the meantime, I'll download what I need and go from there. Also, how do you make the APK flashable? You just zip the APK, or what? Thanks again
Hmm sending it controlled by the text color for the send.XML where you edit the textColor. So there is no way to change just that.

To make a flashable you would need to know how to make an update script. I will post an empty zip that you can place your MMS.APK into later.

Sent From My Toro+ via SkyBlue Tapatalk
Nexus 4: RasSaber / Franco.Kernel
___________________________



 
chugger93
Old
#5  
chugger93's Avatar
Senior Member
Thanks Meter 83
Posts: 1,172
Join Date: Nov 2009
Location: Michigan
ok thanks. I'm still trying to figure out how to get mms.apk from my system/app folder to my sdcard so I can move it over to my computer. I've always had this problem and never knew how to fix it. Everytime I use root explorer, copy it over to my storage/sdcard or even mnt/sdcard or whatever it is, then plug in my usb cable and look in the directory I put it...its never there! NEVER. lol

Also, is there any way to BOLD items too, too make em more apparent?
Jon
- Samsung Galaxy Nexus | JellyBro/Franco Kernel
- Google Nexus 10 | Sentinel Rom w/Trinity
 
ÜBER™
Old
#6  
ÜBER™'s Avatar
Recognized Themer - OP
Thanks Meter 7166
Posts: 12,867
Join Date: Nov 2011
Location: Marble Falls, TX

 
DONATE TO ME
Quote:
Originally Posted by chugger93 View Post
ok thanks. I'm still trying to figure out how to get mms.apk from my system/app folder to my sdcard so I can move it over to my computer. I've always had this problem and never knew how to fix it. Everytime I use root explorer, copy it over to my storage/sdcard or even mnt/sdcard or whatever it is, then plug in my usb cable and look in the directory I put it...its never there! NEVER. lol

Also, is there any way to BOLD items too, too make em more apparent?
You can just do this if you have adb setup.

Code:
 abd remount
Then
Code:
 adb pull /system/app/Mms.apk
Sent From My Toro+ via SkyBlue Tapatalk
Nexus 4: RasSaber / Franco.Kernel
___________________________



 
chugger93
Old
(Last edited by chugger93; 18th July 2012 at 08:21 PM.)
#7  
chugger93's Avatar
Senior Member
Thanks Meter 83
Posts: 1,172
Join Date: Nov 2009
Location: Michigan
worked, and I decompiled it. This is fun! Could I just as well, recompile and push it back to system/app instead of making it flashable?

Also can't recompile, getting this error:

Quote:
F:\AndroidSDK10\platform-tools>apktool b Mms
I: Checking whether sources has changed...
I: Smaling...
I: Checking whether resources has changed...
I: Building resources...
invalid resource directory name: F:\AndroidSDK10\platform-tools\Mms\res/values-s
w600dp
invalid resource directory name: F:\AndroidSDK10\platform-tools\Mms\res/values-s
w600dp-land
Exception in thread "main" brut.androlib.AndrolibException: brut.common.BrutExce
ption: could not exec command: [aapt, p, -F, C:\Users\jbilliau\AppData\Local\Tem
p\APKTOOL367088481466692170.tmp, -I, C:\Users\jbilliau\apktool\framework\1.apk,
-S, F:\AndroidSDK10\platform-tools\Mms\res, -M, F:\AndroidSDK10\platform-tools\M
ms\AndroidManifest.xml]
at brut.androlib.res.AndrolibResources.aaptPackage(An drolibResources.jav
a:193)
at brut.androlib.Androlib.buildResourcesFull(Androlib .java:301)
at brut.androlib.Androlib.buildResources(Androlib.jav a:248)
at brut.androlib.Androlib.build(Androlib.java:171)
at brut.androlib.Androlib.build(Androlib.java:154)
at brut.apktool.Main.cmdBuild(Main.java:182)
at brut.apktool.Main.main(Main.java:67)
Caused by: brut.common.BrutException: could not exec command: [aapt, p, -F, C:\U
sers\jbilliau\AppData\Local\Temp\APKTOOL3670884814 66692170.tmp, -I, C:\Users\jbi
lliau\apktool\framework\1.apk, -S, F:\AndroidSDK10\platform-tools\Mms\res, -M, F
:\AndroidSDK10\platform-tools\Mms\AndroidManifest.xml]
at brut.util.OS.exec(OS.java:83)
at brut.androlib.res.AndrolibResources.aaptPackage(An drolibResources.jav
a:191)
... 6 more
Jon
- Samsung Galaxy Nexus | JellyBro/Franco Kernel
- Google Nexus 10 | Sentinel Rom w/Trinity
 
ÜBER™
Old
#8  
ÜBER™'s Avatar
Recognized Themer - OP
Thanks Meter 7166
Posts: 12,867
Join Date: Nov 2011
Location: Marble Falls, TX

 
DONATE TO ME
Not sure about that error... mine recompiles just fine.. and the tutorial never touches that folder. /res/values-sw600p . Did you update your SDK for jelly bean? Also do you have a jelly bean framework for resource?
Code:
 apktool if framework-res.apk
<- ?
Nexus 4: RasSaber / Franco.Kernel
___________________________



 
chugger93
Old
#9  
chugger93's Avatar
Senior Member
Thanks Meter 83
Posts: 1,172
Join Date: Nov 2009
Location: Michigan
says framework installed to C:\users\myname\apktool\1.apk

but my 3 or 4 apktool files I put in the windows directory. I dont remember why, maybe cause I read you should or had too.

I was researching and got it to compile with java -jar apktool.jar b Mms.apk but the apk is nowhere to be found. Besides, I don't like that way because it just sounds wishy washy....I'd rather do it your way.

I guess I'm just not installed or setup properly to do this is what it boils down too.

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

actually just now got it to compile using your methods. Put all the files with the 1.apk framework in apktools.

However the APK is nowwhere to be found!
Jon
- Samsung Galaxy Nexus | JellyBro/Franco Kernel
- Google Nexus 10 | Sentinel Rom w/Trinity
 
ÜBER™
Old
#10  
ÜBER™'s Avatar
Recognized Themer - OP
Thanks Meter 7166
Posts: 12,867
Join Date: Nov 2011
Location: Marble Falls, TX

 
DONATE TO ME
Quote:
Originally Posted by chugger93 View Post
says framework installed to C:\users\myname\apktool\1.apk

but my 3 or 4 apktool files I put in the windows directory. I dont remember why, maybe cause I read you should or had too.

I was researching and got it to compile with java -jar apktool.jar b Mms.apk but the apk is nowhere to be found. Besides, I don't like that way because it just sounds wishy washy....I'd rather do it your way.

I guess I'm just not installed or setup properly to do this is what it boils down too.

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

actually just now got it to compile using your methods. Put all the files with the 1.apk framework in apktools.

However the APK is nowwhere to be found!
The APK will appear in the dist folder inside the Mms folder it creates after decompiling.
Nexus 4: RasSaber / Franco.Kernel
___________________________




 
Post Reply+
Tags
how to theme your mms apk for jelly bean
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...