Attend XDA's Second Annual Developer Conference, XDA:DevCon 2014!
5,772,899 Members 48,816 Now Online
XDA Developers Android and Mobile Development Forum

[MOD][GUIDE]Enable %battery in 4.4 KitKat

Tip us?
 
firasusman
Old
#11  
firasusman's Avatar
Senior Member
Thanks Meter 11087
Posts: 2,099
Join Date: Sep 2011
Location: Dubai

 
DONATE TO ME
Appreciated if you provide flashable zip for all your mod.
One by one.
Thanks.

Sent from my SM-N9005 using Tapatalk
LiquidBlack ROM N7000
Liquid ROM N7000
Assassin ROM N7100
Swift ROM N7100
Assassin theme your Rom N7100
Assassin ROM N9005
Script/Fix Soft_Brick Loop_ EFS partition

 
aouni_tahech
Old
#12  
Member
Thanks Meter 15
Posts: 82
Join Date: Sep 2011
I'm on echo rom v7, which is based on official stock 4.4.2

I flashed the above soundforge file and the battery background color didn't change. It's still white.

The only issue is that when the battery becomes less than 70%, the percentage text is hard to read! So I prefer the yellow background.
Attached Thumbnails
Click image for larger version

Name:	2014-01-25.jpg
Views:	128
Size:	4.0 KB
ID:	2539572  
 
filchi756
Old
#13  
Senior Member
Thanks Meter 212
Posts: 543
Join Date: Sep 2010
Quote:
Originally Posted by nguyenxuanhoa View Post
Things you'll need:
APKTool
Notepad++
SystemUI.apk from your 4.4 ROM




1. Using APKTool, decompile SystemUI.apk

2. Open \smali\com\android\systemui\BatteryMeterView.smali in Notepad++

3. If you don't already have the white %battery enabled, enable it now. Find:

Code:
    const-string v7, "status_bar_show_battery_percent"

    const/4 v9, 0x0
and change 0x0 to 0x1

4. Now find:
Code:
    iget-object v7, p0, Lcom/android/systemui/BatteryMeterView;->mTextPaint:Landroid/graphics/Paint;

    const/4 v7, -0x1
and change "const/4 v8, -0x1" to "const/high16 v8, -0x100" (this is changing white (-0x1) to black (-0x100))

5. Save the changes and recompile the APK making sure to retain the original signature. Push back to /system/priv-app/ and set with RW/R/R permissions. Voila, now you have black text for your %battery


downlad Enable _battery in 4.4 KitKat N900.zip

http://sourceforge.net/projects/vnro...0.zip/download
Quote:
Originally Posted by termit901 View Post
Bold fonts

Find in BatteryMeterView.smali
Code:
    .line 263
    const-string v7, "sans-serif-condensed"

    const/4 v8, 0x0
replaced
Code:
    .line 263
    const-string v7, "sans-serif"

    const/4 v8, 0x1
result:
Attachment 2536151
Quote:
Originally Posted by termit901 View Post
Red text
Code:
    .line 262
    iget-object v7, p0, Lcom/android/systemui/BatteryMeterView;->mTextPaint:Landroid/graphics/Paint;

    const/high16 v8, -0x30
Attachment 2536312
------
max brighter
Code:
 -0x1
Attachment 2536408
thank you all for the guides, successfully made one for Omega 7 rom.
The Following User Says Thank You to filchi756 For This Useful Post: [ Click to Expand ]
 
mervin8706
Old
#14  
Junior Member
Thanks Meter 3
Posts: 24
Join Date: Sep 2010
tried to flash the file attached but nothing after reboot.. i am on 4.4.2 kitkat stock rom
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes