[How-To]Removing Battery Percentage,Adding Toggles,Battery Circles to Statusbar

Search This thread

neectron

Senior Member
Dec 26, 2011
1,538
1,562
Really>?
[How-To]Removing Battery Percentage and Adding Toggles to Statusbar​


Thanks to pvyParts for being part of this thread.

More info about public.xml - http://xdaforums.com/showpost.php?p=34242328&postcount=73



Adding/porting toggles to Statusbar.

  • Decompile SystemUI.apk

  • Copy both folders from lidroid.zip to /systemui/smali.

  • Copy icons from the quickpanel-icons.zip to /systemui/res/drawable-hdpi.

  • Copy 3 xmls from power.zip to /systemui/res/layout.

  • Copy arrays.xml to /systemui/res/values.

    Resource modifications:

  • Edit "systemui\res\values\ids.xml" and add these Id:

    Code:
    <item type="id" name="power_widget_button_image">false</item>
    <item type="id" name="power_widget_button_text">false</item>
    <item type="id" name="power_widget_button_indic">false</item>
    <item type="id" name="power_widget_button">false</item>


  • Edit "systemui\res\values\strings.xml" and add these strings:

    Code:
        <string name="quickpanel_sound_text">Sound</string>
        <string name="quickpanel_sound_vibration_text">Sound</string>
        <string name="quickpanel_silent_text">Silent</string>
        <string name="quickpanel_vibration_text">Vibration</string>
        <string name="quickpanel_rotation_text">Rotation</string>
        <string name="quickpanel_bluetooth_text">Bluetooth</string>
        <string name="quickpanel_gps_text">GPS</string>
        <string name="quickpanel_autosync_text">Auto Sync</string>
        <string name="quickpanel_brightness_text">Brightness</string>
        <string name="quickpanel_screen_timeout_text">Timeout</string>
        <string name="quickpanel_lockscreen_text">Lockscreen</string>
        <string name="quickpanel_airplane_text">Flight</string>
        <string name="quickpanel_flashlight_text">Flashlight</string>
        <string name="quickpanel_reboot_text">Reboot</string>
        <string name="quickpanel_shutdown_text">Shutdown</string>
        <string name="airplane_mode">In Flight mode</string>
        <string name="shutdown_confirm">Your phone will shut down.</string>
        <string name="screen_timeout_seconds">Screen timeout set to: %d second(s)</string>
        <string name="screen_timeout_minutes">Screen timeout set to: %d minute(s)</string>
        <string name="screen_timeout_hours">Screen timeout set to: %d hour(s)</string>
        <string name="hamster">Phone Options</string>
        <string name="yes">OK</string>
        <string name="no">Cancel</string>
        <string name="reboot">Reboot</string>
        <string name="reboot_recovery">Recovery</string>
        <string name="quickpanel_dc_text">Data</string>
        <string name="reboot_download">Download</string>
        <string name="quickpanel_network_mode_text">Network</string>
        <string name="quickpanel_wifi_text">WiFi</string>

  • Edit "systemui\res\values\public.xml" and add these:

  • Add after the last drawable declared:


    Code:
        <public type="drawable" name="stat_2g3g_off" id="0x7f0200e1" />
        <public type="drawable" name="stat_2g3g_on" id="0x7f0200e2" />
        <public type="drawable" name="stat_3g_on" id="0x7f0200e3" />
        <public type="drawable" name="stat_airplane_off" id="0x7f0200e4" />
        <public type="drawable" name="stat_airplane_on" id="0x7f0200e5" />
        <public type="drawable" name="stat_bg_ing" id="0x7f0200e6" />
        <public type="drawable" name="stat_bg_off" id="0x7f0200e7" />
        <public type="drawable" name="stat_bg_on" id="0x7f0200e8" />
        <public type="drawable" name="stat_bluetooth_off" id="0x7f0200e9" />
        <public type="drawable" name="stat_bluetooth_on" id="0x7f0200ea" />
        <public type="drawable" name="stat_brightness_auto" id="0x7f0200eb" />
        <public type="drawable" name="stat_brightness_mid" id="0x7f0200ec" />
        <public type="drawable" name="stat_brightness_off" id="0x7f0200ed" />
        <public type="drawable" name="stat_brightness_on" id="0x7f0200ee" />
        <public type="drawable" name="stat_data_off" id="0x7f0200ef" />
        <public type="drawable" name="stat_data_on" id="0x7f0200f0" />
        <public type="drawable" name="stat_flashlight_off" id="0x7f0200f1" />
        <public type="drawable" name="stat_flashlight_on" id="0x7f0200f2" />
        <public type="drawable" name="stat_gps_off" id="0x7f0200f3" />
        <public type="drawable" name="stat_gps_on" id="0x7f0200f4" />
        <public type="drawable" name="stat_lock_screen_off" id="0x7f0200f5" />
        <public type="drawable" name="stat_lock_screen_on" id="0x7f0200f6" />
        <public type="drawable" name="stat_wifi_on" id="0x7f0200f7" />
        <public type="drawable" name="stat_orientation_off" id="0x7f0200f8" />
        <public type="drawable" name="stat_orientation_on" id="0x7f0200f9" />
        <public type="drawable" name="stat_reboot" id="0x7f0200fc" />
        <public type="drawable" name="stat_ring_on" id="0x7f0200fd" />
        <public type="drawable" name="stat_ring_vibrate_on" id="0x7f0200fe" />
        <public type="drawable" name="stat_screen_timeout_10m" id="0x7f0200ff" />
        <public type="drawable" name="stat_screen_timeout_15s" id="0x7f020100" />
        <public type="drawable" name="stat_screen_timeout_1m" id="0x7f020101" />
        <public type="drawable" name="stat_screen_timeout_2m" id="0x7f020102" />
        <public type="drawable" name="stat_screen_timeout_30s" id="0x7f020103" />
        <public type="drawable" name="stat_screen_timeout_off" id="0x7f020104" />
        <public type="drawable" name="stat_screen_timeout_on" id="0x7f020105" />
        <public type="drawable" name="stat_screen_timeout_unknown" id="0x7f020106" />
        <public type="drawable" name="stat_shutdown" id="0x7f020107" />
        <public type="drawable" name="stat_silent" id="0x7f020108" />
        <public type="drawable" name="stat_sync_off" id="0x7f020109" />
        <public type="drawable" name="stat_sync_on" id="0x7f02010a" />
        <public type="drawable" name="stat_vibrate_off" id="0x7f02010b" />
        <public type="drawable" name="stat_wifi_off" id="0x7f02010c" />

  • Add after the last layout declared:

    Code:
        <public type="layout" name="power_widget_button" id="0x7f03001b" />
        <public type="layout" name="power_widget_layout" id="0x7f03001c" />
        <public type="layout" name="power_widget_scrollview" id="0x7f03001d" />

  • Add after the last string declared:

    Code:
       <public type="string" name="quickpanel_sound_text" id="0x7f08007f" />
        <public type="string" name="quickpanel_sound_vibration_text" id="0x7f080080" />
        <public type="string" name="quickpanel_silent_text" id="0x7f080081" />
        <public type="string" name="quickpanel_vibration_text" id="0x7f080082" />
        <public type="string" name="quickpanel_rotation_text" id="0x7f080083" />
        <public type="string" name="quickpanel_bluetooth_text" id="0x7f080084" />
        <public type="string" name="quickpanel_gps_text" id="0x7f080085" />
        <public type="string" name="quickpanel_autosync_text" id="0x7f080086" />
        <public type="string" name="quickpanel_brightness_text" id="0x7f080087" />
        <public type="string" name="quickpanel_screen_timeout_text" id="0x7f080088" />
        <public type="string" name="quickpanel_lockscreen_text" id="0x7f080089" />
        <public type="string" name="quickpanel_airplane_text" id="0x7f08008a" />
        <public type="string" name="quickpanel_flashlight_text" id="0x7f08008b" />
        <public type="string" name="quickpanel_reboot_text" id="0x7f08008c" />
        <public type="string" name="quickpanel_shutdown_text" id="0x7f08008d" />
        <public type="string" name="airplane_mode" id="0x7f08008e" />
        <public type="string" name="shutdown_confirm" id="0x7f08008f" />
        <public type="string" name="screen_timeout_seconds" id="0x7f080090" />
        <public type="string" name="screen_timeout_minutes" id="0x7f080091" />
        <public type="string" name="screen_timeout_hours" id="0x7f080092" />
        <public type="string" name="hamster" id="0x7f080093" />
        <public type="string" name="yes" id="0x7f080094" />
        <public type="string" name="no" id="0x7f080095" />
        <public type="string" name="reboot" id="0x7f080096" />

  • Add after the last id decalred:

    Code:
        <public type="id" name="power_widget_button_image" id="0x7f0e0094" />
        <public type="id" name="power_widget_button_text" id="0x7f0e0095" />
        <public type="id" name="power_widget_button_indic" id="0x7f0e0096" />
        <public type="id" name="power_widget_button" id="0x7f0e0097" />
        <public type="array" name="config_cdmaDbmThresholds" id="0x7f0f0000" />
        <public type="array" name="config_cdmaEcioThresholds" id="0x7f0f0001" />
        <public type="array" name="config_evdoDbmThresholds" id="0x7f0f0002" />
        <public type="array" name="config_evdoSnrThresholds" id="0x7f0f0003" />
        <public type="array" name="shutdown_reboot_options" id="0x7f0f0004" />
        <public type="array" name="shutdown_reboot_actions" id="0x7f0f0005" />



    Smali modifications:

  • Edit "systemui\smali\com\android\systemui\statusbar \phone\PhoneStatusBar.smali" and make these changes :


    Add the only lines prefixed by ++;

    Code:
    invoke-virtual {v0, v9, v2}, Landroid/content/Context;->registerReceiver(Landroid/content/BroadcastReceiver;Landroid/content/IntentFilter;)Landroid/content/Intent;
    	
    ++ const v6, 0x7f03001c
    
    ++ invoke-static {v0, v6, v11}, Landroid/view/View;->inflate(Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;
    
    ++ move-result-object v5
    
    ++ check-cast v5, Lcom/lidroid/systemui/quickpanel/PowerWidget;
    
    ++ invoke-virtual {v5}, Lcom/lidroid/systemui/quickpanel/PowerWidget;->setupWidget()V
    
    ++ iget-object v6, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
    
    ++ invoke-virtual {v6, v5, v11}, Lcom/android/systemui/statusbar/phone/ExpandedView;->addView(Landroid/view/View;I)V
    	
    return-object v4


  • Compile SystemUI.apk.
  • Copy Meta-Inf and AndroidManifest.xml from stock SystemUI.apk to your modded one.
  • That's it.

Waring:If the variables you are going to add to public.xml is already used,then you will have edit more smali.
Like if variable for "stat_data_on ": 0x7f0200f0 is already used,then you have to change it to 0x7f02xxxx,not used.
Then you have edit systemui\smali\com\lidroid\systemui\quickpanel\MobileDataButton.smali.
Find 0x7f0200f0 and change it to new 0x7f02xxxx you have addedin public.xml.Similarly for other variables also,if it is used change the respective .smali



Credit:I have used resources from this thread
**********************************************************************************************************************************************************************

Removing Battery Percentage from Statusbar​

  • Decompile SystemUI.apk

  • Open systemui/res/layout/status_bar.xml.

  • Find the line :
    Code:
    <TextView android:layout_gravity="left|center" android:id="@id/battery_text" android: paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/status_bar_settings_settings_button" android:singleLine="true" style="@style/StatusBarNotificationText" />
  • Change that line to:
    Code:
    <TextView android:layout_gravity="left|center" android:id="@id/battery_text" android: paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/status_bar_settings_settings_button" android:singleLine="true" [B]android:visibility="gone"[/B] style="@style/StatusBarNotificationText" />

  • Save the file.
  • Compile SystemUI.apk
  • Copy Meta-Inf and AndroidManifest.xml from stock SystemUI.apk to your modded one.
  • That's it.

  • Then copy it to /system,set permissions to -rw-r-r.
  • Then copy it to /system/app.
  • Reboot the phone.

Credit:Thanks to pvyParts for the tip.


Download:SystemUI w/o battery percentage[U/Sola]

***********************************************************************************************************************************************


Battery Mod

1% Battery Mod
 

Attachments

  • 16.jpg
    16.jpg
    19.7 KB · Views: 8,674
Last edited:

wisnuhadi23

Senior Member
Jul 11, 2012
251
58
Great tutorial.
It would have been better if you also include guide how to add quick toggle to systemui.apk I really want to learn how. I have been trying to find a nice guide but most of them are for sams... phones.

Sent from my ST25i using Tapatalk 2
 

pvyParts

Inactive Recognized Developer
Oct 11, 2010
1,858
2,341
35
pretty sure that adding

http://developer.android.com/reference/android/view/View.html#attr_android:visibility
Code:
android:visibility="GONE"
Code:
<TextView android:layout_gravity="left|center" android:id="@id/battery_text" android: paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/status_bar_settings_settings_button" android:singleLine="true" [B][I]android:visibility="gone" [/I][/B]style="@style/StatusBarNotificationText" />

into the xml with no smali mods will also work ;)

it did on older firmwares just an FYI.

Pvy.
 
  • Like
Reactions: neectron

neectron

Senior Member
Dec 26, 2011
1,538
1,562
Really>?
pretty sure that adding

http://developer.android.com/reference/android/view/View.html#attr_android:visibility
Code:
android:visibility="GONE"
Code:
<TextView android:layout_gravity="left|center" android:id="@id/battery_text" android: paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/status_bar_settings_settings_button" android:singleLine="true" [B][I]android:visibility="gone" [/I][/B]style="@style/StatusBarNotificationText" />

into the xml with no smali mods will also work ;)

it did on older firmwares just an FYI.

Pvy.

Great,it works.Changed the first post.:)
 
  • Like
Reactions: pvyParts

pvyParts

Inactive Recognized Developer
Oct 11, 2010
1,858
2,341
35
I think androidmanifest.xml didn't decompile properly,so it is not compiling.

Agreed. I find it is always good practice to do a clean decompile and recompile to ensure the environment is setup right before. This will make if easy fix a lot of small problems that can arise ;)

Pvy


Sent from my Galaxy Nexus using xda premium
 

neectron

Senior Member
Dec 26, 2011
1,538
1,562
Really>?
Adding 1% battery icons.​

  • Decompile SystemUI.apk

  • Add 100 icons for battery discharging and charging to /res/drawable-hdpi.
    For charging icons,name should be "stat_sys_battery_x.png":x = 1 to 100.
    For discharging icons,name should be "stat_sys_battery_charge_animxx":xx = 1 to 100.
    As you can see from below xmls.

    Sample icons: batteryicons.zipThese are not mine.
    You can copy these to /res/drawable-hdpi.

  • Copy xmls from this zip to systemui\res\drawables\.



    or


  • Edit "systemui\res\drawables\stat_sys_battery.xml" and replace with these:



    Code:
    <?xml version="1.0" encoding="utf-8"?>
    <level-list
      xmlns:android="http://schemas.android.com/apk/res/android">
        <item android:drawable="@drawable/stat_sys_battery_0" android:maxLevel="0" />
        <item android:drawable="@drawable/stat_sys_battery_1" android:maxLevel="1" />
        <item android:drawable="@drawable/stat_sys_battery_2" android:maxLevel="2" />
        <item android:drawable="@drawable/stat_sys_battery_3" android:maxLevel="3" />
        <item android:drawable="@drawable/stat_sys_battery_4" android:maxLevel="4" />
        <item android:drawable="@drawable/stat_sys_battery_5" android:maxLevel="5" />
        <item android:drawable="@drawable/stat_sys_battery_6" android:maxLevel="6" />
        <item android:drawable="@drawable/stat_sys_battery_7" android:maxLevel="7" />
        <item android:drawable="@drawable/stat_sys_battery_8" android:maxLevel="8" />
        <item android:drawable="@drawable/stat_sys_battery_9" android:maxLevel="9" />
        <item android:drawable="@drawable/stat_sys_battery_10" android:maxLevel="10" />
        <item android:drawable="@drawable/stat_sys_battery_11" android:maxLevel="11" />
        <item android:drawable="@drawable/stat_sys_battery_12" android:maxLevel="12" />
        <item android:drawable="@drawable/stat_sys_battery_13" android:maxLevel="13" />
        <item android:drawable="@drawable/stat_sys_battery_14" android:maxLevel="14" />
        <item android:drawable="@drawable/stat_sys_battery_15" android:maxLevel="15" />
        <item android:drawable="@drawable/stat_sys_battery_16" android:maxLevel="16" />
        <item android:drawable="@drawable/stat_sys_battery_17" android:maxLevel="17" />
        <item android:drawable="@drawable/stat_sys_battery_18" android:maxLevel="18" />
        <item android:drawable="@drawable/stat_sys_battery_19" android:maxLevel="19" />
        <item android:drawable="@drawable/stat_sys_battery_20" android:maxLevel="20" />
        <item android:drawable="@drawable/stat_sys_battery_21" android:maxLevel="21" />
        <item android:drawable="@drawable/stat_sys_battery_22" android:maxLevel="22" />
        <item android:drawable="@drawable/stat_sys_battery_23" android:maxLevel="23" />
        <item android:drawable="@drawable/stat_sys_battery_24" android:maxLevel="24" />
        <item android:drawable="@drawable/stat_sys_battery_25" android:maxLevel="25" />
        <item android:drawable="@drawable/stat_sys_battery_26" android:maxLevel="26" />
        <item android:drawable="@drawable/stat_sys_battery_27" android:maxLevel="27" />
        <item android:drawable="@drawable/stat_sys_battery_28" android:maxLevel="28" />
        <item android:drawable="@drawable/stat_sys_battery_29" android:maxLevel="29" />
        <item android:drawable="@drawable/stat_sys_battery_30" android:maxLevel="30" />
        <item android:drawable="@drawable/stat_sys_battery_31" android:maxLevel="31" />
        <item android:drawable="@drawable/stat_sys_battery_32" android:maxLevel="32" />
        <item android:drawable="@drawable/stat_sys_battery_33" android:maxLevel="33" />
        <item android:drawable="@drawable/stat_sys_battery_34" android:maxLevel="34" />
        <item android:drawable="@drawable/stat_sys_battery_35" android:maxLevel="35" />
        <item android:drawable="@drawable/stat_sys_battery_36" android:maxLevel="36" />
        <item android:drawable="@drawable/stat_sys_battery_37" android:maxLevel="37" />
        <item android:drawable="@drawable/stat_sys_battery_38" android:maxLevel="38" />
        <item android:drawable="@drawable/stat_sys_battery_39" android:maxLevel="39" />
        <item android:drawable="@drawable/stat_sys_battery_40" android:maxLevel="40" />
        <item android:drawable="@drawable/stat_sys_battery_41" android:maxLevel="41" />
        <item android:drawable="@drawable/stat_sys_battery_42" android:maxLevel="42" />
        <item android:drawable="@drawable/stat_sys_battery_43" android:maxLevel="43" />
        <item android:drawable="@drawable/stat_sys_battery_44" android:maxLevel="44" />
        <item android:drawable="@drawable/stat_sys_battery_45" android:maxLevel="45" />
        <item android:drawable="@drawable/stat_sys_battery_46" android:maxLevel="46" />
        <item android:drawable="@drawable/stat_sys_battery_47" android:maxLevel="47" />
        <item android:drawable="@drawable/stat_sys_battery_48" android:maxLevel="48" />
        <item android:drawable="@drawable/stat_sys_battery_49" android:maxLevel="49" />
        <item android:drawable="@drawable/stat_sys_battery_50" android:maxLevel="50" />
        <item android:drawable="@drawable/stat_sys_battery_51" android:maxLevel="51" />
        <item android:drawable="@drawable/stat_sys_battery_52" android:maxLevel="52" />
        <item android:drawable="@drawable/stat_sys_battery_53" android:maxLevel="53" />
        <item android:drawable="@drawable/stat_sys_battery_54" android:maxLevel="54" />
        <item android:drawable="@drawable/stat_sys_battery_55" android:maxLevel="55" />
        <item android:drawable="@drawable/stat_sys_battery_56" android:maxLevel="56" />
        <item android:drawable="@drawable/stat_sys_battery_57" android:maxLevel="57" />
        <item android:drawable="@drawable/stat_sys_battery_58" android:maxLevel="58" />
        <item android:drawable="@drawable/stat_sys_battery_59" android:maxLevel="59" />
        <item android:drawable="@drawable/stat_sys_battery_60" android:maxLevel="60" />
        <item android:drawable="@drawable/stat_sys_battery_61" android:maxLevel="61" />
        <item android:drawable="@drawable/stat_sys_battery_62" android:maxLevel="62" />
        <item android:drawable="@drawable/stat_sys_battery_63" android:maxLevel="63" />
        <item android:drawable="@drawable/stat_sys_battery_64" android:maxLevel="64" />
        <item android:drawable="@drawable/stat_sys_battery_65" android:maxLevel="65" />
        <item android:drawable="@drawable/stat_sys_battery_66" android:maxLevel="66" />
        <item android:drawable="@drawable/stat_sys_battery_67" android:maxLevel="67" />
        <item android:drawable="@drawable/stat_sys_battery_68" android:maxLevel="68" />
        <item android:drawable="@drawable/stat_sys_battery_69" android:maxLevel="69" />
        <item android:drawable="@drawable/stat_sys_battery_70" android:maxLevel="70" />
        <item android:drawable="@drawable/stat_sys_battery_71" android:maxLevel="71" />
        <item android:drawable="@drawable/stat_sys_battery_72" android:maxLevel="72" />
        <item android:drawable="@drawable/stat_sys_battery_73" android:maxLevel="73" />
        <item android:drawable="@drawable/stat_sys_battery_74" android:maxLevel="74" />
        <item android:drawable="@drawable/stat_sys_battery_75" android:maxLevel="75" />
        <item android:drawable="@drawable/stat_sys_battery_76" android:maxLevel="76" />
        <item android:drawable="@drawable/stat_sys_battery_77" android:maxLevel="77" />
        <item android:drawable="@drawable/stat_sys_battery_78" android:maxLevel="78" />
        <item android:drawable="@drawable/stat_sys_battery_79" android:maxLevel="79" />
        <item android:drawable="@drawable/stat_sys_battery_80" android:maxLevel="80" />
        <item android:drawable="@drawable/stat_sys_battery_81" android:maxLevel="81" />
        <item android:drawable="@drawable/stat_sys_battery_82" android:maxLevel="82" />
        <item android:drawable="@drawable/stat_sys_battery_83" android:maxLevel="83" />
        <item android:drawable="@drawable/stat_sys_battery_84" android:maxLevel="84" />
        <item android:drawable="@drawable/stat_sys_battery_85" android:maxLevel="85" />
        <item android:drawable="@drawable/stat_sys_battery_86" android:maxLevel="86" />
        <item android:drawable="@drawable/stat_sys_battery_87" android:maxLevel="87" />
        <item android:drawable="@drawable/stat_sys_battery_88" android:maxLevel="88" />
        <item android:drawable="@drawable/stat_sys_battery_89" android:maxLevel="89" />
        <item android:drawable="@drawable/stat_sys_battery_90" android:maxLevel="90" />
        <item android:drawable="@drawable/stat_sys_battery_91" android:maxLevel="91" />
        <item android:drawable="@drawable/stat_sys_battery_92" android:maxLevel="92" />
        <item android:drawable="@drawable/stat_sys_battery_93" android:maxLevel="93" />
        <item android:drawable="@drawable/stat_sys_battery_94" android:maxLevel="94" />
        <item android:drawable="@drawable/stat_sys_battery_95" android:maxLevel="95" />
        <item android:drawable="@drawable/stat_sys_battery_96" android:maxLevel="96" />
        <item android:drawable="@drawable/stat_sys_battery_97" android:maxLevel="97" />
        <item android:drawable="@drawable/stat_sys_battery_98" android:maxLevel="98" />
        <item android:drawable="@drawable/stat_sys_battery_99" android:maxLevel="99" />
        <item android:drawable="@drawable/stat_sys_battery_100" android:maxLevel="100" />
    </level-list>



  • Edit "systemui\res\drawables\stat_sys_battery_charge.xml" and replace with these:



    Code:
    <?xml version="1.0" encoding="utf-8"?>
    <level-list
      xmlns:android="http://schemas.android.com/apk/res/android">
        <item android:drawable="@drawable/stat_sys_battery_charge_anim0" android:maxLevel="0" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim1" android:maxLevel="1" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim2" android:maxLevel="2" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim3" android:maxLevel="3" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim4" android:maxLevel="4" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim5" android:maxLevel="5" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim6" android:maxLevel="6" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim7" android:maxLevel="7" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim8" android:maxLevel="8" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim9" android:maxLevel="9" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim10" android:maxLevel="10" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim11" android:maxLevel="11" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim12" android:maxLevel="12" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim13" android:maxLevel="13" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim14" android:maxLevel="14" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim15" android:maxLevel="15" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim16" android:maxLevel="16" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim17" android:maxLevel="17" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim18" android:maxLevel="18" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim19" android:maxLevel="19" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim20" android:maxLevel="20" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim21" android:maxLevel="21" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim22" android:maxLevel="22" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim23" android:maxLevel="23" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim24" android:maxLevel="24" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim25" android:maxLevel="25" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim26" android:maxLevel="26" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim27" android:maxLevel="27" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim28" android:maxLevel="28" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim29" android:maxLevel="29" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim30" android:maxLevel="30" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim31" android:maxLevel="31" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim32" android:maxLevel="32" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim33" android:maxLevel="33" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim34" android:maxLevel="34" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim35" android:maxLevel="35" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim36" android:maxLevel="36" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim37" android:maxLevel="37" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim38" android:maxLevel="38" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim39" android:maxLevel="39" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim40" android:maxLevel="40" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim41" android:maxLevel="41" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim42" android:maxLevel="42" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim43" android:maxLevel="43" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim44" android:maxLevel="44" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim45" android:maxLevel="45" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim46" android:maxLevel="46" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim47" android:maxLevel="47" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim48" android:maxLevel="48" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim49" android:maxLevel="49" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim50" android:maxLevel="50" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim51" android:maxLevel="51" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim52" android:maxLevel="52" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim53" android:maxLevel="53" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim54" android:maxLevel="54" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim55" android:maxLevel="55" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim56" android:maxLevel="56" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim57" android:maxLevel="57" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim58" android:maxLevel="58" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim59" android:maxLevel="59" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim60" android:maxLevel="60" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim61" android:maxLevel="61" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim62" android:maxLevel="62" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim63" android:maxLevel="63" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim64" android:maxLevel="64" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim65" android:maxLevel="65" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim66" android:maxLevel="66" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim67" android:maxLevel="67" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim68" android:maxLevel="68" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim69" android:maxLevel="69" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim70" android:maxLevel="70" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim71" android:maxLevel="71" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim72" android:maxLevel="72" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim73" android:maxLevel="73" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim74" android:maxLevel="74" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim75" android:maxLevel="75" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim76" android:maxLevel="76" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim77" android:maxLevel="77" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim78" android:maxLevel="78" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim79" android:maxLevel="79" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim80" android:maxLevel="80" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim81" android:maxLevel="81" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim82" android:maxLevel="82" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim83" android:maxLevel="83" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim84" android:maxLevel="84" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim85" android:maxLevel="85" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim86" android:maxLevel="86" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim87" android:maxLevel="87" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim88" android:maxLevel="88" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim89" android:maxLevel="89" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim90" android:maxLevel="90" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim91" android:maxLevel="91" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim92" android:maxLevel="92" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim93" android:maxLevel="93" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim94" android:maxLevel="94" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim95" android:maxLevel="95" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim96" android:maxLevel="96" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim97" android:maxLevel="97" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim98" android:maxLevel="98" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim99" android:maxLevel="99" />
        <item android:drawable="@drawable/stat_sys_battery_charge_anim100" android:maxLevel="100" />
    </level-list>


  • Compile SystemUI.apk
  • Copy Meta-Inf and AndroidManifest.xml from stock SystemUI.apk to your modded one.
  • That's it.

  • Then copy it to /system,set permissions to -rw-r-r.
  • Then copy it to /system/app.
  • Reboot the phone.
 
Last edited:

neectron

Senior Member
Dec 26, 2011
1,538
1,562
Really>?

accts

Senior Member
Feb 21, 2012
468
242
Evergreen State
Thanks for the tutorial, i was learning how to mod myself for the Lt28at Ion - I did everything right but the bar didn't show up. After reading your post I need to edit the lidroid/status bar/quick panel ids to match with my public.xml. What a great source :victory:

I had another question, where/what is the xml or smali that had the 4G icon next to the signal bar instead of above the status bar ? I looked through out the file, couldn't find it. Can you help please :).

Sent from my LT28i using Tapatalk 2
 

Top Liked Posts

  • There are no posts matching your filters.
  • 40
    [How-To]Removing Battery Percentage and Adding Toggles to Statusbar​


    Thanks to pvyParts for being part of this thread.

    More info about public.xml - http://xdaforums.com/showpost.php?p=34242328&postcount=73



    Adding/porting toggles to Statusbar.

    • Decompile SystemUI.apk

    • Copy both folders from lidroid.zip to /systemui/smali.

    • Copy icons from the quickpanel-icons.zip to /systemui/res/drawable-hdpi.

    • Copy 3 xmls from power.zip to /systemui/res/layout.

    • Copy arrays.xml to /systemui/res/values.

      Resource modifications:

    • Edit "systemui\res\values\ids.xml" and add these Id:

      Code:
      <item type="id" name="power_widget_button_image">false</item>
      <item type="id" name="power_widget_button_text">false</item>
      <item type="id" name="power_widget_button_indic">false</item>
      <item type="id" name="power_widget_button">false</item>


    • Edit "systemui\res\values\strings.xml" and add these strings:

      Code:
          <string name="quickpanel_sound_text">Sound</string>
          <string name="quickpanel_sound_vibration_text">Sound</string>
          <string name="quickpanel_silent_text">Silent</string>
          <string name="quickpanel_vibration_text">Vibration</string>
          <string name="quickpanel_rotation_text">Rotation</string>
          <string name="quickpanel_bluetooth_text">Bluetooth</string>
          <string name="quickpanel_gps_text">GPS</string>
          <string name="quickpanel_autosync_text">Auto Sync</string>
          <string name="quickpanel_brightness_text">Brightness</string>
          <string name="quickpanel_screen_timeout_text">Timeout</string>
          <string name="quickpanel_lockscreen_text">Lockscreen</string>
          <string name="quickpanel_airplane_text">Flight</string>
          <string name="quickpanel_flashlight_text">Flashlight</string>
          <string name="quickpanel_reboot_text">Reboot</string>
          <string name="quickpanel_shutdown_text">Shutdown</string>
          <string name="airplane_mode">In Flight mode</string>
          <string name="shutdown_confirm">Your phone will shut down.</string>
          <string name="screen_timeout_seconds">Screen timeout set to: %d second(s)</string>
          <string name="screen_timeout_minutes">Screen timeout set to: %d minute(s)</string>
          <string name="screen_timeout_hours">Screen timeout set to: %d hour(s)</string>
          <string name="hamster">Phone Options</string>
          <string name="yes">OK</string>
          <string name="no">Cancel</string>
          <string name="reboot">Reboot</string>
          <string name="reboot_recovery">Recovery</string>
          <string name="quickpanel_dc_text">Data</string>
          <string name="reboot_download">Download</string>
          <string name="quickpanel_network_mode_text">Network</string>
          <string name="quickpanel_wifi_text">WiFi</string>

    • Edit "systemui\res\values\public.xml" and add these:

    • Add after the last drawable declared:


      Code:
          <public type="drawable" name="stat_2g3g_off" id="0x7f0200e1" />
          <public type="drawable" name="stat_2g3g_on" id="0x7f0200e2" />
          <public type="drawable" name="stat_3g_on" id="0x7f0200e3" />
          <public type="drawable" name="stat_airplane_off" id="0x7f0200e4" />
          <public type="drawable" name="stat_airplane_on" id="0x7f0200e5" />
          <public type="drawable" name="stat_bg_ing" id="0x7f0200e6" />
          <public type="drawable" name="stat_bg_off" id="0x7f0200e7" />
          <public type="drawable" name="stat_bg_on" id="0x7f0200e8" />
          <public type="drawable" name="stat_bluetooth_off" id="0x7f0200e9" />
          <public type="drawable" name="stat_bluetooth_on" id="0x7f0200ea" />
          <public type="drawable" name="stat_brightness_auto" id="0x7f0200eb" />
          <public type="drawable" name="stat_brightness_mid" id="0x7f0200ec" />
          <public type="drawable" name="stat_brightness_off" id="0x7f0200ed" />
          <public type="drawable" name="stat_brightness_on" id="0x7f0200ee" />
          <public type="drawable" name="stat_data_off" id="0x7f0200ef" />
          <public type="drawable" name="stat_data_on" id="0x7f0200f0" />
          <public type="drawable" name="stat_flashlight_off" id="0x7f0200f1" />
          <public type="drawable" name="stat_flashlight_on" id="0x7f0200f2" />
          <public type="drawable" name="stat_gps_off" id="0x7f0200f3" />
          <public type="drawable" name="stat_gps_on" id="0x7f0200f4" />
          <public type="drawable" name="stat_lock_screen_off" id="0x7f0200f5" />
          <public type="drawable" name="stat_lock_screen_on" id="0x7f0200f6" />
          <public type="drawable" name="stat_wifi_on" id="0x7f0200f7" />
          <public type="drawable" name="stat_orientation_off" id="0x7f0200f8" />
          <public type="drawable" name="stat_orientation_on" id="0x7f0200f9" />
          <public type="drawable" name="stat_reboot" id="0x7f0200fc" />
          <public type="drawable" name="stat_ring_on" id="0x7f0200fd" />
          <public type="drawable" name="stat_ring_vibrate_on" id="0x7f0200fe" />
          <public type="drawable" name="stat_screen_timeout_10m" id="0x7f0200ff" />
          <public type="drawable" name="stat_screen_timeout_15s" id="0x7f020100" />
          <public type="drawable" name="stat_screen_timeout_1m" id="0x7f020101" />
          <public type="drawable" name="stat_screen_timeout_2m" id="0x7f020102" />
          <public type="drawable" name="stat_screen_timeout_30s" id="0x7f020103" />
          <public type="drawable" name="stat_screen_timeout_off" id="0x7f020104" />
          <public type="drawable" name="stat_screen_timeout_on" id="0x7f020105" />
          <public type="drawable" name="stat_screen_timeout_unknown" id="0x7f020106" />
          <public type="drawable" name="stat_shutdown" id="0x7f020107" />
          <public type="drawable" name="stat_silent" id="0x7f020108" />
          <public type="drawable" name="stat_sync_off" id="0x7f020109" />
          <public type="drawable" name="stat_sync_on" id="0x7f02010a" />
          <public type="drawable" name="stat_vibrate_off" id="0x7f02010b" />
          <public type="drawable" name="stat_wifi_off" id="0x7f02010c" />

    • Add after the last layout declared:

      Code:
          <public type="layout" name="power_widget_button" id="0x7f03001b" />
          <public type="layout" name="power_widget_layout" id="0x7f03001c" />
          <public type="layout" name="power_widget_scrollview" id="0x7f03001d" />

    • Add after the last string declared:

      Code:
         <public type="string" name="quickpanel_sound_text" id="0x7f08007f" />
          <public type="string" name="quickpanel_sound_vibration_text" id="0x7f080080" />
          <public type="string" name="quickpanel_silent_text" id="0x7f080081" />
          <public type="string" name="quickpanel_vibration_text" id="0x7f080082" />
          <public type="string" name="quickpanel_rotation_text" id="0x7f080083" />
          <public type="string" name="quickpanel_bluetooth_text" id="0x7f080084" />
          <public type="string" name="quickpanel_gps_text" id="0x7f080085" />
          <public type="string" name="quickpanel_autosync_text" id="0x7f080086" />
          <public type="string" name="quickpanel_brightness_text" id="0x7f080087" />
          <public type="string" name="quickpanel_screen_timeout_text" id="0x7f080088" />
          <public type="string" name="quickpanel_lockscreen_text" id="0x7f080089" />
          <public type="string" name="quickpanel_airplane_text" id="0x7f08008a" />
          <public type="string" name="quickpanel_flashlight_text" id="0x7f08008b" />
          <public type="string" name="quickpanel_reboot_text" id="0x7f08008c" />
          <public type="string" name="quickpanel_shutdown_text" id="0x7f08008d" />
          <public type="string" name="airplane_mode" id="0x7f08008e" />
          <public type="string" name="shutdown_confirm" id="0x7f08008f" />
          <public type="string" name="screen_timeout_seconds" id="0x7f080090" />
          <public type="string" name="screen_timeout_minutes" id="0x7f080091" />
          <public type="string" name="screen_timeout_hours" id="0x7f080092" />
          <public type="string" name="hamster" id="0x7f080093" />
          <public type="string" name="yes" id="0x7f080094" />
          <public type="string" name="no" id="0x7f080095" />
          <public type="string" name="reboot" id="0x7f080096" />

    • Add after the last id decalred:

      Code:
          <public type="id" name="power_widget_button_image" id="0x7f0e0094" />
          <public type="id" name="power_widget_button_text" id="0x7f0e0095" />
          <public type="id" name="power_widget_button_indic" id="0x7f0e0096" />
          <public type="id" name="power_widget_button" id="0x7f0e0097" />
          <public type="array" name="config_cdmaDbmThresholds" id="0x7f0f0000" />
          <public type="array" name="config_cdmaEcioThresholds" id="0x7f0f0001" />
          <public type="array" name="config_evdoDbmThresholds" id="0x7f0f0002" />
          <public type="array" name="config_evdoSnrThresholds" id="0x7f0f0003" />
          <public type="array" name="shutdown_reboot_options" id="0x7f0f0004" />
          <public type="array" name="shutdown_reboot_actions" id="0x7f0f0005" />



      Smali modifications:

    • Edit "systemui\smali\com\android\systemui\statusbar \phone\PhoneStatusBar.smali" and make these changes :


      Add the only lines prefixed by ++;

      Code:
      invoke-virtual {v0, v9, v2}, Landroid/content/Context;->registerReceiver(Landroid/content/BroadcastReceiver;Landroid/content/IntentFilter;)Landroid/content/Intent;
      	
      ++ const v6, 0x7f03001c
      
      ++ invoke-static {v0, v6, v11}, Landroid/view/View;->inflate(Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;
      
      ++ move-result-object v5
      
      ++ check-cast v5, Lcom/lidroid/systemui/quickpanel/PowerWidget;
      
      ++ invoke-virtual {v5}, Lcom/lidroid/systemui/quickpanel/PowerWidget;->setupWidget()V
      
      ++ iget-object v6, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
      
      ++ invoke-virtual {v6, v5, v11}, Lcom/android/systemui/statusbar/phone/ExpandedView;->addView(Landroid/view/View;I)V
      	
      return-object v4


    • Compile SystemUI.apk.
    • Copy Meta-Inf and AndroidManifest.xml from stock SystemUI.apk to your modded one.
    • That's it.

    Waring:If the variables you are going to add to public.xml is already used,then you will have edit more smali.
    Like if variable for "stat_data_on ": 0x7f0200f0 is already used,then you have to change it to 0x7f02xxxx,not used.
    Then you have edit systemui\smali\com\lidroid\systemui\quickpanel\MobileDataButton.smali.
    Find 0x7f0200f0 and change it to new 0x7f02xxxx you have addedin public.xml.Similarly for other variables also,if it is used change the respective .smali



    Credit:I have used resources from this thread
    **********************************************************************************************************************************************************************

    Removing Battery Percentage from Statusbar​

    • Decompile SystemUI.apk

    • Open systemui/res/layout/status_bar.xml.

    • Find the line :
      Code:
      <TextView android:layout_gravity="left|center" android:id="@id/battery_text" android: paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/status_bar_settings_settings_button" android:singleLine="true" style="@style/StatusBarNotificationText" />
    • Change that line to:
      Code:
      <TextView android:layout_gravity="left|center" android:id="@id/battery_text" android: paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/status_bar_settings_settings_button" android:singleLine="true" [B]android:visibility="gone"[/B] style="@style/StatusBarNotificationText" />

    • Save the file.
    • Compile SystemUI.apk
    • Copy Meta-Inf and AndroidManifest.xml from stock SystemUI.apk to your modded one.
    • That's it.

    • Then copy it to /system,set permissions to -rw-r-r.
    • Then copy it to /system/app.
    • Reboot the phone.

    Credit:Thanks to pvyParts for the tip.


    Download:SystemUI w/o battery percentage[U/Sola]

    ***********************************************************************************************************************************************


    Battery Mod

    1% Battery Mod
    10
    Adding 1% battery icons.​

    • Decompile SystemUI.apk

    • Add 100 icons for battery discharging and charging to /res/drawable-hdpi.
      For charging icons,name should be "stat_sys_battery_x.png":x = 1 to 100.
      For discharging icons,name should be "stat_sys_battery_charge_animxx":xx = 1 to 100.
      As you can see from below xmls.

      Sample icons: batteryicons.zipThese are not mine.
      You can copy these to /res/drawable-hdpi.

    • Copy xmls from this zip to systemui\res\drawables\.



      or


    • Edit "systemui\res\drawables\stat_sys_battery.xml" and replace with these:



      Code:
      <?xml version="1.0" encoding="utf-8"?>
      <level-list
        xmlns:android="http://schemas.android.com/apk/res/android">
          <item android:drawable="@drawable/stat_sys_battery_0" android:maxLevel="0" />
          <item android:drawable="@drawable/stat_sys_battery_1" android:maxLevel="1" />
          <item android:drawable="@drawable/stat_sys_battery_2" android:maxLevel="2" />
          <item android:drawable="@drawable/stat_sys_battery_3" android:maxLevel="3" />
          <item android:drawable="@drawable/stat_sys_battery_4" android:maxLevel="4" />
          <item android:drawable="@drawable/stat_sys_battery_5" android:maxLevel="5" />
          <item android:drawable="@drawable/stat_sys_battery_6" android:maxLevel="6" />
          <item android:drawable="@drawable/stat_sys_battery_7" android:maxLevel="7" />
          <item android:drawable="@drawable/stat_sys_battery_8" android:maxLevel="8" />
          <item android:drawable="@drawable/stat_sys_battery_9" android:maxLevel="9" />
          <item android:drawable="@drawable/stat_sys_battery_10" android:maxLevel="10" />
          <item android:drawable="@drawable/stat_sys_battery_11" android:maxLevel="11" />
          <item android:drawable="@drawable/stat_sys_battery_12" android:maxLevel="12" />
          <item android:drawable="@drawable/stat_sys_battery_13" android:maxLevel="13" />
          <item android:drawable="@drawable/stat_sys_battery_14" android:maxLevel="14" />
          <item android:drawable="@drawable/stat_sys_battery_15" android:maxLevel="15" />
          <item android:drawable="@drawable/stat_sys_battery_16" android:maxLevel="16" />
          <item android:drawable="@drawable/stat_sys_battery_17" android:maxLevel="17" />
          <item android:drawable="@drawable/stat_sys_battery_18" android:maxLevel="18" />
          <item android:drawable="@drawable/stat_sys_battery_19" android:maxLevel="19" />
          <item android:drawable="@drawable/stat_sys_battery_20" android:maxLevel="20" />
          <item android:drawable="@drawable/stat_sys_battery_21" android:maxLevel="21" />
          <item android:drawable="@drawable/stat_sys_battery_22" android:maxLevel="22" />
          <item android:drawable="@drawable/stat_sys_battery_23" android:maxLevel="23" />
          <item android:drawable="@drawable/stat_sys_battery_24" android:maxLevel="24" />
          <item android:drawable="@drawable/stat_sys_battery_25" android:maxLevel="25" />
          <item android:drawable="@drawable/stat_sys_battery_26" android:maxLevel="26" />
          <item android:drawable="@drawable/stat_sys_battery_27" android:maxLevel="27" />
          <item android:drawable="@drawable/stat_sys_battery_28" android:maxLevel="28" />
          <item android:drawable="@drawable/stat_sys_battery_29" android:maxLevel="29" />
          <item android:drawable="@drawable/stat_sys_battery_30" android:maxLevel="30" />
          <item android:drawable="@drawable/stat_sys_battery_31" android:maxLevel="31" />
          <item android:drawable="@drawable/stat_sys_battery_32" android:maxLevel="32" />
          <item android:drawable="@drawable/stat_sys_battery_33" android:maxLevel="33" />
          <item android:drawable="@drawable/stat_sys_battery_34" android:maxLevel="34" />
          <item android:drawable="@drawable/stat_sys_battery_35" android:maxLevel="35" />
          <item android:drawable="@drawable/stat_sys_battery_36" android:maxLevel="36" />
          <item android:drawable="@drawable/stat_sys_battery_37" android:maxLevel="37" />
          <item android:drawable="@drawable/stat_sys_battery_38" android:maxLevel="38" />
          <item android:drawable="@drawable/stat_sys_battery_39" android:maxLevel="39" />
          <item android:drawable="@drawable/stat_sys_battery_40" android:maxLevel="40" />
          <item android:drawable="@drawable/stat_sys_battery_41" android:maxLevel="41" />
          <item android:drawable="@drawable/stat_sys_battery_42" android:maxLevel="42" />
          <item android:drawable="@drawable/stat_sys_battery_43" android:maxLevel="43" />
          <item android:drawable="@drawable/stat_sys_battery_44" android:maxLevel="44" />
          <item android:drawable="@drawable/stat_sys_battery_45" android:maxLevel="45" />
          <item android:drawable="@drawable/stat_sys_battery_46" android:maxLevel="46" />
          <item android:drawable="@drawable/stat_sys_battery_47" android:maxLevel="47" />
          <item android:drawable="@drawable/stat_sys_battery_48" android:maxLevel="48" />
          <item android:drawable="@drawable/stat_sys_battery_49" android:maxLevel="49" />
          <item android:drawable="@drawable/stat_sys_battery_50" android:maxLevel="50" />
          <item android:drawable="@drawable/stat_sys_battery_51" android:maxLevel="51" />
          <item android:drawable="@drawable/stat_sys_battery_52" android:maxLevel="52" />
          <item android:drawable="@drawable/stat_sys_battery_53" android:maxLevel="53" />
          <item android:drawable="@drawable/stat_sys_battery_54" android:maxLevel="54" />
          <item android:drawable="@drawable/stat_sys_battery_55" android:maxLevel="55" />
          <item android:drawable="@drawable/stat_sys_battery_56" android:maxLevel="56" />
          <item android:drawable="@drawable/stat_sys_battery_57" android:maxLevel="57" />
          <item android:drawable="@drawable/stat_sys_battery_58" android:maxLevel="58" />
          <item android:drawable="@drawable/stat_sys_battery_59" android:maxLevel="59" />
          <item android:drawable="@drawable/stat_sys_battery_60" android:maxLevel="60" />
          <item android:drawable="@drawable/stat_sys_battery_61" android:maxLevel="61" />
          <item android:drawable="@drawable/stat_sys_battery_62" android:maxLevel="62" />
          <item android:drawable="@drawable/stat_sys_battery_63" android:maxLevel="63" />
          <item android:drawable="@drawable/stat_sys_battery_64" android:maxLevel="64" />
          <item android:drawable="@drawable/stat_sys_battery_65" android:maxLevel="65" />
          <item android:drawable="@drawable/stat_sys_battery_66" android:maxLevel="66" />
          <item android:drawable="@drawable/stat_sys_battery_67" android:maxLevel="67" />
          <item android:drawable="@drawable/stat_sys_battery_68" android:maxLevel="68" />
          <item android:drawable="@drawable/stat_sys_battery_69" android:maxLevel="69" />
          <item android:drawable="@drawable/stat_sys_battery_70" android:maxLevel="70" />
          <item android:drawable="@drawable/stat_sys_battery_71" android:maxLevel="71" />
          <item android:drawable="@drawable/stat_sys_battery_72" android:maxLevel="72" />
          <item android:drawable="@drawable/stat_sys_battery_73" android:maxLevel="73" />
          <item android:drawable="@drawable/stat_sys_battery_74" android:maxLevel="74" />
          <item android:drawable="@drawable/stat_sys_battery_75" android:maxLevel="75" />
          <item android:drawable="@drawable/stat_sys_battery_76" android:maxLevel="76" />
          <item android:drawable="@drawable/stat_sys_battery_77" android:maxLevel="77" />
          <item android:drawable="@drawable/stat_sys_battery_78" android:maxLevel="78" />
          <item android:drawable="@drawable/stat_sys_battery_79" android:maxLevel="79" />
          <item android:drawable="@drawable/stat_sys_battery_80" android:maxLevel="80" />
          <item android:drawable="@drawable/stat_sys_battery_81" android:maxLevel="81" />
          <item android:drawable="@drawable/stat_sys_battery_82" android:maxLevel="82" />
          <item android:drawable="@drawable/stat_sys_battery_83" android:maxLevel="83" />
          <item android:drawable="@drawable/stat_sys_battery_84" android:maxLevel="84" />
          <item android:drawable="@drawable/stat_sys_battery_85" android:maxLevel="85" />
          <item android:drawable="@drawable/stat_sys_battery_86" android:maxLevel="86" />
          <item android:drawable="@drawable/stat_sys_battery_87" android:maxLevel="87" />
          <item android:drawable="@drawable/stat_sys_battery_88" android:maxLevel="88" />
          <item android:drawable="@drawable/stat_sys_battery_89" android:maxLevel="89" />
          <item android:drawable="@drawable/stat_sys_battery_90" android:maxLevel="90" />
          <item android:drawable="@drawable/stat_sys_battery_91" android:maxLevel="91" />
          <item android:drawable="@drawable/stat_sys_battery_92" android:maxLevel="92" />
          <item android:drawable="@drawable/stat_sys_battery_93" android:maxLevel="93" />
          <item android:drawable="@drawable/stat_sys_battery_94" android:maxLevel="94" />
          <item android:drawable="@drawable/stat_sys_battery_95" android:maxLevel="95" />
          <item android:drawable="@drawable/stat_sys_battery_96" android:maxLevel="96" />
          <item android:drawable="@drawable/stat_sys_battery_97" android:maxLevel="97" />
          <item android:drawable="@drawable/stat_sys_battery_98" android:maxLevel="98" />
          <item android:drawable="@drawable/stat_sys_battery_99" android:maxLevel="99" />
          <item android:drawable="@drawable/stat_sys_battery_100" android:maxLevel="100" />
      </level-list>



    • Edit "systemui\res\drawables\stat_sys_battery_charge.xml" and replace with these:



      Code:
      <?xml version="1.0" encoding="utf-8"?>
      <level-list
        xmlns:android="http://schemas.android.com/apk/res/android">
          <item android:drawable="@drawable/stat_sys_battery_charge_anim0" android:maxLevel="0" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim1" android:maxLevel="1" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim2" android:maxLevel="2" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim3" android:maxLevel="3" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim4" android:maxLevel="4" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim5" android:maxLevel="5" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim6" android:maxLevel="6" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim7" android:maxLevel="7" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim8" android:maxLevel="8" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim9" android:maxLevel="9" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim10" android:maxLevel="10" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim11" android:maxLevel="11" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim12" android:maxLevel="12" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim13" android:maxLevel="13" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim14" android:maxLevel="14" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim15" android:maxLevel="15" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim16" android:maxLevel="16" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim17" android:maxLevel="17" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim18" android:maxLevel="18" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim19" android:maxLevel="19" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim20" android:maxLevel="20" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim21" android:maxLevel="21" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim22" android:maxLevel="22" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim23" android:maxLevel="23" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim24" android:maxLevel="24" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim25" android:maxLevel="25" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim26" android:maxLevel="26" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim27" android:maxLevel="27" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim28" android:maxLevel="28" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim29" android:maxLevel="29" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim30" android:maxLevel="30" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim31" android:maxLevel="31" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim32" android:maxLevel="32" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim33" android:maxLevel="33" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim34" android:maxLevel="34" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim35" android:maxLevel="35" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim36" android:maxLevel="36" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim37" android:maxLevel="37" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim38" android:maxLevel="38" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim39" android:maxLevel="39" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim40" android:maxLevel="40" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim41" android:maxLevel="41" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim42" android:maxLevel="42" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim43" android:maxLevel="43" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim44" android:maxLevel="44" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim45" android:maxLevel="45" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim46" android:maxLevel="46" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim47" android:maxLevel="47" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim48" android:maxLevel="48" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim49" android:maxLevel="49" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim50" android:maxLevel="50" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim51" android:maxLevel="51" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim52" android:maxLevel="52" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim53" android:maxLevel="53" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim54" android:maxLevel="54" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim55" android:maxLevel="55" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim56" android:maxLevel="56" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim57" android:maxLevel="57" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim58" android:maxLevel="58" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim59" android:maxLevel="59" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim60" android:maxLevel="60" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim61" android:maxLevel="61" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim62" android:maxLevel="62" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim63" android:maxLevel="63" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim64" android:maxLevel="64" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim65" android:maxLevel="65" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim66" android:maxLevel="66" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim67" android:maxLevel="67" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim68" android:maxLevel="68" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim69" android:maxLevel="69" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim70" android:maxLevel="70" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim71" android:maxLevel="71" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim72" android:maxLevel="72" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim73" android:maxLevel="73" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim74" android:maxLevel="74" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim75" android:maxLevel="75" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim76" android:maxLevel="76" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim77" android:maxLevel="77" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim78" android:maxLevel="78" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim79" android:maxLevel="79" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim80" android:maxLevel="80" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim81" android:maxLevel="81" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim82" android:maxLevel="82" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim83" android:maxLevel="83" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim84" android:maxLevel="84" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim85" android:maxLevel="85" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim86" android:maxLevel="86" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim87" android:maxLevel="87" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim88" android:maxLevel="88" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim89" android:maxLevel="89" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim90" android:maxLevel="90" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim91" android:maxLevel="91" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim92" android:maxLevel="92" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim93" android:maxLevel="93" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim94" android:maxLevel="94" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim95" android:maxLevel="95" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim96" android:maxLevel="96" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim97" android:maxLevel="97" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim98" android:maxLevel="98" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim99" android:maxLevel="99" />
          <item android:drawable="@drawable/stat_sys_battery_charge_anim100" android:maxLevel="100" />
      </level-list>


    • Compile SystemUI.apk
    • Copy Meta-Inf and AndroidManifest.xml from stock SystemUI.apk to your modded one.
    • That's it.

    • Then copy it to /system,set permissions to -rw-r-r.
    • Then copy it to /system/app.
    • Reboot the phone.
    9
    Ok... so sit down girls and boys. its gonna get bumpy :p

    first off i HATE smali :p its a PITA at the best of times. and is dam near impossible to troubleshoot.

    but you do get allot of info from the logs if you know what to look for.

    so for your reference on smali oppcode
    http://pallergabor.uw.hu/androidblog/dalvik_opcodes.html
    http://developer.android.com/reference/dalvik/bytecode/Opcodes.html
    i'll explain cause that is gobbldy goop.

    so the error! (tidied up a bit.)
    Code:
    VFY: register1 v11 type 12, wanted ref
    
    VFY: bad arg 2 (into Landroid/view/ViewGroup;)
    
    VFY:  rejecting call to Landroid/view/View;.inflate (Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;
    
    VFY:  rejecting opcode 0x71 at 0x01a7
    
    VFY:  rejected Lcom/android/systemui/statusbar/phone/PhoneStatusBar;.makeStatusBarView ()Landroid/view/View;

    Break it down to it's peices.

    Code:
    VFY: register1 v11 type 12, wanted ref
    Register v11 has a variable of type 12 (constant or such)
    but it wanted a Ref type(a type reference "an object")

    Code:
    VFY: bad arg 2 (into Landroid/view/ViewGroup;)
    
    VFY:  rejecting call to Landroid/view/View;.inflate (Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;

    argument 2 is bad in the call with those arguments

    Code:
    VFY:  rejecting opcode 0x71 at 0x01a7
    the call was a Opcode 0x71 (check the first reference link to find the info)

    0x71 is this
    invoke-static {parameters}, methodtocall
    Invokes a static method with parameters.

    ok now the easy part. look in the smali file in the crash data you will ahve changed part of the file go to that area.
    "com/android/systemui/statusbar/phone/PhoneStatusBar.smali"

    look for register v11 and chack that it is not used elsewhere for a differnet reason.

    Code:
    .method protected makeStatusBarView()Landroid/view/View;
        .locals 12
    
        .prologue
        const/16 v11, 0x8
    
        const/4 v10, 0x0
    
        .line 273
        iget-object v0, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
    
        .line 275
        .local v0, context:Landroid/content/Context;
        invoke-virtual {v0}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
    
        move-result-object v3
    
        .line 277
        .local v3, res:Landroid/content/res/Resources;
        invoke-virtual {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->updateDisplaySize()V
    
        .line 278
        invoke-virtual {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->loadDimens()V
    
        .line 280
        const v8, 0x105000e
    
        invoke-virtual {v3, v8}, Landroid/content/res/Resources;->getDimensionPixelSize(I)I
    
        move-result v8
    
        iput v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mIconSize:I
    
        .line 282
        const v8, 0x7f030008
    
        invoke-static {v0, v8, v10}, Landroid/view/View;->inflate(Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;
    
        move-result-object v1
    
        check-cast v1, Lcom/android/systemui/statusbar/phone/ExpandedView;
    
        .line 287
        .local v1, expanded:Lcom/android/systemui/statusbar/phone/ExpandedView;
        iput-object p0, v1, Lcom/android/systemui/statusbar/phone/ExpandedView;->mService:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
    
        .line 289
        const v8, 0x7f030003
    
        invoke-static {v0, v8, v10}, Landroid/view/View;->inflate(Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;
    
        move-result-object v8
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mIntruderAlertView:Landroid/view/View;
    
        .line 290
        iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mIntruderAlertView:Landroid/view/View;
    
        invoke-virtual {v8, v11}, Landroid/view/View;->setVisibility(I)V
    
        .line 291
        iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mIntruderAlertView:Landroid/view/View;
    
        const/4 v9, 0x1
    
        invoke-virtual {v8, v9}, Landroid/view/View;->setClickable(Z)V
    
        .line 293
        const v8, 0x7f030006
    
        invoke-static {v0, v8, v10}, Landroid/view/View;->inflate(Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;
    
        move-result-object v4
    
        check-cast v4, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
    
        .line 295
        .local v4, sb:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
        iput-object p0, v4, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->mService:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
    
        .line 296
        iput-object v4, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusBarView:Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;
    
        .line 299
        :try_start_0
        iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mWindowManager:Landroid/view/IWindowManager;
    
        invoke-interface {v8}, Landroid/view/IWindowManager;->hasNavigationBar()Z
    
        move-result v5
    
        .line 300
        .local v5, showNav:Z
        if-eqz v5, :cond_0
    
        .line 301
        const v8, 0x7f030004
    
        const/4 v9, 0x0
    
        invoke-static {v0, v8, v9}, Landroid/view/View;->inflate(Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;
    
        move-result-object v8
    
        check-cast v8, Lcom/android/systemui/statusbar/phone/NavigationBarView;
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNavigationBarView:Lcom/android/systemui/statusbar/phone/NavigationBarView;
    
        .line 304
        iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNavigationBarView:Lcom/android/systemui/statusbar/phone/NavigationBarView;
    
        iget v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDisabled:I
    
        invoke-virtual {v8, v9}, Lcom/android/systemui/statusbar/phone/NavigationBarView;->setDisabledFlags(I)V
        :try_end_0
        .catch Landroid/os/RemoteException; {:try_start_0 .. :try_end_0} :catch_0
    
        .line 311
        .end local v5           #showNav:Z
        :cond_0
        :goto_0
        const/4 v8, -0x1
    
        iput v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPixelFormat:I
    
        .line 312
        const v8, 0x7f0e0024
    
        invoke-virtual {v4, v8}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
    
        move-result-object v8
    
        check-cast v8, Landroid/widget/LinearLayout;
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mStatusIcons:Landroid/widget/LinearLayout;
    
        .line 313
        const v8, 0x7f0e0023
    
        invoke-virtual {v4, v8}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
    
        move-result-object v8
    
        check-cast v8, Lcom/android/systemui/statusbar/phone/IconMerger;
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNotificationIcons:Lcom/android/systemui/statusbar/phone/IconMerger;
    
        .line 314
        const v8, 0x7f0e0022
    
        invoke-virtual {v4, v8}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
    
        move-result-object v8
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mMoreIcon:Landroid/view/View;
    
        .line 315
        iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNotificationIcons:Lcom/android/systemui/statusbar/phone/IconMerger;
    
        iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mMoreIcon:Landroid/view/View;
    
        invoke-virtual {v8, v9}, Lcom/android/systemui/statusbar/phone/IconMerger;->setOverflowIndicator(Landroid/view/View;)V
    
        .line 316
        const v8, 0x7f0e0021
    
        invoke-virtual {v4, v8}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
    
        move-result-object v8
    
        check-cast v8, Landroid/widget/LinearLayout;
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mIcons:Landroid/widget/LinearLayout;
    
        .line 317
        const v8, 0x7f0e0029
    
        invoke-virtual {v4, v8}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
    
        move-result-object v8
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTickerView:Landroid/view/View;
    
        .line 319
        new-instance v8, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$ExpandedDialog;
    
        invoke-direct {v8, p0, v0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$ExpandedDialog;-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;Landroid/content/Context;)V
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedDialog:Landroid/app/Dialog;
    
        .line 320
        iput-object v1, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
    
        .line 321
        const v8, 0x7f0e003f
    
        invoke-virtual {v1, v8}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
    
        move-result-object v8
    
        check-cast v8, Lcom/android/systemui/statusbar/policy/NotificationRowLayout;
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPile:Lcom/android/systemui/statusbar/policy/NotificationRowLayout;
    
        .line 322
        iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mPile:Lcom/android/systemui/statusbar/policy/NotificationRowLayout;
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedContents:Landroid/view/View;
    
        .line 323
        const v8, 0x7f0e003d
    
        invoke-virtual {v1, v8}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
    
        move-result-object v8
    
        check-cast v8, Landroid/widget/TextView;
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNoNotificationsTitle:Landroid/widget/TextView;
    
        .line 324
        iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNoNotificationsTitle:Landroid/widget/TextView;
    
        invoke-virtual {v8, v11}, Landroid/widget/TextView;->setVisibility(I)V
    
        .line 326
        const v8, 0x7f0e003c
    
        invoke-virtual {v1, v8}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
    
        move-result-object v8
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButton:Landroid/view/View;
    
        .line 327
        iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButton:Landroid/view/View;
    
        iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButtonListener:Landroid/view/View$OnClickListener;
    
        invoke-virtual {v8, v9}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
    
        .line 328
        iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButton:Landroid/view/View;
    
        const/4 v9, 0x0
    
        invoke-virtual {v8, v9}, Landroid/view/View;->setAlpha(F)V
    
        .line 329
        iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mClearButton:Landroid/view/View;
    
        const/4 v9, 0x0
    
        invoke-virtual {v8, v9}, Landroid/view/View;->setEnabled(Z)V
    
        .line 330
        const v8, 0x7f0e003a
    
        invoke-virtual {v1, v8}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
    
        move-result-object v8
    
        check-cast v8, Lcom/android/systemui/statusbar/policy/DateView;
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mDateView:Lcom/android/systemui/statusbar/policy/DateView;
    
        .line 331
        const v8, 0x7f0e003b
    
        invoke-virtual {v1, v8}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
    
        move-result-object v8
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSettingsButton:Landroid/view/View;
    
        .line 332
        iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSettingsButton:Landroid/view/View;
    
        iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mSettingsButtonListener:Landroid/view/View$OnClickListener;
    
        invoke-virtual {v8, v9}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
    
        .line 333
        const v8, 0x7f0e003e
    
        invoke-virtual {v1, v8}, Lcom/android/systemui/statusbar/phone/ExpandedView;->findViewById(I)Landroid/view/View;
    
        move-result-object v8
    
        check-cast v8, Landroid/widget/ScrollView;
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mScrollView:Landroid/widget/ScrollView;
    
        .line 335
        new-instance v8, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;
    
        invoke-direct {v8, p0, v0, v4}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar$MyTicker;-><init>(Lcom/android/systemui/statusbar/phone/PhoneStatusBar;Landroid/content/Context;Landroid/view/View;)V
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTicker:Lcom/android/systemui/statusbar/phone/Ticker;
    
        .line 337
        const v8, 0x7f0e002b
    
        invoke-virtual {v4, v8}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
    
        move-result-object v7
    
        check-cast v7, Lcom/android/systemui/statusbar/phone/TickerView;
    
        .line 338
        .local v7, tickerView:Lcom/android/systemui/statusbar/phone/TickerView;
        iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTicker:Lcom/android/systemui/statusbar/phone/Ticker;
    
        iput-object v8, v7, Lcom/android/systemui/statusbar/phone/TickerView;->mTicker:Lcom/android/systemui/statusbar/phone/Ticker;
    
        .line 340
        const v8, 0x7f03001a
    
        invoke-static {v0, v8, v10}, Landroid/view/View;->inflate(Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;
    
        move-result-object v8
    
        check-cast v8, Lcom/android/systemui/statusbar/phone/TrackingView;
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTrackingView:Lcom/android/systemui/statusbar/phone/TrackingView;
    
        .line 341
        iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTrackingView:Lcom/android/systemui/statusbar/phone/TrackingView;
    
        iput-object p0, v8, Lcom/android/systemui/statusbar/phone/TrackingView;->mService:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
    
        .line 342
        iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mTrackingView:Lcom/android/systemui/statusbar/phone/TrackingView;
    
        const v9, 0x7f0e008f
    
        invoke-virtual {v8, v9}, Lcom/android/systemui/statusbar/phone/TrackingView;->findViewById(I)Landroid/view/View;
    
        move-result-object v8
    
        check-cast v8, Lcom/android/systemui/statusbar/phone/CloseDragHandle;
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCloseView:Lcom/android/systemui/statusbar/phone/CloseDragHandle;
    
        .line 343
        iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mCloseView:Lcom/android/systemui/statusbar/phone/CloseDragHandle;
    
        iput-object p0, v8, Lcom/android/systemui/statusbar/phone/CloseDragHandle;->mService:Lcom/android/systemui/statusbar/phone/PhoneStatusBar;
    
        .line 345
        const/high16 v8, 0x7f0a
    
        invoke-virtual {v3, v8}, Landroid/content/res/Resources;->getDimensionPixelSize(I)I
    
        move-result v8
    
        iput v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mEdgeBorder:I
    
        .line 348
        invoke-direct {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->setAreThereNotifications()V
    
        .line 351
        new-instance v8, Lcom/android/systemui/statusbar/policy/LocationController;
    
        iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
    
        invoke-direct {v8, v9}, Lcom/android/systemui/statusbar/policy/LocationController;-><init>(Landroid/content/Context;)V
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mLocationController:Lcom/android/systemui/statusbar/policy/LocationController;
    
        .line 352
        new-instance v8, Lcom/android/systemui/statusbar/policy/BatteryController;
    
        iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
    
        invoke-direct {v8, v9}, Lcom/android/systemui/statusbar/policy/BatteryController;-><init>(Landroid/content/Context;)V
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBatteryController:Lcom/android/systemui/statusbar/policy/BatteryController;
    
        .line 353
        iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBatteryController:Lcom/android/systemui/statusbar/policy/BatteryController;
    
        const v8, 0x7f0e0027
    
        invoke-virtual {v4, v8}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
    
        move-result-object v8
    
        check-cast v8, Landroid/widget/ImageView;
    
        invoke-virtual {v9, v8}, Lcom/android/systemui/statusbar/policy/BatteryController;->addIconView(Landroid/widget/ImageView;)V
    
        .line 354
        new-instance v8, Lcom/android/systemui/statusbar/policy/NetworkController;
    
        iget-object v9, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mContext:Landroid/content/Context;
    
        invoke-direct {v8, v9}, Lcom/android/systemui/statusbar/policy/NetworkController;-><init>(Landroid/content/Context;)V
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNetworkController:Lcom/android/systemui/statusbar/policy/NetworkController;
    
        .line 355
        const v8, 0x7f0e0026
    
        invoke-virtual {v4, v8}, Lcom/android/systemui/statusbar/phone/PhoneStatusBarView;->findViewById(I)Landroid/view/View;
    
        move-result-object v6
    
        check-cast v6, Lcom/android/systemui/statusbar/SignalClusterView;
    
        .line 357
        .local v6, signalCluster:Lcom/android/systemui/statusbar/SignalClusterView;
        iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNetworkController:Lcom/android/systemui/statusbar/policy/NetworkController;
    
        invoke-virtual {v8, v6}, Lcom/android/systemui/statusbar/policy/NetworkController;->addSignalCluster(Lcom/android/systemui/statusbar/policy/NetworkController$SignalCluster;)V
    
        .line 358
        iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mNetworkController:Lcom/android/systemui/statusbar/policy/NetworkController;
    
        invoke-virtual {v6, v8}, Lcom/android/systemui/statusbar/SignalClusterView;->setNetworkController(Lcom/android/systemui/statusbar/policy/NetworkController;)V
    
        .line 365
        new-instance v8, Lcom/android/systemui/recent/RecentTasksLoader;
    
        invoke-direct {v8, v0}, Lcom/android/systemui/recent/RecentTasksLoader;-><init>(Landroid/content/Context;)V
    
        iput-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mRecentTasksLoader:Lcom/android/systemui/recent/RecentTasksLoader;
    
        .line 366
        invoke-virtual {p0}, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->updateRecentsPanel()V
    
        .line 369
        new-instance v2, Landroid/content/IntentFilter;
    
        invoke-direct {v2}, Landroid/content/IntentFilter;-><init>()V
    
        .line 370
        .local v2, filter:Landroid/content/IntentFilter;
        const-string v8, "android.intent.action.CONFIGURATION_CHANGED"
    
        invoke-virtual {v2, v8}, Landroid/content/IntentFilter;->addAction(Ljava/lang/String;)V
    
        .line 371
        const-string v8, "android.intent.action.CLOSE_SYSTEM_DIALOGS"
    
        invoke-virtual {v2, v8}, Landroid/content/IntentFilter;->addAction(Ljava/lang/String;)V
    
        .line 372
        const-string v8, "android.intent.action.SCREEN_OFF"
    
        invoke-virtual {v2, v8}, Landroid/content/IntentFilter;->addAction(Ljava/lang/String;)V
    
        .line 373
        iget-object v8, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mBroadcastReceiver:Landroid/content/BroadcastReceiver;
    
        invoke-virtual {v0, v8, v2}, Landroid/content/Context;->registerReceiver(Landroid/content/BroadcastReceiver;Landroid/content/IntentFilter;)Landroid/content/Intent;
    
        const v6, 0x7f03001c
    
        invoke-static {v0, v6, v11}, Landroid/view/View;->inflate(Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;
    
        move-result-object v5
    
        check-cast v5, Lcom/lidroid/systemui/quickpanel/PowerWidget;
    
        invoke-virtual {v5}, Lcom/lidroid/systemui/quickpanel/PowerWidget;->setupWidget()V
    
        iget-object v6, p0, Lcom/android/systemui/statusbar/phone/PhoneStatusBar;->mExpandedView:Lcom/android/systemui/statusbar/phone/ExpandedView;
    
        invoke-virtual {v6, v5, v11}, Lcom/android/systemui/statusbar/phone/ExpandedView;->addView(Landroid/view/View;I)V
    
        .line 375
        return-object v4
    
        .line 306
        .end local v2           #filter:Landroid/content/IntentFilter;
        .end local v6           #signalCluster:Lcom/android/systemui/statusbar/SignalClusterView;
        .end local v7           #tickerView:Lcom/android/systemui/statusbar/phone/TickerView;
        :catch_0
        move-exception v8
    
        goto/16 :goto_0
    .end method

    that is the entire method (i know it is alot. but waht i needed was at the top and your edit was at the bottom.)

    note a the top.
    Code:
        const/16 v11, 0x8

    note the Possible lines that crashed
    Code:
        invoke-static {v0, v6, v11}, Landroid/view/View;->inflate(Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;
    Code:
        invoke-virtual {v6, v5, v11}, Lcom/android/systemui/statusbar/phone/ExpandedView;->addView(Landroid/view/View;I)V

    v11 is not a "Landroid/view/View" as required by the method call hence the crash.
    v11 is used to set the vissiblity of some other stuff
    as seen on a few lines looking like this

    Code:
    invoke-virtual {v8, v11}, Landroid/view/View;->setVisibility(I)V

    i'm taking a punt with reading over the smali file and as a guess i would say that you need to change the v11 to v1 but i need the file from a working phone to get the correct register numbers and cross ref them, to the new file to make sure that the registers are pointing to the correct view.

    So i dont have a concise answer for you but if someone can upload the smali file from a working mod i will cross ref and update the post ( or start another with the how to / what i did )

    Ok time for bed :) Smali makes my brain hurt :p
    But if you look at it logicaly it is really VERY VERY simple.
    The calls all match a java call. and the registers (vNumbers) are simply the variables being fed in. it is just the file that makes it look confusing. you can use this smali syntax highliting for NPP
    http://androidcracking.blogspot.com.au/2011/02/smali-syntax-highlighting-for-notepad.html
    that was BEYOND helpfull to me when i was doing alot of smali hacks.

    Pvy.

    Sent from my PC and my Phone and my Desk and my Notepad
    7
    I am trying to do some Status Bar tweaks and would really appreciate someone with Theming experience to assist me in this regard. I would like to know which file in the SystemUI.apk handles the following:

    1. Change the AM/PM style. (Making it all caps and a bit small.
    2. Hiding the Captions (WiFi, Data, Bluetooth etc)
    So Please Help :) Thanks.

    1 requires code edits probably easyer to make a custom clock from android source.

    2 is easy add the visible:gone to the lable text in the XML that holds the widget layout. it is the layout that is named
    Code:
    power_widget_button.xml
    i think

    I think when use variable higher than last variable in public.xml and still there is a unused variable within that range.That'll give that error.

    Because you have deleted the sync png.

    Public ID's (because there seams to be alot of confusion!)
    in a nutshell

    the public ID's are used in the smali code to reference a resource. be it a drawable / layout / string / colour / ect ect...

    the ID's are made of certain parts

    Code:
    <public type="drawable" name="stat_lock_screen_on" id="0x7f0200f6" />
    see the type is a drawable here. this refers to a image this time.
    notice the ID this is the important part.
    0x7f0200f6

    the ID is made of 3 parts

    part 1 - "0x7f" - all applications look like this at the begining frameworks are different.

    part 2 - "02" - refers to the "Type" ie 02="drawable" (these change from application to application so be carefull... if you are copying stuff from one app to another you'll get an error if this is wrong.)

    part 3 - "00f6" - this is the ID of the drawable counted in HEX (base 16 (0 to F))

    how to count in hex
    Code:
    1 2 3 4 5 6 7 8 9 a b c d e f 10 11 12 13 14 15 16 17 18 19 1a 1b 1c ..... 99 9a 9b 9c 9d 9e 9f a0 ......... f9 fa fb fc fd fe ff 100
    100(hex) does not equal 100 (decimal) so when an error gives you a decimal id to goto you'll need to do a conversion. (Google it is the easiest way)

    now the interesting bits. public XML compile errors!
    if you have an error that says spmething similar to
    Code:
    Public entry identifier 0xffffffff entry is larger than available symbols (index ###, total symbols ###)

    then your ID's are not correct the hex is too large. it is slow and annoying but you will need to go through and find an id that is missing and use that one. bare in mind that any changes to ID's require a change to the smali to match or you will get problems with the wrong pictures being used for the wrong things. (see above on hex counting)


    if you get an error like
    Code:
    Public symbol some_type/some_file declared here is not defined
    these are generaly linked to the above error and go hand in hand because there is no reference in the public xml to the defined item.

    if you get an error like
    Code:
    Error parsing XML: not well formed (invalid token)
    you made a booboo in your public xml make sure that EVERY Item has a opening and a closing tag this error happens when you miss or delete part of a tag.
    Good
    Code:
     <public type="drawable" name="stat_2g3g_off" id="0x7f0200e1" />
    also good
    Code:
     <public type="drawable" name="stat_2g3g_off" id="0x7f0200e1"></public>

    Bad
    Code:
     <public type="drawable" name="stat_2g3g_off" id="0x7f0200e1">

    the differnece is very minor but very Important!

    i have lots more info on public xmls but i think this will solve 90% of problems. if there are any more issues post the error and i'll try tell you the problem :)

    sorry neectron for highjack but i figure this info is helpfull to this thread.

    Pvy

    Sent from my Galaxy Nexus using Tapatalk 2
    6
    sorry for more hijacky goodness Neectron, but cause i've had a few pms about this now. i thought i'd share.

    if your Public.xml contains the ids and you have to assign new ones your status bar will crash. no ifs no buts, it will crash when you run it. (or you will get some whacked images)
    7a5f0a76ad21b6e159038c.png


    This process can be used for any mod where you add id's + smali files

    How to fix this :p

    Read entire post FIRST! as i can tend to ramble.

    Neectron covered it here in brief. in the OP but some people are getting confused.

    Waring:If the variables you are going to add to public.xml is already used,then you will have edit more smali.
    Like if variable for "stat_data_on ": 0x7f0200f0 is already used,then you have to change it to 0x7f02xxxx,not used.
    Then you have edit systemui\smali\com\lidroid\systemui\quickpanel\MobileDataButton.smali.
    Find 0x7f0200f0 and change it to new 0x7f02xxxx you have addedin public.xml.Similarly for other variables also,if it is used change the respective .smali

    You will need a Grep tool (standard in linux)
    for Windows (astrogrep)

    i'll go over the windows side of things cause thats what i have right now.

    BEFORE YOU CHANGE ANY OF THE ID'S
    make sure you know what you want to change them to.
    see this post for info on Public Id's and how to figure the suckers out
    what i do is go like this

    say these drawable id's are doubled up and the rest of the id is fine
    Code:
    <public type="drawable" name="stat_2g3g_off" id="0x7f0200e1" />
    <public type="drawable" name="stat_2g3g_on" id="0x7f0200e2" />
    <public type="drawable" name="stat_3g_on" id="0x7f0200e3" />
    <public type="drawable" name="stat_airplane_off" id="0x7f0200e4" />
    <public type="drawable" name="stat_airplane_on" id="0x7f0200e5" />

    i put what i was gonna change it to next to it for reference
    Code:
    <public type="drawable" name="stat_2g3g_off" id="0x7f0200e1" /> -> 0x7f0200e6
    <public type="drawable" name="stat_2g3g_on" id="0x7f0200e2" /> -> 0x7f0200e7
    <public type="drawable" name="stat_3g_on" id="0x7f0200e3" /> -> 0x7f0200e8
    <public type="drawable" name="stat_airplane_off" id="0x7f0200e4" /> -> 0x7f0200e9
    <public type="drawable" name="stat_airplane_on" id="0x7f0200e5" /> -> 0x7f0200ea

    this will make the app fail to recompile (this is to help remind you you still have work to do)

    Next Fireup Astrogrep.

    Pick the directory that your decompiled app is in and nav to the folder containing the power widget smali files ( eg c:/decompiled-statusbar-of-awesomeness/src/com/android/statusbar/quickpannel)

    <THIS SPOT HERE> (ignor for now will make sence at the bottom)

    Astro/Awesome Grep for the first original ID
    eg.
    Code:
    <public type="drawable" name="stat_2g3g_off" id="0x7f0200e1" /> -> 0x7f0200e6

    grep for
    Code:
    0x7f0200e1

    Astro will give you the line numbers and file names for EVERY instance of that text string. ( I LOVE THIS APP it is beyond handy! )

    then replace all the ones that were found with the new one you have selected. and save all the files. MAKE SURE YOU DONT EDIT ANY OF THE FILES THAT ARE IRREVERENT! Only edit the files you have added into the thing.

    then edit your public.xml to match and remove your note to self.

    Code:
    <public type="drawable" name="stat_2g3g_off" id="0x7f0200e6" />

    next you return to the <THIS SPOT HERE> and do the next id that needs to be changed. rinse and repeat and your
    decompiled-statusbar-of-awesomeness will be a functioning-statusbar-of-awesomeness in no time.

    Enjoy, feel free to buzz into the thread instead of PM's i'll help here. :) i think i covered it all. i'm sure Neectron will agree if i say that info shared here is better than info shared via PM.

    Pvy.