Related
Always perform a nandroid backup before attempting any mods.
This is a tutorial on how to change the music widget to the one of your liking. It doesn't matter if you have the Dude build and want the G build widget or have the G build and want the 1.5Hr1 widget. This will work for any cupcake (Android 1.5) user who is not happy with their current music widget. I use a windows PC and I am not a Linux guru so I'm not going to attempt to tweak my tutorial for Linux users. Hopefully it's not to hard for them to figure it out from this. (I think it's just file path differences, maybe?)
First step is to have ADB commands working on your computer. Follow this link if you don't know how to do this.
http://forum.xda-developers.com/showthread.php?t=502010
Now that you have ADB, you have to download the appropriate music player/widget that you prefer.
This one is for installing the dark blue music widget with the off-center play/pause button and the transparent record and needle logo. My personal favorite for looks, but has a play/pause with a easy to miss touch area.
http://rapidshare.com/files/227653807/Music_fancy_widget_G_build.apk
This one is for installing the plain white and pale blue music widget with rectangular shape and the large play/pause button with it's large touch area.
http://rapidshare.com/files/227653907/Music_standard_build.apk
This third option is for future development. You can "harvest" a third music widget/player from a third source that doesn't yet exist using the ADB pull command. Lets say your using build X, but build Y has a theme available and you love the themed music widget on themed build Y. What you do is perform a nandroid backup of your current build so you can return to it later and install build Y and then theme it. (Don't waist your time setting up your settings because you won't be on this build for long. Just make sure USB debugging is enabled in settings > Applications > Development so you can use ADB.) You can skip this step if you have access to a friends phone who's already running the music player/widget you want. Connect the USB cable to the phone and go into where you run your ADB commands in Command Prompt on your PC. Type in this command.
adb pull system/app/Music.apk c:\your_path_here
Click to expand...
Click to collapse
The "system/app/Music.apk" part of the command is case sensitive. This will create the Music.apk with the widget you want at the path you specify. Next you can use Fastboot to restore your nandroid backup of build X. (Nandroid saves everything. It's as if you never left.)
Next step is to rename the downloaded file "Music.apk". It's case sensitive and take note of the folder path it's in.
Next, enter the following ADB commands from the appropriate place in Command Prompt. (Start > Run > type "cmd")
adb remount
adb shell rm -r system/app/Music.apk
adb push c:\your_path_here\Music.apk system/app
Click to expand...
Click to collapse
"system/app/Music.apk" and "system/app" parts are both case sensitive.
saying no such directory, would apps to sd card cause that, and ifso what would i instead need to put in?
i never knew there was a difference between the music widgets...
whats different about them?
the gui??
pgiuoco said:
saying no such directory, would apps to sd card cause that, and ifso what would i instead need to put in?
Click to expand...
Click to collapse
On the last step, adb push, dont just put your directory, put in the file name also, Music.apk. For example, i put the file on my C directory to make it easy, so I typed "adb push c:\Music.apk system/app" without the "".
FYI - I have Apps2SD and I used the above command. Guess that doesn't make a difference, assuming because the symlinks say so? I'm such a Linux noob!!!!
bigballa said:
i never knew there was a difference between the music widgets...
whats different about them?
the gui??
Click to expand...
Click to collapse
Yes, different looking gui, the Dark Blue is very nice!
P.S. Nice write up!
setzer715 said:
On the last step, adb push, dont just put your directory, put in the file name also, Music.apk. For example, i put the file on my C directory to make it easy, so I typed "adb push c:\Music.apk system/app" without the "".
Click to expand...
Click to collapse
Wow, that was a BIG OOPS! Thanks for catching that. I fixed the original post.
Has anyone found a way to do this via Terminal Emulator? I'm at work so I wanna do this now instead of waiting till I get home.
djdeviance said:
Has anyone found a way to do this via Terminal Emulator? I'm at work so I wanna do this now instead of waiting till I get home.
Click to expand...
Click to collapse
I'm not a frequent Linux user, but I know a couple of commands. You could download the apk file to your sdcard and try this. This method is not recommended!
su
rm -r system/app/Music.apk
Click to expand...
Click to collapse
This will delete your old music player. Next, you can just install the new music player apk through Apps Installer or whatever you use in it's place. This will allow you to use the new music player as if it was any other 3rd party app. However, I recommend uninstalling it and doing it through the ADB push when you get home.
yeah the app installer method didn't work for me
pgiuoco said:
yeah the app installer method didn't work for me
Click to expand...
Click to collapse
Did you delete the original Music.apk first? Do you have cupcake, or are you using JF RC33 like it says in your sig? This music player has a widget embedded and needs cupcake. If neither of these is the problem, then just use the adb push commands in the first post. I don't recommend using apk installer. I just posted that to help out someone who was too impatient to get home to his pc.
testing567 said:
Did you delete the original Music.apk first? Do you have cupcake, or are you using JF RC33 like it says in your sig? This music player has a widget embedded and needs cupcake. If neither of these is the problem, then just use the adb push commands in the first post. I don't recommend using apk installer. I just posted that to help out someone who was too impatient to get home to his pc.
Click to expand...
Click to collapse
Haha ended up doing it at home anyways. =D Yeah i was kinda doing nothing at work. So as usual I started fidgeting with my phone.
the steps given in the first post work perfectly...!!!
i am on ADP1.5H A2SD...Gud Work...THNX..!!
If someone could post screenshots of the different UIs, that'd be great.
For some reason, when I pushed the Music.apk it worked fine, but when I tried to do the same thing with the CalendarProvider.apk, it didn't....
This method works for me as well. How do you take screenshots with the new builds?
CalendarProvider.apk... Just do a normal .apk installation.
Does this only work for Rooted phones as when I try it I get permission denied
Code:
C:\android\tools>adb shell rm -r system/app/Music.apk
rm failed for system/app/Music.apk, Read-only file system
C:\android\tools>adb shell
$ su
su
su: permission denied
$
jayaustn said:
If someone could post screenshots of the different UIs, that'd be great.
Click to expand...
Click to collapse
i second this idea
moosefist said:
i second this idea
Click to expand...
Click to collapse
I third it
music.apk
can someone post some different download links for the two different music.apk builds? rapidshare has always hated me and will still not let me download either of them saying that my ip address is already downloading something. thanks.
Can someone post pics of all the music widgets in order to compare them?
I have read and still don't understand how to add back apps like Sprint TV. I have them all saved on my computer I just do not know the commands to get them back into the phone. Do the apps I want to ad back need to be in a certain dir on my computer first. If someone could explain or either point me to a thread that explains this I would really appriciate it.
Seems I found an easy way to add sprints, htc's apps back into the phone once removed. I saved all of them on my computer and used HTC Sync to install the app back. I removed Nscar as a test using root manager, rebooted and it was gone, then opened up HTC synch and added it back. Not sure how to get the odex files back in but it works with apk files.
AFter testing it om HTCfootprints it would not install this. Installed Nscar with no problems.
I am also trying to figure out how to add sprint tv back onto my Hero. I see that people are saying to use adb push, but I can't seem to get it to work. I just rooted with the new fresh rom and everything is great, I just want to add back sprint tv. Any help would be appreciated, thanks
Im a total noob, but I got it the apps back on this way:
Go to the directory where the ADK Tools directory is. Then the following commands:
adb shell
su
mount -o rw,remount -t yaffs2 /dev/block/mtdblock3 /system
chmod 777 /system
chmod 777 /system/app
exit
exit
Then I copied the .apk files that I wanted to push to the tools directory
I am in.
Then did this:
adb push Sprint_TV.apk /system/app
I found it is case sensitive, so make sure you type the filename exactly.
I rebooted my phone and the apps (such as Sprint TV) were back.
I hope this helps, like I said, I spent an hour trying to figure it out, but this worked for me.
I would not recommend doing a chmod 777 on your system or app directory. Not that anything bad will necessarily happen, but it's generally not a good idea to mess with system file permissions when you don't have to.
Your procedure would work fine without those commands at all, in fact. You don't even need to enter the shell; just adb remount and then adb push.
those instructions worked perfectly. Thanks a ton.
I tried this with HtcFootprints. I removed the widget as well. When I added all 4 back in I can see the widget for footprints, but the footprint icon does not show up in the apps section.
Another thing of intrest. When I added Nscar back using HTC Sync, it now shows up as a third party app. It is no longer a system app and I can uninstall it like a market app.
Ok scratch that I did the Footprints again and the Icon is now there Thanks a Ton
I was able to push HtcTwitter.apk and .odex. i cannot get the widget to show up in the add HTC widgets menu. Any ideas?
Well, after trying my hand at update/rom modding with some success... I'm willing to take a shot at making update.zip files to easily flash individual stock apps back onto your phone. That's if there's any interest.
obelisk79 said:
Well, after trying my hand at update/rom modding with some success... I'm willing to take a shot at making update.zip files to easily flash individual stock apps back onto your phone. That's if there's any interest.
Click to expand...
Click to collapse
That would be great and very helpful to many
Easy Peasy App Install
I just copied the files to my SD card. I then browsed to the SD card folder using Linda File Manager and "clicked" the file. It asked me if I wanted to use Linda File Manager or Package Installer. I selected Package Installer and it proceeded to installed the package for me. Not need to get into the console or use any commands.
VOILA!
I had a mod done to my widgetlocker apk , but i cant adb push it. Can someone please sign it for me so i can install using root explorer? Im not sure how difficult it is , so if its insanely hard or something im sorry for asking haha . Thanks .
Get apkmanager and it will sign it for you. Plus apk manager will let you decompile and recompile then sign so you can mod anything and it's a whole lot easier.
Sent from my Incognito Droid using Tapatalk
1. Add your JDK Directory to the Path variable (Right click on My Computer, Properties, Advanced, Environment Variables)
2. At the command prompt, navigate to the containing folder
3. keytool -genkeypair
4. jarsigner -verbose APPNAME.apk mykey
5. Push the signed app
sorry guys but im not real sure what a JDK directory is or anything. I didnt do the mod myself. i made a donation and had it done by someone on here. Once they returned it to me via email they told me to adb push it.. but i do not have any exp doing that and was hoping someone could help me out... there would be a nicely themed widgetlocker.apk in it for you haha
Different problem, same answer.
I have been trying to install a custom framework res for a while now. I am on a Mac. I simply have been changing ext to zip, unzipping, making changes, rezipping, using mv command in terminal to change to apk, and pushing to phone. It hasn't even kind of worked. Could someone please help? Are there any steps I'm missing? Do I need to sign the framework res apk?
Please help
lucas.scott said:
I had a mod done to my widgetlocker apk , but i cant adb push it. Can someone please sign it for me so i can install using root explorer? Im not sure how difficult it is , so if its insanely hard or something im sorry for asking haha . Thanks .
Click to expand...
Click to collapse
Post it or post a link to it and I'll sign it.
That said, if you modify one apk it is highly unlikely you will not modify others (which is a good thing). Therefore, I would highly recommend getting acquainted with the proper tools.
First you will need to install the Android SDK on your computer. Here is the link:
http://developer.android.com/sdk/index.html Bear in mind that to use it you will also need to install the JDK (Java Developers Kit) on your computer but the links are in the instructions so it is very easy.
In addition to the SDK download 7zip if you do not already have it. It is a free archive utility that enables opening and editing the contents of archives without extracting them.
Lastly, if you just plan on editing images download Stericson's autosign tool so that once you finish changing images you can resign the apk which is necessary to install. However, if you want to delve a little deeper into apps I highly recommend Apk Manager. Not only does it include a signing tool but can also decompile apks so that you can do deeper editing.
dkdude36 said:
I have been trying to install a custom framework res for a while now. I am on a Mac. I simply have been changing ext to zip, unzipping, making changes, rezipping, using mv command in terminal to change to apk, and pushing to phone. It hasn't even kind of worked. Could someone please help? Are there any steps I'm missing? Do I need to sign the framework res apk?
Please help
Click to expand...
Click to collapse
The framework-res.apk does not need to be resigned. In fact, there are few, if any, reasons why any system app would need to be resigned. Therefore, that should not be your issue.
That said, in the steps you listed above I see several areas which could problems so, it would be beneficial if you provided more information. Here are my initial comments:
1)When you are rezipping the apk are you recompressing the folder created when you unzipped the apk OR, are you selecting the contents of the folder (e.g. AndroidManifest.xml, res folder, etc. ) and compressing them? It is important to do it the second way I described.
2)No need to bother with the mv command as you are using it. Once you've rezipped the apk (it will likely be named Archive.zip) you will need to rename it "framework-res.apk" at which point you should only need to push the apk back to the phone. The process would go like this:
a)put modified framework-res.apk into the tools folder (located in the SDK folder)
b)open up terminal.app
c)type "cd " (without the quotes) and drag the tools folder located in the sdk folder into the terminal terminal window, and press Enter
d)type "./adb remount" (without the quotes) and press Enter
e)type "./adb push framework-res.apk /system/framework/" (without the quotes) and press Enter
f)type "./adb reboot" (without the quotes) and press Enter. (The phone will reboot which is necessary to see your changes)
g)Marvel at your accomplishment
Obviously, you should make a nandroid backup of your phone first so that in case you mess anything up you can restore it as if nothing happened.
If you have any more questions simply post them and I'd be happy to answer them. I bought and rooted my EVO the day it first came out which was before there were any Mac tutorials and have since become fluent in adb due to lots of trial and error.
could you possibly help me with my widgetlocker apk? i have adb pushed ( finally learned how to do that on mac) and it still wont install . have contacted ultralynx (he did the mod) but im not getting a response...thank you .
lucas.scott said:
could you possibly help me with my widgetlocker apk? i have adb pushed ( finally learned how to do that on mac) and it still wont install . have contacted ultralynx (he did the mod) but im not getting a response...thank you .
Click to expand...
Click to collapse
Hmmm... If ultralynx did the mod for you it is probably already signed. I've seen some of his threads and he clearly knows what he is doing. And, signing is apk-modding-101.
Where did you ./adb push the widget locker to? /system/app/ or /data/app/? Adb push does not install the apk if you push to /data/app/
My recommendation would be to do the following:
1)Using root explorer, find and delete the widgetlocker.apk from wherever you adb pushed it on your phone. Exit out of Root Explorer.
2)Reboot phone
3)Confirm that you don't have any previously installed versions of WIdget Locker on your phone. From your home screen press the menu button and navigate to Settings-->Applications-->Manage Applications-->All and look for Widget Locker. If you find it select and uninstall it.
4)Assuming the modified widget locker.apk was signed you should not need to mess with adb. You certainly can but it is not necessary and I'd hate to confuse you with the commands. So... Instead, connect the EVO to your computer and mount as disk drive. Put the widget locker.apk you want to install on your sdcard. Personally, I would recommend creating a folder named Apps and putting it in there.
5)Unmount phone as disk drive and unplug phone from computer
6) Using any file manager (Root explorer is fine) navigate to the apk on your sdcard and select install.
If that doesn't work let me know
Found problem, need answer
okolowicz said:
The framework-res.apk does not need to be resigned. In fact, there are few, if any, reasons why any system app would need to be resigned. Therefore, that should not be your issue.
That said, in the steps you listed above I see several areas which could problems so, it would be beneficial if you provided more information. Here are my initial comments:
1)When you are rezipping the apk are you recompressing the folder created when you unzipped the apk OR, are you selecting the contents of the folder (e.g. AndroidManifest.xml, res folder, etc. ) and compressing them? It is important to do it the second way I described.
2)No need to bother with the mv command as you are using it. Once you've rezipped the apk (it will likely be named Archive.zip) you will need to rename it "framework-res.apk" at which point you should only need to push the apk back to the phone. The process would go like this:
a)put modified framework-res.apk into the tools folder (located in the SDK folder)
b)open up terminal.app
c)type "cd " (without the quotes) and drag the tools folder located in the sdk folder into the terminal terminal window, and press Enter
d)type "./adb remount" (without the quotes) and press Enter
e)type "./adb push framework-res.apk /system/framework/" (without the quotes) and press Enter
f)type "./adb reboot" (without the quotes) and press Enter. (The phone will reboot which is necessary to see your changes)
g)Marvel at your accomplishment
Obviously, you should make a nandroid backup of your phone first so that in case you mess anything up you can restore it as if nothing happened.
If you have any more questions simply post them and I'd be happy to answer them. I bought and rooted my EVO the day it first came out which was before there were any Mac tutorials and have since become fluent in adb due to lots of trial and error.
Click to expand...
Click to collapse
Thanks for the help okolwoiz. I am fluent in adb and have been hacking for a while. I think I know the problem. The mod I was trying to theme (drop down notifications bar) is a .9.png, which means it is automatically resized to fit the phone. These are different than normal .png files. I know i need to use a draw9 something file in the sdk, but I don't know how. Any help would be great. Thanks
Dk
yeah i have tried all of that . It always just says "Application not installed" . No matter how i get it on the phone . ore than happy to send it to you to see if its the file or my phone .
Thanks this thread has helped me and I was just wondering through aimlessly.. And stumbled upon tis thread.
Sent from my netarchy_toast, froyo beast of a machine evo!
glad it helped someone haha
Ok here's one to all the ppl that didnt manage to get it to work like me (HTC desire). My phone is only rooted with revoked, no custom roms etc.
Ive read a lot of forums and i've seen a lot of people that didnt manage to get it to work. After spending nights trying to get it to work is was getting frustrated. All i read was about pushing the file to /system/media or /system/data, but after spending some time looking through all the folders with root explorer i found the actual default bootanimation.zip file.
IT WAS LISTED UNDER /system/customize/resource
so i rebooted my phone in recovery mode:
- mounts and storage
- mount /system
- in cmd: adb shell rm /system/customize/recource/bootanimation.zip
- in cmd: adb push bootanimation.zip /system/customize/resource/bootanimation.zip
note: for this exact command to work u need to have the bootanimation.zip in your androidsdk/tools folder. If not u need to change the push command to adb push <the location here(i.e. d:\downloads\bootanimations\bootanimation.zip)> /system/customize/resource/bootanimation.zip
(this didnt work if i had the file on the c drive of my pc and i would get an error, unless it was in the c:\androidsdk\tools folder, it would work on a 2nd partition, ext storage or whatever)
Only 1 thing... in that same file there prolly still is an audio file, cous when i boot i get my customized bootanimation, but still the standard boot sound. I will be looking in to this now.
If ppl could confirm this works for them aswell i would be happy
EDIT: the bootmusic is listed in the same folder as the bootanimation. It's named android_audio, so you probably wanna remove this aswell (using the command adb shell rm /system/customize/resource/android_music.mp3). Im not sure if you can change this, and since i didnt backup the default bootanimation.zip im dont know if there was someting diffirent about is that would make the music play. I would appreciate if someone could adb pull the original files for me and post em
another note, if you'r making your own bootanimation.zip's make sure compression is set to 0 (store or save)
on my dutch version of winrar its listed under 'ìnpakmethode' -> 'opslaan'
I'd really like to help you out and pull the plain bootanimation (there's no sound actually) from the (custom) rom I'm using but I just can't (see screenshot). If you give me some guidance I can do that, but I do wanna wipe my current one! Please note I recently got S-Off and I'm in Recovery with /system mounted (it says "click to unmount" so it should be good, shouldn't it? Anyway I tried the other way and it's the same... )
well yours might be in the /system/media or /data/local folder. You can always use a file explorer on the phone to find out where yours is located or use adb shell ls /system and check folders if it actually is there.
i r still a noob with all this so i got no clue what s-off is
Ok I got to find and replace the bootanimation.zip file (the only one I could fine on the phone, anyyway) with different ones I got in the forums (Desire bios-like and Star Wars Droid) but I get no animation at all... I mean, I reboot and get the initial still image and the old nexus animation after that is gone, black screen instead, and then Android loads. Any thought maybe? And I'd really like to know how to completely wipe Google Maps/Brut from my phone (don't know the actual files, I got Gmail.apk and I succeeded but the jar's I found for maps weren't enough, I suppose, as I can't install the updated version from the Market, just like I had with Gmail before removing the apk and I solved doing that).
So your still getting the standard animation? Did you use the adb command with the phone in recovery mode to delete and push the new one in?
hy5eyhe5yh
hteherhyeyhey
not bad,i hood you
ToWi1989 said:
So your still getting the standard animation? Did you use the adb command with the phone in recovery mode to delete and push the new one in?
Click to expand...
Click to collapse
Actually I'm getting black screen, no animation... only the first still image (green HTC on white background, you know). And yes, I pulled the original, rm the old one and pushed the new one, in Recovery, with /system mounted.
did u try to make ur own and failed at compressing the .zip ? Or did u just download a standard one off the internet?
Also did u make sure the file u pushed actually is there, in the right folder?
I'm trying to use my new Sensation with the SIM from my Japanese iPhone, which requires replacing the stock Mms.apk with one that works with Softbank. That much I managed to do. Now when I try to open the Messaging app it crashes immediately, which is apparently normal and means I need to delete the old Mms.odex. But when I try, the command prompt window tells me:
rm failed for /system/app/Mms.odex, No such file or directory
I've made sure the folder isn't read-only (I managed to copy the new Mms.apk to it after all). Not sure what else could be going wrong. Thanks in advance for any help.
Its not a good idea to push files into the system directory of an odexed ROM like that. You usually need to push the appropriate .odex file with the .apk file.
Also could be a permissions problem. You need to make sure the permissions for the new file the are same as what's already in the directory.
Sent from my Sensation using Cyanogenmod
dr.m0x said:
Its not a good idea to push files into the system directory of an odexed ROM like that. You usually need to push the appropriate .odex file with the .apk file.
Click to expand...
Click to collapse
I know it's not ideal, but this method seems to work just fine; I've read a bunch of Japanese blogs that explain this is how to get MMS working with Softbank, and people on forums elsewhere say it's worked for them.
dr.m0x said:
Also could be a permissions problem. You need to make sure the permissions for the new file the are same as what's already in the directory.
Click to expand...
Click to collapse
How do I do that? I'm pretty new to all this, two days ago I was Googling where to find my Sensation's settings menu
If you want to ensure the mms.apk has correct permissions you can simply run:
adb shell chmod 644 /system/app/mms.apk
This will set the correct permissions for apps in the /system/app folder, although its worth reading up on linux permissions to understand what the command is actually doing.
Permissions didn't help, but I've managed to track down another Mms.apk file that works well enough - messages don't integrate properly with HTC's Messaging app, but I can send and receive MMS. I'm going to keep looking for a better apk but at least this one functions!