5,597,198 Members 43,450 Now Online
XDA Developers Android and Mobile Development Forum

[guide][GT-I9152] how to modifying systemui

Tip us?
 
unclefab
Old
(Last edited by unclefab; 22nd February 2014 at 07:29 PM.)
#21  
Senior Member
Thanks Meter 177
Posts: 273
Join Date: Jun 2012
It works, terima kasih banyak kawan (thanks a lot my friend)!
Actually your SystemUi fc everytime the screen orientation changes, maybe cuz it's much heavier than the original (like 1 mb more), so what I did is that I decompiled it, found what changes you made and reproduced them on the original SystemUI.
I saw you added in res/values/public:

<public type="style" name="SystemBarNotificationText" id="0x7f10002b" />
<public type="style" name="SystemBarPanelSettingsRow" id="0x7f10002c" />
<public type="style" name="SystemBarPanelSettingsIcon" id="0x7f10002d" />
<public type="style" name="SystemBarPanelSettingsContents" id="0x7f10002e" />
<public type="style" name="SystemBarPanelSettingsPanelSeparator" id="0x7f10002f" />

but actually it's not needed. You added as well in res/values/styles:

<style name="SystemBarNotificationText">
<item name="android:textSize">16.0sp</item>
<item name="android:textColor">#ff999999</item>
</style>
<style name="SystemBarPanelSettingsRow">
<item name="androidrientation">horizontal</item>
<item name="android:background">?android:listChoiceBackg roundIndicator</item>
<item name="androidaddingRight">16.0dip</item>
<item name="android:layout_width">fill_parent</item>
<item name="android:layout_height">64.0dip</item>
</style>
<style name="SystemBarPanelSettingsIcon">
<item name="android:layout_width">64.0dip</item>
<item name="android:layout_height">fill_parent</item>
<item name="android:scaleType">center</item>
</style>
<style name="SystemBarPanelSettingsContents">
<item name="android:textSize">18.0sp</item>
<item name="android:textColor">?android:textColorPrimary </item>
<item name="android:layout_gravity">left|center</item>
<item name="android:layout_width">0.0dip</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:layout_weight">1.0</item>
</style>
<style name="SystemBarPanelSettingsPanelSeparator">
<item name="android:background">@*android:drawable/divider_horizontal_dark</item>
<item name="android:layout_width">fill_parent</item>
<item name="android:layout_height">1.0dip</item>
<item name="android:layout_marginRight">0.0dip</item>

but it's not needed either.
I found why my previous attempts failed, it's because I stubbornly kept on editing my mega 6.3's layout/navigation_bar.xml (replacing the APKTOOL_DUMMY fields by tw_navigationbar_bg) instead of using the one from the mega 5.8, for some reasons there are lines in the 6.3's navigation_bar.xml that prevent the navbar from working.
A big thanks again, I pressed the thanks button and to thank you even more now I put some SystemUI mods here...

The following mods have been tested on I9200, but they should work on all mega variants.
First you have to decompile SystemUi (see OP if you get recompile errors), then let's start.

ADD MORE BUTTONS TO THE QUICK SETTINGS PANEL

Navigate to res/values/integers.xml and find:

<integer name="quick_settings_num_columns">5</integer>

Change the 5 to whatever value pleases you. Mine is set at 9, dunno if it works for values above but for sure it works with 6, 7, 8 and 9.

CHANGE THE BATTERY TEXT COLOR

Navigate to res/layout/status_bar.xml and find:

<TextView android:textSize="12.0dip" android:textColor="#ffffffff" android:layout_gravity="center" android:id="@id/battery_text" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/status_bar_network_name_separator" />
<ImageView android:gravity="center" android:id="@id/battery" android:layout_width="wrap_content" android:layout_height="wrap_content" />

Replace #ffffffff by your favorite color.

CHANGE CLOCK COLOR

Navigate to res/layout/status_bar.xml and find:

<com.android.systemui.statusbar.policy.Clock android:textSize="@dimen/status_bar_clock_text_size" android:textColor="#ffffffff" android:ellipsize="none" android:gravity="left|center" android:id="@id/clock" androidaddingLeft="3.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" android:includeFontPadding="false" />

Replace #ffffffff by your favorite color.

CHANGE COLORS IN EXPANDED NOTIFICATIONS

Navigate to res/layout/status_bar_expanded_header.xml and find:

<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Clock" android:textColor= @Color/notification_header_clock_color" android:id="@id/clock" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="@dimen/notification_panel_header_clock_margin_left" android:layout_marginTop="-3.0dip" android:singleLine="true" systemui:ampmSmall="true" />

Change @Color/notification_header_clock_color with your favorite color, and don't forget to start with # (for example #ffffffff is full black).
Then in the same xml find:

<com.android.systemui.statusbar.policy.DateView android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Date" android:textColor= @Color/notification_header_date_color" android:gravity="bottom" android:id="@id/date" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginLeft="8.0dip" android:layout_marginRight="4.0dip" android:layout_marginBottom="@dimen/notification_panel_header_date_margin_bottom" android:singleLine="true" />

Change @Color/notification_header_date_color with your favorite color, and don't forget to start with # (for example #ffffffff is full black).
Then navigate to res/values/colors and change colors to your liking (or, if you like green you can use mine, I've attached it)... Some examples:

-notification_panel_solid_background (for notification panel, #ff000000 is full black, #00000000 is 100% transparent, #3F000000 is black with 75% transparency, #7F000000 is black with 50% transparency, #BF000000 is black with 25% transparency)

-quick_setting_btn_divider_color (to make transparent the divisions between toggle buttons).

Don't edit:

<item type="color" name="toggle_slider_background_color">@drawable/notification_background_color</item> and
<item type="color" name="toggle_slider_divider_color" @Color/toggle_slider_background_color</item>

MAKE THE CLEAR BUTTON TRANSPARENT

This one is easy, just change the 4 quick_panel_clearbtn in res/drawable-hdpi with any transparent 9png files, or use the ones I attached here.
DO NOT use non 9png files, if you don't know why do some search on the forum.

MAKE THE TOGGLES TRANSPARENT

Another easy one, just change the tw_quick_panel_quick_setting_button_bg_normal.9.pn g in res/drawable-hdpi with the one attached here.
DO NOT use non 9png files, if you don't know why do some search on the forum.

MAKE NAVBAR TRANSPARENT

Go to res/values/drawables.xml and find:

<item type="drawable" name="tw_navigationbar_bg">

Change the color to #00000000 for 100% transparent, #3F000000 for black with 75% transparency, #7F000000 for black with 50% transparency, #BF000000 for black with 25% transparency.
In the same file you will see that there are other colors that can be edited, try and test

MAKE NAVBAR AND NOTIFICATION BAR SMALLER

Yep, cuz now that you have a nice navbar you may find that it's pretty big...
Decompile framework-res.apk.
Navigate to res/values/dimens.xml and find:

status_bar_height

Change the value, as for me I changed it from 25 to 20.
Then just below you see:

dimen name="navigation_bar_height

Change the size, as for me I changed it from 48 to 24.
Below there's navigation_bar_height_landscape, you can edit it as well.

Enjoy!
 
sitifire
Old
#22  
Member - OP
Thanks Meter 40
Posts: 81
Join Date: Apr 2013
Location: Tanjungpandan
Quote:
Originally Posted by unclefab View Post
It works, terima kasih banyak kawan (thanks a lot my friend)!
Actually your SystemUi fc everytime the screen orientation changes, maybe cuz it's much heavier than mine (like 1 mb more) so what I did is that I decompiled it, found what changes you made and reproduced them on my original SystemUI.
I saw you added in res/values/public

<public type="style" name="SystemBarNotificationText" id="0x7f10002b" />
<public type="style" name="SystemBarPanelSettingsRow" id="0x7f10002c" />
<public type="style" name="SystemBarPanelSettingsIcon" id="0x7f10002d" />
<public type="style" name="SystemBarPanelSettingsContents" id="0x7f10002e" />
<public type="style" name="SystemBarPanelSettingsPanelSeparator" id="0x7f10002f" />

but actually it's not needed. You added as well in res/values/styles

<style name="SystemBarNotificationText">
<item name="android:textSize">16.0sp</item>
<item name="android:textColor">#ff999999</item>
</style>
<style name="SystemBarPanelSettingsRow">
<item name="androidrientation">horizontal</item>
<item name="android:background">?android:listChoiceBackg roundIndicator</item>
<item name="androidaddingRight">16.0dip</item>
<item name="android:layout_width">fill_parent</item>
<item name="android:layout_height">64.0dip</item>
</style>
<style name="SystemBarPanelSettingsIcon">
<item name="android:layout_width">64.0dip</item>
<item name="android:layout_height">fill_parent</item>
<item name="android:scaleType">center</item>
</style>
<style name="SystemBarPanelSettingsContents">
<item name="android:textSize">18.0sp</item>
<item name="android:textColor">?android:textColorPrimary </item>
<item name="android:layout_gravity">left|center</item>
<item name="android:layout_width">0.0dip</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:layout_weight">1.0</item>
</style>
<style name="SystemBarPanelSettingsPanelSeparator">
<item name="android:background">@*android:drawable/divider_horizontal_dark</item>
<item name="android:layout_width">fill_parent</item>
<item name="android:layout_height">1.0dip</item>
<item name="android:layout_marginRight">0.0dip</item>

but it's not needed either. I found why my previous attempts failed, it's because I stubbornly kept on editing my mega 6.3's layout/navigation_bar.xml (replacing the APKTOOL_DUMMY fields by tw_navigationbar_bg) instead of using the one from the mega 5.8, for some reasons there are lines in the 6.3's navigation_bar.xml that prevent the navbar from working.
A big thanks again, I pressed the thanks button and to thank you even better now I put some SystemUI mods here...

ADD MORE BUTTONS TO THE QUICK SETTINGS PANEL

Navigate to res/values/integers.xml and find

<integer name="quick_settings_num_columns">5</integer>

Change the 5 to whatever value pleases you. Mine is set at 9, dunno if it works for values above but for sure it works with 6, 7, 8 and 9.

CHANGE THE BATTERY TEXT COLOR

Navigate to res/layout/status_bar.xml and find

<TextView android:textSize="12.0dip" android:textColor="#ffffffff" android:layout_gravity="center" android:id="@id/battery_text" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/status_bar_network_name_separator" />
<ImageView android:gravity="center" android:id="@id/battery" android:layout_width="wrap_content" android:layout_height="wrap_content" />

Replace #ffffffff by your favorite color.

CHANGE CLOCK COLOR

Navigate to res/layout/status_bar.xml and find

<com.android.systemui.statusbar.policy.Clock android:textSize="@dimen/status_bar_clock_text_size" android:textColor="#ffffffff" android:ellipsize="none" android:gravity="left|center" android:id="@id/clock" androidaddingLeft="3.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" android:includeFontPadding="false" />

Replace #ffffffff by your favorite color.

CHANGE COLORS IN EXPANDED NOTIFICATIONS

Navigate to res/layout/status_bar_expanded_header.xml and find

<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Clock" android:textColor= @Color/notification_header_clock_color" android:id="@id/clock" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="@dimen/notification_panel_header_clock_margin_left" android:layout_marginTop="-3.0dip" android:singleLine="true" systemui:ampmSmall="true" />

Change @Color/notification_header_clock_color with your favorite color, and don't forget to start with # (for example #ffffffff is full black). Then in the same xml find

<com.android.systemui.statusbar.policy.DateView android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Date" android:textColor= @Color/notification_header_date_color" android:gravity="bottom" android:id="@id/date" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginLeft="8.0dip" android:layout_marginRight="4.0dip" android:layout_marginBottom="@dimen/notification_panel_header_date_margin_bottom" android:singleLine="true" />

Change @Color/notification_header_date_color with your favorite color, and don't forget to start with # (for example #ffffffff is full black).

MAKE THE CLEAR BUTTON TRANSPARENT

This one is easy, just change the 4 quick_panel_clearbtn in res/drawable-hdpi with any transparent 9png files, or use the one I attached here.

More to come in a minute, for now I save my work cuz it rains and I'm affraid of power shortage mati lampu
welcome bro...glad to know it works on yours... and thanks for adding some guide too... I just a noob which just followed other guides in XDA...
 
shazzl
Old
#23  
shazzl's Avatar
Senior Member
Thanks Meter 82
Posts: 315
Join Date: Jan 2013
Location: Banting
Quote:
Originally Posted by sitifire View Post
welcome bro...glad to know it works on yours... and thanks for adding some guide too... I just a noob which just followed other guides in XDA...
Can u help me i want the partition info so you can flash with cwmrecovery or twpr...

Open terminal emulator
su
ls -al /dev/block/platform/msm_sdcc.1/by-name

Sent from my GT-I9205 using xda app-developers app
 
sitifire
Old
#24  
Member - OP
Thanks Meter 40
Posts: 81
Join Date: Apr 2013
Location: Tanjungpandan
Quote:
Originally Posted by shazzl View Post
Can u help me i want the partition info so you can flash with cwmrecovery or twpr...

Open terminal emulator
su
ls -al /dev/block/platform/msm_sdcc.1/by-name

Sent from my GT-I9205 using xda app-developers app
Sorry for my late reply bro...got extra works on my office last 2 days...
I can't used that command on terminal emulator.there's no such file on directory.....but I'd pm you & gave a flashable zip that contain boot.img by @k2wl . flashable zip was made by @Rittik. I hope it can help you and offcourse big thanks for you too bro for helping me...

Sent from my GT-I9152 using Tapatalk
 
shazzl
Old
(Last edited by shazzl; 24th February 2014 at 01:57 AM.)
#25  
shazzl's Avatar
Senior Member
Thanks Meter 82
Posts: 315
Join Date: Jan 2013
Location: Banting
Quote:
Originally Posted by sitifire View Post
Sorry for my late reply bro...got extra works on my office last 2 days...
I can't used that command on terminal emulator.there's no such file on directory.....but I'd pm you & gave a flashable zip that contain boot.img by @k2wl . flashable zip was made by @Rittik. I hope it can help you and offcourse big thanks for you too bro for helping me...

Sent from my GT-I9152 using Tapatalk
remember bacup first
if all working we are on i will open thret
 
sitifire
Old
#26  
Member - OP
Thanks Meter 40
Posts: 81
Join Date: Apr 2013
Location: Tanjungpandan
Quote:
Originally Posted by shazzl View Post
remember bacup first
if all working we are on i will open thret
not lucky yet bro...got bootloop after flashing it on cwm...
 
shazzl
Old
#27  
shazzl's Avatar
Senior Member
Thanks Meter 82
Posts: 315
Join Date: Jan 2013
Location: Banting
Quote:
Originally Posted by sitifire View Post
not lucky yet bro...got bootloop after flashing it on cwm...
ok mayby i shuld change the tool change
The Following User Says Thank You to shazzl For This Useful Post: [ Click to Expand ]
 
sitifire
Old
#28  
Member - OP
Thanks Meter 40
Posts: 81
Join Date: Apr 2013
Location: Tanjungpandan
finally can make a custom rom...
thread : http://forum.xda-developers.com/show....php?t=2678826
thanks...

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes