FORUMS

Index Project For XDA Device Subforums

Another ambitious project from the collaborative efforts of Recognized Contributors and Forum … more

The Atlas of XDA

A few weeks ago, we asked you “How Does Your Location Affect Your Life As A Power User?”. In the days that … more

New Snapdragons: Some Context & Contrast

It hasn’t been a good year for Qualcomm so far. Every device featuring the Snapdragon 810 … more

Google To Launch Next Gen Android One On July 14

The first gen of Android One devices to be launched in India in September 2014 were … more

[DPI] Dialer, MusicPlayer, Calc, FM, Camera + GUIDE +utility(kinda)

1,399 posts
Thanks Meter: 457
 
By xan, Retired Recognized Developer on 6th December 2010, 11:42 PM
Post Reply Subscribe to Thread Email Thread
Hello, you all know that when you change screen density in build.prop a problem with some apps appears.

[MultiDPI]GalaxySpack-CWM.zip contains Dialer, Music Player, FMRadio, Calculator
all modded to support multiple DPI
You can just flash this via CWM or extract individual APKs and replace them in /system/apk/
Newest: Camera.apk
Video Player
How to do it yourself? (example on DialerTabActivity.apk)
* its quite easy, if you want do fix any app you need to know how to edit .xml files, have some basic knowledge about android layout files. If you just want to repack Dialer its easier, because I supply the layout file you just need to recompile the file with apkmanager replacing one of layout files
- download layout_resize.zip file attached (you are welcome to improve the app);
- download APK Manager;
*optional step, not sure if its needed: get framework files from your device and goto apk_manager_4.9\other and install framework files:
Code:
java -jar apktool.jar if "[dir]\apk_manager_4.9\twframework-res.apk"
Code:
java -jar apktool.jar if "[dir]\apk_manager_4.9\framework-res.apk"
- copy DialerTabActivity.apk from your device to "\apk_manager_4.9\place-apk-here-for-modding"
- start script.bat and select decompile apk (if it doesnt work you probably need to do optional step and then try with dependencies, skipping part where it asks for apks)
* now there comes my small commandline java utility - it resizes (replaces hardcoded dip values with 1,5 times bigger rounded px values) layouts in files passed by commandline.
-copy .xml files you want to modify to its dir;
-invoke by (or just use convert_all.bat, now working, thanks Einride!) (windows!):
Code:
for /f %a IN ('dir /b *.xml') DO call java LayoutResizer %a
(idk why resize_all.bat doesnt work)
- modified files are in converted directory, you need to copy them over files in apk_manager_4.9\res\

- hit compile apk
- select yes for system apk and yes for min # of errors
- delete \apk_manager_4.9\keep\resources.arsc and \apk_manager_4.9\keep\res\layout\dialer_app.xml (and any other xml file corresponding to one you have modified
- hit any key
- the apk you need to copy back to your phone is \apk_manager_4.9\place-apk-here-for-modding\unsignedDialerTabActivity.apk

If any rommakers would like to include these apks feel free to do so
Also you are welcome to fix remaining apps including:
-clock
-calendar
-allshare


kudos:
APKTOOL + SIGNAPK authors
APKMANAGER author
Attached Files
File Type: apk TouchWizCalculator.apk - [Click for QR Code] (494.4 KB, 1085 views)
File Type: apk DialerTabActivity.apk - [Click for QR Code] (935.7 KB, 739 views)
File Type: zip dialer_app.zip - [Click for QR Code] (1.5 KB, 873 views)
File Type: zip [MultiDPI]GalaxySpack-CWM.zip - [Click for QR Code] (7.23 MB, 1862 views)
File Type: zip layout_resize.zip - [Click for QR Code] (5.2 KB, 1058 views)
Last edited by xan; 11th January 2011 at 11:29 PM.
The Following 20 Users Say Thank You to xan For This Useful Post: [ View ]
 
 
7th December 2010, 06:53 AM |#2  
ragin's Avatar
Senior Member
Flag Hubli
Thanks Meter: 154
 
More
Quote:
Originally Posted by xan

Hello, you all know that when you change screen density in build.prop a problem with some apps appears. On my first attempt to correct that:
Modded TW calculator (which i kinda like), to work with 200dpi density.
It may not be pixel perfect but hell it works

kudos:
APKTOOL + SIGNAPK authors

So, this is for people who change the screen density to 200 dpi, right?
7th December 2010, 07:53 AM |#3  
Jumba's Avatar
Senior Member
Flag Johannesburg
Thanks Meter: 514
 
Donate to Me
More
This is a great idea! Do you take requests?
7th December 2010, 08:01 AM |#4  
KLoNe1's Avatar
Senior Member
Flag Brisbane
Thanks Meter: 84
 
Donate to Me
More
Such a great idea! I'm on 170 density, but i'll give this a go anyway.
You'll become loved if you end up doing this to all the apps that don't scale correctly!

Sent from my GT-I9000 using XDA App
7th December 2010, 08:41 AM |#5  
torres76's Avatar
Senior Member
Flag Reading
Thanks Meter: 60
 
More
The dialler is the main one.

Sent from my GT-I9000 using XDA App
7th December 2010, 10:07 AM |#6  
Member
Thanks Meter: 1
 
More
Hello,

How do you change the screen density?
7th December 2010, 10:54 AM |#7  
torres76's Avatar
Senior Member
Flag Reading
Thanks Meter: 60
 
More
Quote:
Originally Posted by kevnangel

Hello,

How do you change the screen density?

Hi you have to be rooted download lcddensity from the market.
7th December 2010, 12:09 PM |#8  
xan's Avatar
OP Retired Recognized Developer
Flag Crack-ow
Thanks Meter: 457
 
Donate to Me
More
Yes, this is for those who changed density to 200 or less (still looks better than stock one).

This was just a proof of concept, the main aim is to mod Phone.apk. At this stage I'm able to repack it, but due to its complexity and the fact its system apk, I'm doing something wrong. This needs more time, but I will try to figure it out today.

And yes, Samsung's layout files are a mess. Phone.apk >40 layout files.

No requests, since its kind of time demanding task, you can post list of STOCK apps that dont scale well for reference. After I'm done with Phone I'll write some guide.
Last edited by xan; 7th December 2010 at 12:12 PM.
13th December 2010, 03:05 PM |#9  
DistortedWisdom's Avatar
Senior Member
Flag Jeddah
Thanks Meter: 27
 
More
Thanks for the great modification. I tried to onstall it on my Galaxy tab and it actually worked. Not perfect for the tab but Hey it works atleast, however, it keeps forcing close everytime i try to go landsacpe! It would be excellent if you would fix this cheers
13th December 2010, 03:24 PM |#10  
RambJoe's Avatar
Senior Member
Thanks Meter: 18
 
More
Any screenshots of how the phone looks with a different DPI?
Post Reply Subscribe to Thread
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes