FORUMS

Earthquake Early Warning in Your Pocket

Probably all of us reading this have a smartphone in our pocket. For many of us, the … more

Sony: The OEM You Want To Save

In our recent Discuss article, we asked you readers on which OEM you would like to help. While the … more

How to Lock and Protect Your Apps – XDA Xposed Tuesday

The smartphone revolution has passed. Everybody has mobile apps. Some of … more

Which OEM Would You Like to Help?

Most manufacturers have moments of greatness and moments of decadence, and in the past few years … more

[GUIDE][CM9-11] Add partition info in Settings.apk

710 posts
Thanks Meter: 1,429
 
Post Reply Subscribe to Thread Email Thread
Assalamualaikum
Hello guys, i want to share a simple guide with you

WHAT IS IT?
it's a guide to make a partition info in the Settings.apk
Source:

SCREENSHOT




Ok, let's start working on it

WHATS NEEDED?
- Brain
- A cup of coffe
- Use Apktool v 2.0.0 beta 9
- Settings.apk
- Attachment file

1. Decompile your Settings.apk

2. Download and extrack Attachment file and place it in the right place

3. Go to the ~\Settings\res\values\strings.xml
Add this code below before </resources>
Code:
    <string name="partition_info_title">Partition info</string>
    <string name="partition_info_system">/system</string>
    <string name="partition_info_data">/data</string>
    <string name="partition_info_cache">/cache</string>
    <string name="partition_info_sdcard">/sdcard (FAT)</string>
    <string name="partition_info_sdext">/sd-ext (EXT)</string>
    <string name="partition_info_used_of">/</string>
    <string name="nol">Unavailable</string>
</resources>
3. Go to the ~\Settings\res\xml\settings_headers.xml
Add this code below wherever you want inside settings_headers.xml
Code:
    <header android:icon="@drawable/partition_info" android:title="@string/partition_info_title">
        <intent android:targetPackage="com.android.settings" android:action="com.android.action.MAIN" android:targetClass="com.android.settings.ktech.PartitionInfo" />
    </header>
4. Compile your Settings.apk and decompile again

5. Go to ~\Settings\AndroidManifest.xml
Code:
        <activity android:label="@string/partition_info_title" android:name=".ktech.PartitionInfo">
            <intent-filter>
                <action android:name="android.intent.action.MAIN"/>
                <category android:name="android.intent.category.DEFAULT"/>
                <category android:name="android.intent.category.VOICE_LAUNCH"/>
            </intent-filter>
        </activity>
6. Go to the ~\Settings\smali\com\android\settings\ktech\Partit ionInfo.smali
Find & replace this code below with your public id

Code:
Line 110	0x7f080403	public type="string" name="partition_info_used_of"
Line 189	0x7f050043	public type="xml" name="partition_info"
7. Recompile Settings.apk then Sign it
8. Push it in your phone
Attached Files
File Type: zip [PARTITION INFO]Settings.zip - [Click for QR Code] (6.0 KB, 222 views)
Last edited by K_TECH; 19th October 2014 at 07:42 PM.
The Following 7 Users Say Thank You to K_TECH For This Useful Post: [ View ]
 
 
22nd October 2014, 07:48 PM |#2  
G.M.L's Avatar
Senior Member
Flag Thessaloniki
Thanks Meter: 157
 
More
hi i have one problem i make all the steps and im getting fc of settings when im pushing ''partition info'' and then i see that after decompile (the second decompile) the partition_info is in pyblic type drawable and not in pyblic type xml im trying 5 times but nothing (sorry for my bad english)
23rd October 2014, 01:55 AM |#3  
K_TECH's Avatar
OP Recognized Contributor
Flag Sidoarjo
Thanks Meter: 1,429
 
More
Quote:
Originally Posted by G.M.L

hi i have one problem i make all the steps and im getting fc of settings when im pushing ''partition info'' and then i see that after decompile (the second decompile) the partition_info is in pyblic type drawable and not in pyblic type xml im trying 5 times but nothing (sorry for my bad english)

Post your log here
23rd October 2014, 04:25 AM |#4  
G.M.L's Avatar
Senior Member
Flag Thessaloniki
Thanks Meter: 157
 
More
Here is it
Attached Files
File Type: txt log.txt - [Click for QR Code] (2.4 KB, 27 views)
25th October 2014, 07:48 AM |#5  
G.M.L's Avatar
Senior Member
Flag Thessaloniki
Thanks Meter: 157
 
More
OK I made it I changed the icon name in drawable-hdpi and after decomplile (the second time) in public the names are correct thanks k_tech!!!!!!

G.M.L.
25th October 2014, 06:11 PM |#6  
K_TECH's Avatar
OP Recognized Contributor
Flag Sidoarjo
Thanks Meter: 1,429
 
More
Quote:
Originally Posted by G.M.L

OK I made it I changed the icon name in drawable-hdpi and after decomplile (the second time) in public the names are correct thanks k_tech!!!!!!

G.M.L.

Ok, good job
The Following 2 Users Say Thank You to K_TECH For This Useful Post: [ View ]
13th November 2014, 05:52 PM |#7  
Senior Member
Flag Kiev
Thanks Meter: 30
 
More
Thx sir, its work on my LG P713 (4.1.2)
22nd November 2014, 01:24 PM |#8  
D2Y aka E's Avatar
Senior Member
Flag muara wahau (borneo)
Thanks Meter: 74
 
More
Thx sir...
4th January 2015, 07:22 PM |#9  
Senior Member
Flag Pune
Thanks Meter: 23
 
More
step6 is little confusing....could u plz be in detail.
4th January 2015, 08:19 PM |#10  
G.M.L's Avatar
Senior Member
Flag Thessaloniki
Thanks Meter: 157
 
More
Quote:
Originally Posted by rrajesh011

step6 is little confusing....could u plz be in detail.

Open smali/com/android/settings/k_tech/partitioninfo.smali and leave it open
Open value/public.xml and find
type=string name=partition_info_used_of id=this number copy and paste to partition info.smali in line 1100
And
type=xml name=partition_info id=this number copy and paste in partition info.Smali in line 1890
Compile and its ready!!!

G.M.L.
The Following User Says Thank You to G.M.L For This Useful Post: [ View ]
Post Reply Subscribe to Thread
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes