Attend XDA's Second Annual Developer Conference, XDA:DevCon 2014!
5,742,614 Members 40,767 Now Online
XDA Developers Android and Mobile Development Forum

center clock and how to

Tip us?
 
CiDev
Old
#1  
Member - OP
Thanks Meter 48
Posts: 80
Join Date: Nov 2013
Default center clock and how to

This is for who"s on XXUBMJ6 firmware

download here:
https://www.dropbox.com/s/zke597pq8f...ck_XXUBMJ6.zip



who want's to do this:

Decompile you're SystemUI.apk

go to res/layout-sw800dp-xhdpi/status_bar.XML

open with Notepad++

and overwrite with this code

Code:
Select Code
<?xml version="1.0" encoding="utf-8"?>
<com.android.systemui.statusbar.phone.PhoneStatusBarView android:orientation="vertical" android:id="@id/status_bar" android:background="@drawable/status_bar_background" android:focusable="true" android:fitsSystemWindows="true" android:descendantFocusability="afterDescendants"
  xmlns:android="http://schemas.android.com/apk/res/android"
  xmlns:systemui="http://schemas.android.com/apk/res/com.android.systemui">
    <ImageView android:id="@id/black_bg" android:background="#ff000000" android:visibility="gone" android:layout_width="fill_parent" android:layout_height="fill_parent" />
    <ImageView android:id="@id/notification_lights_out" android:paddingLeft="4.0dip" android:paddingBottom="2.0dip" android:visibility="gone" android:layout_width="@dimen/status_bar_icon_size" android:layout_height="fill_parent" android:src="@drawable/ic_sysbar_lights_out_dot_small" android:scaleType="center" />
    <LinearLayout android:orientation="horizontal" android:id="@id/status_bar_contents" android:paddingLeft="1.0dip" android:paddingRight="1.0dip" android:layout_width="fill_parent" android:layout_height="fill_parent">
        <LinearLayout android:orientation="horizontal" android:id="@id/notification_icon_area" android:layout_width="0.0dip" android:layout_height="fill_parent" android:layout_weight="1.0" android:alpha="@dimen/notification_icon_area_alpha">
            <TextView android:textSize="15.0dip" android:textColor="#ffffffff" android:gravity="center_vertical" android:id="@id/carrierLabel" android:visibility="gone" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
            <ImageView android:id="@id/operatorLogoIcon" android:visibility="gone" android:layout_width="wrap_content" android:layout_height="fill_parent" android:src="@drawable/tw_stat_notify_operator_logo" />
            <ImageView android:id="@id/operatorLogoIcon_org" android:visibility="gone" android:layout_width="wrap_content" android:layout_height="fill_parent" android:src="@drawable/tw_stat_notify_operator_logo_org" />
            <com.android.systemui.statusbar.StatusBarIconView android:id="@id/moreIcon" android:visibility="gone" android:layout_width="@dimen/status_bar_icon_size" android:layout_height="fill_parent" android:src="@drawable/stat_notify_more" />
            <com.android.systemui.statusbar.phone.IconMerger android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/notificationIcons" android:paddingBottom="@dimen/notification_icon_bottom_margin" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_alignParentLeft="true" />
        </LinearLayout>
        <LinearLayout android:gravity="center" android:orientation="horizontal" android:id="@id/clock" android:layout_width="wrap_content" android:layout_height="fill_parent">
            <com.android.systemui.statusbar.policy.Clock android:textSize="@dimen/status_bar_clock_text_size" android:textColor="#ffffffff" android:gravity="center" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" systemui:ampmSmall="true" />
        </LinearLayout>
        <LinearLayout android:gravity="right|center" android:orientation="horizontal" android:id="@id/system_icon_area" android:layout_width="0.0dip" android:layout_height="fill_parent" android:layout_weight="1.0" android:alpha="@dimen/system_icon_area_alpha">
            <LinearLayout android:gravity="right|center" android:orientation="horizontal" android:id="@id/statusIcons" android:layout_width="wrap_content" android:layout_height="fill_parent" />
            <LinearLayout android:gravity="right|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:textSize="@dimen/status_bar_battery_text_size" 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:paddingLeft="2.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" />
            </LinearLayout>
        </LinearLayout>
    </LinearLayout>
    <LinearLayout android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/ticker" android:paddingLeft="4.0dip" android:animationCache="false" android:layout_width="fill_parent" android:layout_height="fill_parent">
        <ImageSwitcher android:id="@id/tickerIcon" android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:layout_marginRight="4.0dip">
            <com.android.systemui.statusbar.AnimatedImageView android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:scaleType="centerInside" />
            <com.android.systemui.statusbar.AnimatedImageView android:layout_width="@dimen/status_bar_icon_size" android:layout_height="@dimen/status_bar_icon_size" android:scaleType="centerInside" />
        </ImageSwitcher>
        <com.android.systemui.statusbar.phone.TickerView android:id="@id/tickerText" android:paddingRight="10.0dip" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_weight="1.0">
            <TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:textColor="#ffffffff" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
            <TextView android:textAppearance="@style/TextAppearance.StatusBar.PhoneTicker" android:textColor="#ffffffff" android:layout_width="fill_parent" android:layout_height="wrap_content" android:singleLine="true" />
        </com.android.systemui.statusbar.phone.TickerView>
    </LinearLayout>
</com.android.systemui.statusbar.phone.PhoneStatusBarView>
Will try to add date also soon
Enjoy...
 
ddavtian
Old
(Last edited by ddavtian; 6th March 2014 at 06:20 PM.)
#2  
Senior Member
Thanks Meter 110
Posts: 456
Join Date: Apr 2007
Location: San Francisco Bay Area
Or use Wanam xposed and select "center":

 
CiDev
Old
#3  
Member - OP
Thanks Meter 48
Posts: 80
Join Date: Nov 2013
Default center clock

Quote:
Originally Posted by ddavtian View Post
Or use Wanam xposed and select "center":

Yes, 4 sure, maby I'm to old school like to do it to save space.
 
ddavtian
Old
#4  
Senior Member
Thanks Meter 110
Posts: 456
Join Date: Apr 2007
Location: San Francisco Bay Area
Your approach is fine for people who know what they are doing.
I'm good with xposed
 
CiDev
Old
#5  
Member - OP
Thanks Meter 48
Posts: 80
Join Date: Nov 2013
Default center clock

Quote:
Originally Posted by ddavtian View Post
Your approach is fine for people who know what they are doing.
I'm good with xposed
I understand, but I'm making a rom for my daughter who's 6 years old,so I avoid dangerous apps for my kid.
now can you tell me maby if there's already a transparent weather widget posted cause I'm working on that one, so don't feel like posting what already is out.
thx
 
moabizzi
Old
#6  
moabizzi's Avatar
Senior Member
Thanks Meter 176
Posts: 596
Join Date: Feb 2008
Location: Marlboro NJ

 
DONATE TO ME
Ur six year old gets a note 10.1 2014, goshhhhh lucckkyyyyyyy.

Sent from my SGH-T889 using XDA Premium 4 mobile app
 
CiDev
Old
#7  
Member - OP
Thanks Meter 48
Posts: 80
Join Date: Nov 2013
Default center clock

Quote:
Originally Posted by moabizzi View Post
Ur six year old gets a note 10.1 2014, goshhhhh lucckkyyyyyyy.

Sent from my SGH-T889 using XDA Premium 4 mobile app
lol, to be true, I ordered the tablet on firm name, no taks so price was ok, and she's all I got so do everything for my little princes. think every father will understand me.
anyway, will do my best to post some mod stuff here, but tablets are so hard to do...

Cheers
 
GeorgeP
Old
#8  
Senior Member
Thanks Meter 85
Posts: 290
Join Date: Sep 2007
Quote:
Originally Posted by CiDev View Post
lol, to be true, I ordered the tablet on firm name, no taks so price was ok, and she's all I got so do everything for my little princes. think every father will understand me.
anyway, will do my best to post some mod stuff here, but tablets are so hard to do...

Cheers
As a father of a 4 year old daughter I can definitely understand! She is my little princess and I want to do everything for her. I do try to hold back so as not to spoil her though, so I gave her an old iPad instead of an N10.1 2014.
 
CiDev
Old
#9  
Member - OP
Thanks Meter 48
Posts: 80
Join Date: Nov 2013
Default Dad

Thx for understanding my friend.
Its hard not to spoil them, but I also gave this cause Its an extra for her general education and development (sorry if my words are wrong)
and she beats almost everyone with SubwaySurfers
 
GeorgeP
Old
#10  
Senior Member
Thanks Meter 85
Posts: 290
Join Date: Sep 2007
Quote:
Originally Posted by CiDev View Post
Thx for understanding my friend.
Its hard not to spoil them, but I also gave this cause Its an extra for her general education and development (sorry if my words are wrong)
and she beats almost everyone with SubwaySurfers
I agree. My daughter has gotten very good at Angry Birds. I figure that is giving her an early introduction to Newtonian physics.
But yes, there are also a lot of good educational apps she likes, so that's good.

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


XDA PORTAL POSTS

Slide Dial Replacement Dialer Lets You Make Calls from Anywhere

If you frequently make phone calls, your dialer (aka phone app)is one of the … more

Navigate with Your Samsung Gear 2 Using DMA Navi Watch

Whether you’re travelling to a new destination or exploring some previously … more

Xperia Z1 Stereo Speaker Mod, Cell Phone Unlocking Legal Again! – XDA Developer TV

Cell Phone Unlocking is legal again!! That and much … more

[OTA Captured] Verizon LG G Pad 8.3 Finally Gets Official KitKat Update

It’s been almost nine months since the LG G Pad … more