Welcome to XDA

Search to go directly to your device's forum

Register an account

Unlock full posting privileges

Ask a question

No registration required
Post Reply

[MOD][ICS] Z2 style Z1 SystemUI.apk (12/03/14)

OP DBRoger

14th April 2014, 03:43 AM   |  #21  
Aciong.Aksaya's Avatar
Senior Member
Flag Mandaluyong
Thanks Meter: 165
 
454 posts
Join Date:Joined: Aug 2012
More
How did you manage to put the clock inside the battery icon?
28th May 2014, 06:46 PM   |  #22  
DBRoger's Avatar
OP Member
Flag Taipei
Thanks Meter: 58
 
82 posts
Join Date:Joined: Mar 2013
Quote:
Originally Posted by Aciong.Aksaya

How did you manage to put the clock inside the battery icon?

Sorry for late reply. I wasn't putting clock text inside the battery icon. If you are asking how to put battery text inside battery icon, this is solution:
I use "FrameLayout" to make battery icon under battery text. Don't ask me why use this or how to use this. I am not expert. I just google android layout and find this solution.

Part of original SystemUI layout from DdcCabuslay. (res\layout\status_bar.xml)
Code:
<LinearLayout android:gravity="center" android:orientation="horizontal" android:id="@id/signal_battery_cluster" android:paddingLeft="2.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent">
            <include android:id="@id/signal_cluster" android:layout_width="wrap_content" android:layout_height="wrap_content" layout="@layout/signal_cluster_view" />
            <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" />
            <ImageView android:id="@id/battery" android:paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" />
        </LinearLayout>
After modification.
Code:
<LinearLayout android:gravity="center" android:orientation="horizontal" android:id="@id/signal_battery_cluster" android:paddingLeft="2.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent">
            <include android:id="@id/signal_cluster" android:layout_width="wrap_content" android:layout_height="wrap_content" layout="@layout/signal_cluster_view" />
            <FrameLayout android:layout_gravity="right|center" android:paddingLeft="4.0dip" android:layout_width="wrap_content" android:layout_height="fill_parent">
                <ImageView android:layout_gravity="right|center" android:id="@id/battery" android:layout_width="wrap_content" android:layout_height="wrap_content" />
                <TextView android:textSize="9.0dip" android:textStyle="bold" android:layout_gravity="right|center" android:id="@id/battery_text" android:paddingRight="12.5dip" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/status_bar_settings_settings_button" android:singleLine="true" style="@style/StatusBarNotificationText" />
            </FrameLayout>
        </LinearLayout>
Post Reply Subscribe to Thread
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes