[Guide] BASIC Modding SystemUI [Part I]
[Guide] BASIC Modding SystemUI [Part I] - Hallo sobat Jogja Android Blog, Pada Artikel yang sobat baca kali ini dengan judul [Guide] BASIC Modding SystemUI [Part I], kami telah mempersiapkan artikel ini dengan baik untuk sobat baca dan ambil informasi didalamnya. Mudah-mudahan isi postingan [Guide] BASIC Modding SystemUI [Part I] yang kami tulis ini dapat sobat Jogja Android Blog pahami. Baiklah, selamat membaca sambil menikmati kopi.
Intro :
Tentunya smua guide di bawah bkn murni temuan ane.
Hasil dari gugling, xda , dan bantuan dari teman2 user android.
Requirement :
- Brain,patient and logic
- Compile apk tools : apktool,apkmultitool,ticklemyandroid,mitools dsb..
- Knowledge Compile apk and sign
- Notepad ++
------------------------------------------------------------------------------
1. Statusbar
1.1 Transparant statusbar (SystemUI dan android.policy.jar)
http://forum.xda-developers.com/showpost.php?p=40278450&postcount=2
Credit to Adi Aishiteru
1.2 Add background statusbar ( dng ketentuan statusbar sudah transparan )
Tambah image utk background statusbar di drawable-hdpi dng format png
Lalu kasih nama statbar_bg.png -------cuma contoh nama, bs kasih nama apa aja terserah
cara I :
buka gemini_status_bar.xml di res/layout
line 2 android:background="@drawable/status_bar_background" ganti status_bar_background dng nama image ente
sehingga mjd spt ini android:background="@drawable/statbar_bg"
cara II :
buka drawable.xml di res/values
cari line <item type="drawable" name="status_bar_background">#3f000000</item>
ganti #3f000000 dng @drawable/statbar_bg
<item type="drawable" name="status_bar_background">@drawable/statbar_bg</item>
1.3 Center clock/notification/signal
buka gemini_status_bar.xml
cari line
<ImageView android:id="@id/notification_lights_out" android:paddingLeft="6.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" />tambahkan tulisan ini tepat di bawahnya
<LinearLayout android:gravity="center" android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="fill_parent">
<clock/"notif"/"signal">
</LinearLayout>
center Notification
<?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/notification_lights_out" android:paddingLeft="6.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:gravity="center" android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="fill_parent">
<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:layout_width="wrap_content" android:layout_height="fill_parent" />
</LinearLayout>
<LinearLayout android:orientation="horizontal" android:id="@id/status_bar_contents" android:paddingLeft="6.0dip" android:paddingRight="6.0dip" android:layout_width="fill_parent" android:layout_height="fill_parent">
center clock
<?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/notification_lights_out" android:paddingLeft="6.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:gravity="center" android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="fill_parent">
<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:textColor="@*android:color/white" android:gravity="left|center" android:id="@id/clock" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
</LinearLayout>
<LinearLayout android:orientation="horizontal" android:id="@id/status_bar_contents" android:paddingLeft="6.0dip" android:paddingRight="6.0dip" android:layout_width="fill_parent" android:layout_height="fill_parent">
center signal
<?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/notification_lights_out" android:paddingLeft="6.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:gravity="center" android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="fill_parent">
<include android:id="@id/signal_cluster" android:layout_width="wrap_content" android:layout_height="wrap_content" layout="@layout/gemini_signal_cluster_view" />
</LinearLayout>
<LinearLayout android:orientation="horizontal" android:id="@id/status_bar_contents" android:paddingLeft="6.0dip" android:paddingRight="6.0dip" android:layout_width="fill_parent" android:layout_height="fill_parent">
klo masih bingung sama layout2 statusbar, coba perhatikan baik2 di bawah ini
<?xml version="1.0" encoding="utf-8"?>-------------layout tengah------------------
<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/notification_lights_out" android:paddingLeft="6.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:gravity="center" android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="fill_parent">-----------------layout kiri ----------------
<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:layout_width="wrap_content" android:layout_height="fill_parent" />
</LinearLayout>
<LinearLayout android:orientation="horizontal" android:id="@id/status_bar_contents" android:paddingLeft="6.0dip" android:paddingRight="6.0dip" android:layout_width="fill_parent" android:layout_height="fill_parent">
<LinearLayout android:orientation="horizontal" android:id="@id/notification_icon_area" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_weight="1.0">-----------------layout kanan ---------------
<include android:gravity="left|center" android:id="@id/signal_cluster" android:layout_width="wrap_content" android:layout_height="fill_parent" layout="@layout/gemini_signal_cluster_view" />
</LinearLayout>
<LinearLayout android:orientation="horizontal" android:id="@id/system_icon_area" android:layout_width="wrap_content" android:layout_height="fill_parent">--------------------------------------------
<LinearLayout android:gravity="center_vertical" android:orientation="horizontal" android:id="@id/statusIcons" android:layout_width="wrap_content" android:layout_height="fill_parent" />
<LinearLayout android:gravity="center" android:orientation="horizontal" android:id="@id/signal_battery_cluster" android:layout_width="wrap_content" android:layout_height="fill_parent">
<ImageView android:id="@id/laptop_battery" android:visibility="gone" android:layout_width="0.0dip" android:layout_height="0.0dip" />
<TextView android:textSize="12.0sp" android:textColor="@*android:color/white" android:id="@id/percentage" android:visibility="gone" android:layout_width="wrap_content" android:layout_height="wrap_content" />
<ImageView android:id="@id/battery" android:layout_width="0.0dip" android:layout_height="0.0dip" />
</LinearLayout>
<com.android.systemui.statusbar.policy.Clock android:textAppearance="@style/TextAppearance.StatusBar.Clock" android:textColor="@*android:color/white" android:gravity="left|center" android:id="@id/clock" android:layout_width="wrap_content" android:layout_height="fill_parent" android:singleLine="true" />
</LinearLayout>
</LinearLayout>
klo udah khatam ente bs merubah posisi2 sesuka ente.
1.4 Add Carrier logo
tambahakn image png di drawable-hdpi lalu beri nama carrier_logo.png
line carrier logo di gemini_status_bar.xml
<ImageView android:gravity="left|center" android:id="@+id/carrier_logo" android:layout_width="wrap_content" android:layout_height="fill_parent" android:src="@drawable/carrier_logo" android:scaleType="fitCenter" android:adjustViewBounds="true" />
Silahkan taro dmn aja sesuai kemauan ente.
Thankz to :
Martin Ind
Group FB M.a.a.a.D Reborn
Demikian Artikel dengan judul [Guide] BASIC Modding SystemUI [Part I]
Mudah-mudahan bisa memberi manfaat untuk sobat Jogja Android Blog semua. Baiklah, sampai jumpa di postingan artikel lainnya.
Sobat Jogja Android Blog sekarang membaca artikel [Guide] BASIC Modding SystemUI [Part I] dengan alamat link https://jogjandroidz.blogspot.com/2014/11/guide-basic-modding-systemui-part-i.html
0 Response to "[Guide] BASIC Modding SystemUI [Part I]"
Post a Comment