From 44c1473c03a0021224fa94af9b1e3579ec244b12 Mon Sep 17 00:00:00 2001 From: Gilles Debunne Date: Tue, 19 Oct 2010 11:56:59 -0700 Subject: [PATCH] New Holo style for Tabs. Holo theme with new assets and style for TabWidgets. Legacy Themes still use GB style. Assets added in a previous bluk update were removed. Change-Id: Ia4a612678561fa5047bbd2a72488086c0f3d61a1 --- core/java/android/widget/TabHost.java | 29 +++++++++-- core/java/android/widget/TabWidget.java | 14 ++---- core/java/android/widget/TextView.java | 1 + .../tab_arrow_left_holo_dark.png | Bin 597 -> 0 bytes .../tab_arrow_left_holo_light.png | Bin 728 -> 0 bytes .../tab_arrow_right_holo_dark.png | Bin 581 -> 0 bytes .../tab_arrow_right_holo_light.png | Bin 707 -> 0 bytes .../res/drawable-hdpi/tab_bottom_holo.9.png | Bin 0 -> 159 bytes .../drawable-hdpi/tab_divider_holo_dark.png | Bin 296 -> 0 bytes .../drawable-hdpi/tab_divider_holo_light.png | Bin 306 -> 0 bytes .../tab_selected_focused_holo.9.png | Bin 0 -> 218 bytes .../res/drawable-hdpi/tab_selected_holo.9.png | Bin 0 -> 159 bytes .../tab_selected_pressed_focused_holo.9.png | Bin 0 -> 522 bytes .../tab_selected_pressed_holo.9.png | Bin 0 -> 271 bytes .../tab_selector_holo_dark.9.png | Bin 234 -> 0 bytes .../res/drawable-hdpi/tab_strip_holo.9.png | Bin 140 -> 0 bytes .../tab_unselected_focused_holo.9.png | Bin 0 -> 216 bytes .../drawable-hdpi/tab_unselected_holo.9.png | Bin 0 -> 147 bytes .../tab_unselected_pressed_focused_holo.9.png | Bin 0 -> 536 bytes .../tab_unselected_pressed_holo.9.png | Bin 0 -> 265 bytes .../tab_arrow_left_holo_dark.png | Bin 463 -> 0 bytes .../tab_arrow_left_holo_light.png | Bin 554 -> 0 bytes .../tab_arrow_right_holo_dark.png | Bin 465 -> 0 bytes .../tab_arrow_right_holo_light.png | Bin 554 -> 0 bytes .../res/drawable-mdpi/tab_bottom_holo.9.png | Bin 0 -> 145 bytes .../drawable-mdpi/tab_divider_holo_dark.png | Bin 289 -> 0 bytes .../drawable-mdpi/tab_divider_holo_light.png | Bin 300 -> 0 bytes .../res/drawable-mdpi/tab_focused_holo.9.png | Bin 0 -> 634 bytes .../res/drawable-mdpi/tab_pressed_holo.9.png | Bin 0 -> 328 bytes .../tab_selected_focused_holo.9.png | Bin 0 -> 203 bytes .../res/drawable-mdpi/tab_selected_holo.9.png | Bin 0 -> 144 bytes .../tab_selected_pressed_focused_holo.9.png | Bin 0 -> 454 bytes .../tab_selected_pressed_holo.9.png | Bin 0 -> 231 bytes .../tab_selector_holo_dark.9.png | Bin 210 -> 0 bytes .../tab_unselected_focused_holo.9.png | Bin 0 -> 196 bytes .../drawable-mdpi/tab_unselected_holo.9.png | Bin 0 -> 128 bytes .../tab_unselected_pressed_focused_holo.9.png | Bin 0 -> 459 bytes .../tab_unselected_pressed_holo.9.png | Bin 0 -> 223 bytes core/res/res/drawable/tab_bottom_right.xml | 4 +- core/res/res/drawable/tab_indicator_holo.xml | 34 +++++++++++++ core/res/res/layout/tab_indicator.xml | 1 - core/res/res/layout/tab_indicator_holo.xml | 46 ++++++++++++++++++ core/res/res/values/attrs.xml | 2 + core/res/res/values/styles.xml | 17 ++++++- 44 files changed, 127 insertions(+), 21 deletions(-) delete mode 100644 core/res/res/drawable-hdpi/tab_arrow_left_holo_dark.png delete mode 100644 core/res/res/drawable-hdpi/tab_arrow_left_holo_light.png delete mode 100644 core/res/res/drawable-hdpi/tab_arrow_right_holo_dark.png delete mode 100644 core/res/res/drawable-hdpi/tab_arrow_right_holo_light.png create mode 100644 core/res/res/drawable-hdpi/tab_bottom_holo.9.png delete mode 100644 core/res/res/drawable-hdpi/tab_divider_holo_dark.png delete mode 100644 core/res/res/drawable-hdpi/tab_divider_holo_light.png create mode 100644 core/res/res/drawable-hdpi/tab_selected_focused_holo.9.png create mode 100644 core/res/res/drawable-hdpi/tab_selected_holo.9.png create mode 100644 core/res/res/drawable-hdpi/tab_selected_pressed_focused_holo.9.png create mode 100644 core/res/res/drawable-hdpi/tab_selected_pressed_holo.9.png delete mode 100644 core/res/res/drawable-hdpi/tab_selector_holo_dark.9.png delete mode 100644 core/res/res/drawable-hdpi/tab_strip_holo.9.png create mode 100644 core/res/res/drawable-hdpi/tab_unselected_focused_holo.9.png create mode 100644 core/res/res/drawable-hdpi/tab_unselected_holo.9.png create mode 100644 core/res/res/drawable-hdpi/tab_unselected_pressed_focused_holo.9.png create mode 100644 core/res/res/drawable-hdpi/tab_unselected_pressed_holo.9.png delete mode 100644 core/res/res/drawable-mdpi/tab_arrow_left_holo_dark.png delete mode 100644 core/res/res/drawable-mdpi/tab_arrow_left_holo_light.png delete mode 100644 core/res/res/drawable-mdpi/tab_arrow_right_holo_dark.png delete mode 100644 core/res/res/drawable-mdpi/tab_arrow_right_holo_light.png create mode 100644 core/res/res/drawable-mdpi/tab_bottom_holo.9.png delete mode 100644 core/res/res/drawable-mdpi/tab_divider_holo_dark.png delete mode 100644 core/res/res/drawable-mdpi/tab_divider_holo_light.png create mode 100644 core/res/res/drawable-mdpi/tab_focused_holo.9.png create mode 100644 core/res/res/drawable-mdpi/tab_pressed_holo.9.png create mode 100644 core/res/res/drawable-mdpi/tab_selected_focused_holo.9.png create mode 100644 core/res/res/drawable-mdpi/tab_selected_holo.9.png create mode 100644 core/res/res/drawable-mdpi/tab_selected_pressed_focused_holo.9.png create mode 100644 core/res/res/drawable-mdpi/tab_selected_pressed_holo.9.png delete mode 100644 core/res/res/drawable-mdpi/tab_selector_holo_dark.9.png create mode 100644 core/res/res/drawable-mdpi/tab_unselected_focused_holo.9.png create mode 100644 core/res/res/drawable-mdpi/tab_unselected_holo.9.png create mode 100644 core/res/res/drawable-mdpi/tab_unselected_pressed_focused_holo.9.png create mode 100644 core/res/res/drawable-mdpi/tab_unselected_pressed_holo.9.png create mode 100644 core/res/res/drawable/tab_indicator_holo.xml create mode 100644 core/res/res/layout/tab_indicator_holo.xml diff --git a/core/java/android/widget/TabHost.java b/core/java/android/widget/TabHost.java index ff31dec2ff0cd..2949208b3ef16 100644 --- a/core/java/android/widget/TabHost.java +++ b/core/java/android/widget/TabHost.java @@ -21,6 +21,7 @@ import com.android.internal.R; import android.app.LocalActivityManager; import android.content.Context; import android.content.Intent; +import android.content.res.TypedArray; import android.graphics.drawable.Drawable; import android.os.Build; import android.util.AttributeSet; @@ -63,6 +64,8 @@ public class TabHost extends FrameLayout implements ViewTreeObserver.OnTouchMode private OnTabChangeListener mOnTabChangeListener; private OnKeyListener mTabKeyListener; + private int mTabLayoutId; + public TabHost(Context context) { super(context); initTabHost(); @@ -70,6 +73,18 @@ public class TabHost extends FrameLayout implements ViewTreeObserver.OnTouchMode public TabHost(Context context, AttributeSet attrs) { super(context, attrs); + + TypedArray a = context.obtainStyledAttributes(attrs, + com.android.internal.R.styleable.TabWidget, + com.android.internal.R.attr.tabWidgetStyle, 0); + + mTabLayoutId = a.getResourceId(R.styleable.TabWidget_tabLayout, 0); + if (mTabLayoutId == 0) { + throw new IllegalArgumentException("Invalid TabWidget tabLayout id"); + } + + a.recycle(); + initTabHost(); } @@ -214,6 +229,7 @@ mTabHost.addTab(TAB_TAG_1, "Hello, world!", "Tab 1"); if (tabSpec.mIndicatorStrategy instanceof ViewIndicatorStrategy) { mTabWidget.setStripEnabled(false); } + mTabWidget.addView(tabIndicator); mTabSpecs.add(tabSpec); @@ -513,7 +529,7 @@ mTabHost.addTab(TAB_TAG_1, "Hello, world!", "Tab 1"); final Context context = getContext(); LayoutInflater inflater = (LayoutInflater) context.getSystemService(Context.LAYOUT_INFLATER_SERVICE); - View tabIndicator = inflater.inflate(R.layout.tab_indicator, + View tabIndicator = inflater.inflate(mTabLayoutId, mTabWidget, // tab widget is the parent false); // no inflate params @@ -525,7 +541,7 @@ mTabHost.addTab(TAB_TAG_1, "Hello, world!", "Tab 1"); tabIndicator.setBackgroundResource(R.drawable.tab_indicator_v4); tv.setTextColor(context.getResources().getColorStateList(R.color.tab_indicator_text_v4)); } - + return tabIndicator; } } @@ -547,7 +563,7 @@ mTabHost.addTab(TAB_TAG_1, "Hello, world!", "Tab 1"); final Context context = getContext(); LayoutInflater inflater = (LayoutInflater) context.getSystemService(Context.LAYOUT_INFLATER_SERVICE); - View tabIndicator = inflater.inflate(R.layout.tab_indicator, + View tabIndicator = inflater.inflate(mTabLayoutId, mTabWidget, // tab widget is the parent false); // no inflate params @@ -555,14 +571,17 @@ mTabHost.addTab(TAB_TAG_1, "Hello, world!", "Tab 1"); tv.setText(mLabel); final ImageView iconView = (ImageView) tabIndicator.findViewById(R.id.icon); - iconView.setImageDrawable(mIcon); + if (mIcon != null) { + iconView.setImageDrawable(mIcon); + iconView.setVisibility(VISIBLE); + } if (context.getApplicationInfo().targetSdkVersion <= Build.VERSION_CODES.DONUT) { // Donut apps get old color scheme tabIndicator.setBackgroundResource(R.drawable.tab_indicator_v4); tv.setTextColor(context.getResources().getColorStateList(R.color.tab_indicator_text_v4)); } - + return tabIndicator; } } diff --git a/core/java/android/widget/TabWidget.java b/core/java/android/widget/TabWidget.java index 0469e7bf72276..36adacdf26209 100644 --- a/core/java/android/widget/TabWidget.java +++ b/core/java/android/widget/TabWidget.java @@ -120,7 +120,9 @@ public class TabWidget extends LinearLayout implements OnFocusChangeListener { final Context context = mContext; final Resources resources = context.getResources(); - + + // Tests the target Sdk version, as set in the Manifest. Could not be set using styles.xml + // in a values-v? directory which targets the current platform Sdk version instead. if (context.getApplicationInfo().targetSdkVersion <= Build.VERSION_CODES.DONUT) { // Donut apps get old color scheme if (mLeftStrip == null) { @@ -131,16 +133,6 @@ public class TabWidget extends LinearLayout implements OnFocusChangeListener { mRightStrip = resources.getDrawable( com.android.internal.R.drawable.tab_bottom_right_v4); } - } else { - // Use modern color scheme for Eclair and beyond - if (mLeftStrip == null) { - mLeftStrip = resources.getDrawable( - com.android.internal.R.drawable.tab_bottom_left); - } - if (mRightStrip == null) { - mRightStrip = resources.getDrawable( - com.android.internal.R.drawable.tab_bottom_right); - } } // Deal with focus, as we don't want the focus to go by default diff --git a/core/java/android/widget/TextView.java b/core/java/android/widget/TextView.java index 09563fc564fed..6897537a5a6d3 100644 --- a/core/java/android/widget/TextView.java +++ b/core/java/android/widget/TextView.java @@ -7142,6 +7142,7 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener case Gravity.RIGHT: return 0.0f; case Gravity.CENTER_HORIZONTAL: + case Gravity.FILL_HORIZONTAL: return (mLayout.getLineWidth(0) - ((mRight - mLeft) - getCompoundPaddingLeft() - getCompoundPaddingRight())) / getHorizontalFadingEdgeLength(); diff --git a/core/res/res/drawable-hdpi/tab_arrow_left_holo_dark.png b/core/res/res/drawable-hdpi/tab_arrow_left_holo_dark.png deleted file mode 100644 index cfd6f785c88033495c635dc2e689eb08d3e85042..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 597 zcmeAS@N?(olHy`uVBq!ia0vp^f|xA&jf59DzcctjQh zX%8@VJDF_<5-cllOb60ny$sg+hFJ^@jIo|Bjv*T7doOSFza1cQ^x^wkikzjhcnvQb zg?O~`9{F$YaAl$F1gi}fRyrklCAA(=S?`?lSYXvR-)&z%*M6T`STlp-Cp(eb!ha@{h!&lwP#|xA&jf59DzcctjQh zX%8@VJDF_<5-cllOb60ny$sg+hFJ^@j1N3r978nD_fEd=JvmY2xc&3H%e13z3$f_C ziSxQO`|`{d?omoRmB-ZCbLsYrRndFD-{;t6xNs($qj+)UPSaqYIcpc0pOUW>U7u-` z_Hv%yw({!u*eg4&&OiKIV|o9%CHp_gOKVmru`tGR`3gRLASRyOo?6Lxi?j2f6~pw9 zCoGG8?cn+F@9lFYhJ(o+U6U9h^xMR}pJttGTVXbd!TR>zogoUBcpLH@r?d;+3AiVF z&gKK3sz5^QwO1WQMqToJ{A!oh8kxN)U}U?@aBkKKhPMl}R{m7C51+JFZo!cyZ>|eo zK7QzRb+mMNtt`WtuE4!(O>1g&zwL|eV{>9iaWUV0r6HT)*!GCLXEovc43#I%=472Z zZ}}s3*WXtQ-#`1hivQBJ>z4wqE^)03&HAY+W9Cx#K{jUj@?Y|AZD)szE|@D_CR)My z;B~}~qV!@-eg~hgHwAt=u_*{d^&Gio*2SO_a%ELh%1P#u)ijHhrzu!(O}`4PXg@$>1!95-)^wv`ue9=14T_ckaLjx;A zGb;l#T?2C~1B1KY_SvFn$jwj5OsmALVa;l`MxX{skPX54X(i=}MX3yqDfvmM3ZA)% b>8U}fi7AzZCsS>JiWody{an^LB{Ts50X8G` diff --git a/core/res/res/drawable-hdpi/tab_arrow_right_holo_dark.png b/core/res/res/drawable-hdpi/tab_arrow_right_holo_dark.png deleted file mode 100644 index b226038795616e713a9568f2732dae80fd1db33e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 581 zcmeAS@N?(olHy`uVBq!ia0vp^f|xA&jf59DzcctjQh zX%8@VJDF_<5-cllOb60ny$sg+hFJ^@jJ}>Ojv*T7doSDiOFN3RK1{!Mf6Zeq7cUXj ziAsW!o$Pd#~BO*@wEUGgx6d289k*7O$Z z;P9dpw~3|`MAX6}b{*Wx7v(llYVVR$F0F^cou>=k>MOhDtIhi3>AjWbeRJR5I&5TQ zdCcwJYzgIlt*Ox$FP-7BG1($(THCn1cUyFD_^%AtZQU&vJ%!>YODDug?J_;C70Ro^ zcJ1Yy>eu(qpS^rL`ceL|bh{skJY6BzJhqq}*vQ>4cR=Utt2ia&Ns8Z(UYUDf^YXVI zs>-@0F^`W4X-^i3c8z`8*2gr}a~0q6catwixlauH|0(rdbg;X!#G>cEk5i^~F_#Bt z#=ZBhKCpV%X8 cO-xS>N=;0uEIgTN160J|>FVdQ&MBb@09LT!QUCw| diff --git a/core/res/res/drawable-hdpi/tab_arrow_right_holo_light.png b/core/res/res/drawable-hdpi/tab_arrow_right_holo_light.png deleted file mode 100644 index 0e5fbe671c01fbd2a1e993fb905d19b15590ffbb..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 707 zcmeAS@N?(olHy`uVBq!ia0vp^f|xA&jf59DzcctjQh zX%8@VJDF_<5-cllOb60ny$sg+hFJ^@jHf+a978nD_fEd=JvmXNVgBcxF0E^Kavw~H zJ)xK8m;dRwL+gS2Rm-Os+?e~r{RjJ%{Q_6+Dg<1(t$AC)Q{Z?wyooIJR}YU?so6&fQWy@21!>8Z2fsPYPz(D0XaG z&Bia4k{PP&;+Q9T3(au~{(Q>B=FXm747WO0FQ3P{a>4_isG9R?^QK)lj$*Z%VIVL; z$&;Zzy)4DBena-INI!mlPezu*zxOs()((ToHEFOUjDRnhJ({%nm zmKF%uFTL{9-B2Y4IdLOTfeXE79_xR5(`&XsLzVer;vxq2-TZ!beZTS|XOSwF1#Zy>{_O>eI(jeE4^P^IOxs86~*ovb2RwX1rk zv|GF_DE*ir9JXxstj1uWqDb>y&g>bbwx5^eoZt4N!B{BBaOrM_B7O1CeeOYB?9Y12bI%b1MUbyWjTNqG-s?PsvQH z#I0e?YPLq821$?&!TD(=<%vb942~)JNvR5+xryniL8*x;m4zo$LC#?CboFyt=akR{ E0Eb!@+W-In diff --git a/core/res/res/drawable-hdpi/tab_bottom_holo.9.png b/core/res/res/drawable-hdpi/tab_bottom_holo.9.png new file mode 100644 index 0000000000000000000000000000000000000000..ec9fa8d8054e02c10819ddb968a7cb3fbadb8db6 GIT binary patch literal 159 zcmeAS@N?(olHy`uVBq!ia0vp^fDSr z1<%~X^wgl##FWaylc_d9MUI{>jv*Ddl04`Bn#?FaWA531@+;Z|=Szuc{FR^1v_kd& z#~BAXHa)agye?3n$*e4BCdky|W5A}zvx#%QjfarJ0fvXu1pnXWc(w{?7=x#)pUXO@ GgeCx!6)~*< literal 0 HcmV?d00001 diff --git a/core/res/res/drawable-hdpi/tab_divider_holo_dark.png b/core/res/res/drawable-hdpi/tab_divider_holo_dark.png deleted file mode 100644 index 112cb04b829e9ab4762e529c81102cb1e0b2761e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 296 zcmeAS@N?(olHy`uVBq!ia0vp^96)Tq!2%@P^gkZ}QcOwS?k)`f+xyS#2l6-zJR*yM zvQ&rUPlPUIw+}oYR3E15X#n5RLP1Pi^F7P~c%c$epyI=Um!CZ%5De zmeto!2675DDz9RIp_7q{8DKP=1VxhPry^{SS*MwFx^mZVxG7o`Fz1|tJQ z16>14T_ckaLjx;AGb;l#T?2C~1B1KY_SvFn$jwj5OsmALVa;l`MxX{skPX54X(i=} nMX3yqDfvmM3ZA)%>8U}fi7AzZCsS>JiWody{an^LB{Ts5%>h#s diff --git a/core/res/res/drawable-hdpi/tab_divider_holo_light.png b/core/res/res/drawable-hdpi/tab_divider_holo_light.png deleted file mode 100644 index 1bf4d386881a50967fb3c5c3f3ae65ec751cff91..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 306 zcmeAS@N?(olHy`uVBq!ia0vp^96)Tq!2%@P^gkZ}QcOwS?k)`f+xyS#2l6-zJR*yM zvQ&rUPlPUIw+}oYR3ED^C~45RLQ6f9@Xu0gLX&hxJm-Kp@O4B_Rrg zElfH*Jq2dU8=3w;WcshjRR55vzHo(uFayJBckbsBMQ8s2O;IgzjVMV;EJ?LWE=mPb z3`Pcq2D%28x<)1;h6YxKW>yAfx(4P}1_pP(?XyMEkei>9nO2Eg!jX({OARB`7 r(@M${i&7aJQ}UBi6+Ckj(^G>|6H_V+Po~-c6)||a`njxgN@xNAc9>Na diff --git a/core/res/res/drawable-hdpi/tab_selected_focused_holo.9.png b/core/res/res/drawable-hdpi/tab_selected_focused_holo.9.png new file mode 100644 index 0000000000000000000000000000000000000000..1ba35d554811207106066427813fcb04219ceca0 GIT binary patch literal 218 zcmeAS@N?(olHy`uVBq!ia0vp^Ahs6=8<1?uI(iXEu@pObhHwBu4M$1`kk47*5n0T@ zz}*SLjOHg#uLTO$c)B=-cyzwKX3N!Jz|;27Jm`Z{+)9fIj;{i;N3<&!`V|J|{B5-A z;!Me$|7>w|K&ao+XnFQk7J`XUo4O4v85%kQ<{q~VH7tofBIkbFfWgQ6*{|@6L0sMH zQYIM}7C1Ju@&04vYT*C4$z_>o`B!zj&#WE%f_zopr0H#GqV*mgE literal 0 HcmV?d00001 diff --git a/core/res/res/drawable-hdpi/tab_selected_holo.9.png b/core/res/res/drawable-hdpi/tab_selected_holo.9.png new file mode 100644 index 0000000000000000000000000000000000000000..ef913cc8e5934d06c04d90547972f2c5ef4179ba GIT binary patch literal 159 zcmeAS@N?(olHy`uVBq!ia0vp^EI=&4!3HD^x83^;5-4`^4B-HR8jh3>AfL0qBeIx* zfx8og8O=|gUJDd-^mK6yk(iqNU! w14Yi9OG`fx&=|@MQYSb^i_N2f@$PSi2|ERZALZLD1scZS>FVdQ&MBb@0Gc5ykpKVy literal 0 HcmV?d00001 diff --git a/core/res/res/drawable-hdpi/tab_selected_pressed_focused_holo.9.png b/core/res/res/drawable-hdpi/tab_selected_pressed_focused_holo.9.png new file mode 100644 index 0000000000000000000000000000000000000000..d7e968806aed3d191fae9f7b4adacd19697ec317 GIT binary patch literal 522 zcmV+l0`>igP)Y1NsF{aOK#K&;wFc$Z$xU^={HaR;mz@qPDK%u{~pFAqmB${!Ru73zB$v zOMmS5*G~YjT)qxAl30}CAaY~_U{l7aYXLy}_nWO7cDv^-0IXKG!R_Vl*AWc>0YD&y zlwbVr(3w%fr1LE3KXMGr42d)SPC~dCH0k=0Lkpd3GDn5xDltV>3XMdo%uz7^ogn>V@560bfA5((B0S2iz-E2Wt04z_4dP<YpSBT8lrJKTrMg2EfG8n8-eoq$FOo$>0! zRWLIb+6;Zq1UiaIR#Yw8kfWw^tdJRsVhZ)d1(3A|qKRy0Lsz|LbmFrjV#Cj4Yi$bv zjp+jb%#KH6`{j-Vfc54uIz-0n@&4*x9FYElBi5S(kPhjS_j+@{H`$fQ!T=IjPXGV_ M07*qoM6N<$g0^_tDgXcg literal 0 HcmV?d00001 diff --git a/core/res/res/drawable-hdpi/tab_selected_pressed_holo.9.png b/core/res/res/drawable-hdpi/tab_selected_pressed_holo.9.png new file mode 100644 index 0000000000000000000000000000000000000000..b8b1fcfe26558d8465c82a517b81f59ed9e15673 GIT binary patch literal 271 zcmeAS@N?(olHy`uVBq!ia0vp^EI{nV!3HGfEdH7V5-4`^4B-HR8jh3>AfL0qBeIx* zfx8og8O=|gUJDf5=;`7ZV$r*IiZ$P11p$})OhKon?2O=>a4a`(g11Z2`(U?4Czl=Y zs7cveCa5y&>b{wg4hvQ>?8m-wJO{FI~6V#8L--CZMAo{j@=)i P;~6|%{an^LB{Ts5hF@xd literal 0 HcmV?d00001 diff --git a/core/res/res/drawable-hdpi/tab_selector_holo_dark.9.png b/core/res/res/drawable-hdpi/tab_selector_holo_dark.9.png deleted file mode 100644 index f01b9bc3f92e24d3c53ad1ac479b70be92838c47..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 234 zcmeAS@N?(olHy`uVBq!ia0vp^CP2)`!3HD~X4)$NDVAa<&kznEsNqQI0P;BtJR*x3 z7`Qt@n9=;?>9s(?9#0p?5RcBcQysYuD~PbV3u{d(J+D1)JG%z!!_@ZUV}C5ax)mBHA6VXDmL7hw2w7rug&s@ z3D>hP>m2*BO6a+QV$1VgGK^bS+=zeY6n?yDV`NZQYmS(y|MXL(uH~&gDm^FX1!m88 b5vyaH+9l@vWoDxh&|M6ku6{1-oD!MbEX7WqAsj$Z!;#Vf4nJ zaCd?*qxs3xYk`7#o-U3d95YLM4Y>{&2sD^{dHlV|TGYuSR&+^{azmGUYFgRsSHD&@ gi#>2XasM%^e1mZFjgNl{fjSvHUHx3vIVCg!0L=<1NB{r; diff --git a/core/res/res/drawable-hdpi/tab_unselected_focused_holo.9.png b/core/res/res/drawable-hdpi/tab_unselected_focused_holo.9.png new file mode 100644 index 0000000000000000000000000000000000000000..256e8e7302e490535b52dfe719dae0c40c4434ce GIT binary patch literal 216 zcmeAS@N?(olHy`uVBq!ia0vp^Ahs6=8<1?uI(iXEu@pObhHwBu4M$1`kk47*5n0T@ zz}*SLjOHg#uLTNLdAc};cyzwKX3N*)Akp%$oTpR#k=L<9&I{TXD8zMgNA~i%)Hy|P zNgKs)I{R+({VmP8VvisG(aX{DEcyH9q3KVC1{J;2rP0AWs}+-a9>;xVdGTvzHlOQi z5wUz87_iY6Ik5KcnpK}m?)AU6KeZuu$=z?O^q=n)|J67l-~`YW44$rjF6*2UngCq( BO<@24 literal 0 HcmV?d00001 diff --git a/core/res/res/drawable-hdpi/tab_unselected_holo.9.png b/core/res/res/drawable-hdpi/tab_unselected_holo.9.png new file mode 100644 index 0000000000000000000000000000000000000000..eaa306aee14b3074962b9eb69f7d66f40b3bbc7b GIT binary patch literal 147 zcmeAS@N?(olHy`uVBq!ia0vp^EI`c8!3HGtQ{P+w2^2edhHwBu4M$1`kk47*5n0T@ zz}*SLjOHg#uLTO4db&7DJBbQD0#AUB zH}C^0-a~%p}r-FEkk`qbJ!z4GNE43s#KK zNDRs@3KsWHgcd0#zy)_t5P&p3Jj$#!qre@_`~aORytx@CS|N~E-DYX7!3q)ywwf#R zi~LF{d_BSz^f=YGK|9ZM0fn=bk}vu+>y{m!nweA@)C183mI|l2t~*ywL~IbQ%zQ@4 zjBbYqbD2|k7rF+l5n4N-Q9@^P4dyB)b11YKCe8!~6qBszTC`ZB>NPgV3`H}Adi(;& z=z(Y=hl8P;erL4fy&+@A?PjoH0D#W)0RU#3jdA!27YP8@x1Y1W&i>rr94*ncBrxA_ awZm^n)5h{@F-;->0000AfL0qBeIx* zfx8og8O=|gUJDdl?djqeV$r*HiZ>UNAy3=>Ev(b^_D(ndz;y3`cLig<=9yzVUhr(= zy=>Op8o=>W-qR~Elp(fRMX9Pys*<=;4p% z$vbwLGM|#MO=eHa>XFT;pUnH0>(<^9#og7CE2b>DEIj#wikm>Z{_L+2#b+FPHd-`X zSTSYOWC67{ot1t(p#@(z{r1}$FW9_q^^vE4D$lIGP?r|boFyt I=akR{08mR~WB>pF literal 0 HcmV?d00001 diff --git a/core/res/res/drawable-mdpi/tab_arrow_left_holo_dark.png b/core/res/res/drawable-mdpi/tab_arrow_left_holo_dark.png deleted file mode 100644 index 4f8bafe08ce04db552979bd67017a0f20faa0c48..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 463 zcmeAS@N?(olHy`uVBq!ia0vp^+(0bM!2%@TDA-2>DW)WEcNd2L?fqx=19_YU9+AaB z+5?Q;PG;MI1j`B>(}6TtFN54Ko(Lf4x~Gd{h{Wa4i-vwoi2@D}^XtUIjW71btv0>)zjJvyq+$?WA_E`I6S!tu% z>bbhx?3SpfFLQc)LB&k$+PgDXsv>tKN^fnPy7v1j;j)DZ+4lDW)WEcNd2L?fqx=19_YU9+AaB z+5?Q;PG;MI1j`B>(}6TtFN54Ko(Kj8Mk7xb#}J9jp%?diJ0*%7`}qF%vPx5C*59oP zQ=0{@O?omxKyc#bj4N^8XTO?Td|~Hc&27A6>ohB9(t?#2^He$7T0&Z?&UWWFt5qH2 z=bv-9I3eZAl1U6n9e3V5KJFr}U!<|CdH-c6<&{qwLZ>`+vt3#4GsovkBVpv9NYZ{Qkp&yHZ?vmrQzNczK2Vy`@P9)>bf2 zV2OOO#jj}QjLV0ccf5Z)$;Wx;mM3#!Sw8(Q_slYo*V?*@ZG&Y(;)k5;mp(pD`aC&Q z^tXTWx!tF$_f6DYa3koTU3dJZEj5i3zP}VaxNg?#rGoJ>iLTf6dR8?yyUceC*&!$G zf4skI+Q}(J{Nl3{j%MAKF|m}^`_|TV){!~3#C?8qktX8@cKPFJOourf5WGBDFMFt;)=xchCNEsBQR{FKbJO57UO ztY&KjYLEok5S*V@Ql40p%HWuipOmWLnVXoN8kCxtQdxL1)dr}D!PC{xWt~$(69DEl B*0KNq diff --git a/core/res/res/drawable-mdpi/tab_arrow_right_holo_dark.png b/core/res/res/drawable-mdpi/tab_arrow_right_holo_dark.png deleted file mode 100644 index 0a8006de9829c0d14d185895210ee5b410cbe6c1..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 465 zcmeAS@N?(olHy`uVBq!ia0vp^+(0bM!2%@TDA-2>DW)WEcNd2L?fqx=19_YU9+AaB z+5?Q;PG;MI1j`B>(}6TtFN54Ko(Lf4rl*Tzh{WaGi@Uv;6GdDfzW;MFrNiiQ1m`Sv zfxwMhzF*xM%<+g>rSB$XRo?_wGuW)UUJC)O>woxN^UhS%g{b$(qCEd(2FCn%##tVXN2sTHpWi zDL3tn-&&&^`#*NB%vb*Mt)jztE9W)qInK_#+5OL^iLq`f>XG)h(vHe#ID&MDr&n`n}3>J@=jqtzm~?<$}`_WFW!uZ_-Qfc(franhRv7Ud*?-Q z{RMhbwZt`|BqgyV)hf9t6-Y4{85kPq8d&NYnS>Y`SQ(mG8JOuBm|Gbb-2JxC7DYpD zeoAIqC2kFCR?gDW)WEcNd2L?fqx=19_YU9+AaB z+5?Q;PG;MI1j`B>(}6TtFN54Ko(Kj8Mk7xb#}J9jxfAz$I|WL#%`e{ZaPQp(96c?I zOuEFDAMiM%+H^oyM|!r@ox}fKG^BbDW$CpmIAv`-sd>6?Lc$V{z_RrvA5Aj4E|}ZZ z?6KLS&)}sod7kisJuZftg$l3gBeYIhExVl1Gxgo}CGv+iUcdBJs?PNO!AIR)%hbh% zB$prDB=tV6`o@u|=WC-5y5@Xy5mo6h%A8Wa?n7XuoBFC41xA;N#V$HqN+Z`Bo@$%4 zY3@|jbRN~_&NKb3;`85F#5Sa7U8~SyP>z*pEBbhC)*QxrTf~ADnXXm;(Gq=WT=B$_ zNkiUyMM;@?4&Ucf3p2a|8U}fi7AzZCsS>Jii|y7978H@CHc(#HJMR*#@w_25!2%=;*sERxDW)WEcNd2L?fqx=19_YU9+AaB z+5?Q;PG;MI1j`B>(}6TtFT;h|91=i|rl*Tzh{WZ$#}*1QDDbdsn3BAq?_65H^8$&6 z6(Lf&hBEv6=W<=S+OUDqgMp>}+4tHapeEH4*NBpo#FA925!2%=;*sERxDW)WEcNd2L?fqx=19_YU9+AaB z+5?Q;PG;MI1j`B>(}6TtFT;h|91=i|iKmNWh{WZ$Ck}ElDDp5I>|7G|dPCpq&`0hp z8(VK*-w@dRW7Xw3b#^|CO?UQBPx#24YJ`L;(K){{a7>y{D4^000SaNLh0L01FcU01FcV0GgZ_00007bV*G`2igh~ z7bZI#(W=Y<00H_*L_t(I%f-~YZ&XJZ1@Pa@y?Yn4V8LP;nFb*q4TXiANJtb&RB7l_ zq$Pb2f|`Pc!c978uxODWZ3;^i`~j9o6O18EA|cCywb^C8yE7ENHY*+xPjRGa=9@X+ znR8}_uZ#TM3BDErxR?VXih3@52GJ0o`-u~rb zn*H-|cyg>2HV#FpS~vOhpLAsTaC~xXDm*(qMt-+6e1xCy5bdF|w_V(&zduM7JkR@A zPW6@_ph6D=jJBPr(7JGRa}DOYx13wQW;5=wJFRKto**OtuVwkYw!e!`JZOIUFL3j5 z)y7NnpicZAfa z(1md^5zfE(4fMi3t-Pk0H$-V?XA;B@T!(;$zJ|Un@+~<~rLDxC6({_o?W@~P7Fzu#X7bmi?TveDD{O}e5l2*7RR;Hs#aceV6>tz zG|)6NSi+Ax{N-4m1ZOv{JG1e-O3y%3Krc+1$esF`6Wj}Nmtj6Q|aW7bC|M5w0eCxz-P&fS$How(h_eG?y0olB@ UHzT|OOaK4?07*qoM6N<$g5AR!D*ylh literal 0 HcmV?d00001 diff --git a/core/res/res/drawable-mdpi/tab_pressed_holo.9.png b/core/res/res/drawable-mdpi/tab_pressed_holo.9.png new file mode 100644 index 0000000000000000000000000000000000000000..a76fbae5be065eee4bfca6aa90d66d18cdfb3d41 GIT binary patch literal 328 zcmV-O0k{5%P)PbXFRCwC7RzVKJFbqpVw|#=&apyJM zc^n_$%7KIyF|o0>#MNqP(%RLE?RHVw%qRzDj-QM-^YO9M<#9{{Rbr~(dY*2QNNM4} z#WRFJNXbJ9VL4D^b`d-aSA?j_O~6feCwxpd#+rlv1QK$SOIVJ8#M&n5sa#Ae{T5qE zRP(?)cz_AfSj7Vwl#&%T4n7*)O|zgCIujJ$>4ubG4+l^Z%Wj9SBq{Xups?u%Ndb*@ zKs}7;S*lgY_NCGLtIichG^J_oD!#7qCAcdL9>b-+lzZnDL4@w!3h5U0zD#-arwi9h afB^t_BY9!3HEJJUw_8NJ*BsMwA5Sr8n0M1DW`tbSwb=FK+^Rf3lPOJU(KVDPR|J0bAe<1Nr)22WQ%mvv4FO#pfqOKt!F literal 0 HcmV?d00001 diff --git a/core/res/res/drawable-mdpi/tab_selected_holo.9.png b/core/res/res/drawable-mdpi/tab_selected_holo.9.png new file mode 100644 index 0000000000000000000000000000000000000000..e029e577a711e01450d8924bb7cd8bcb6867db82 GIT binary patch literal 144 zcmeAS@N?(olHy`uVBq!ia0vp^%s|Y|!3HFERhwS|Qj#UE5hcO-X(i=}MX3yqDfvmM z3ZA)%>8U}fi7AzZCsS>Jii|v6978H@CH?sS-=0~ZfivY;J=+AIS6Aj=Q{WS37HTN$ qQz(|;D3Fkp+<4kRVK;-q0S2o8fp2Rs`~3szX7F_Nb6Mw<&;$SgLM&YX literal 0 HcmV?d00001 diff --git a/core/res/res/drawable-mdpi/tab_selected_pressed_focused_holo.9.png b/core/res/res/drawable-mdpi/tab_selected_pressed_focused_holo.9.png new file mode 100644 index 0000000000000000000000000000000000000000..285116e31e1c3fb26567af209b73718f07bc1355 GIT binary patch literal 454 zcmV;%0XhDOP)DF0XHC5fCg&1oFoM^V6d>XlD+HCBt>?{(e6rmdU}?_B0{m4Sq~g{wt4!r zOWN(uURJA*E8X9o5`pq1%=xiasQb6`jUKk!*Ufr;;jZ^fbg&jJ#D&#`!qIK=b6In= z4s{w7)41lI%r07#2$`jVkT}Ec$L&ljwAe}zSti7@ggO;j6%rHwP=!Q#LdChy6oR*c z@mo=c%?Ogk{+e}+hZtjm#F&LMNtVI#OlD|XWTvJq05qMU)SFOJNG9*oVf%flkP~v9 z=Y+3jgm<=-`V42?!wN%1FiVM3j0wDEHMGV=kqm5;4Rvd0k?m~ w8U}fi7AzZCsS>JiaI@A978H@^#nQcH7M}hZY%G%JHuabG5!aqaP2Bixj6GbE&Os5bkw9sMq-sUhLgvwDil6_u$Ij+-sD=}ZmKxYhgcu#~pn0rP!P zlW+2eN-A94>Tv7U%K#(ixsEr27ML73#$j6gN!I7~MEh2azKZipvd`~)x3!+5XZ7?s c9n*oXua>h?X*ygK2XqvJr>mdKI;Vst06dpdnE(I) literal 0 HcmV?d00001 diff --git a/core/res/res/drawable-mdpi/tab_selector_holo_dark.9.png b/core/res/res/drawable-mdpi/tab_selector_holo_dark.9.png deleted file mode 100644 index 30d30df42b1ddcb557505b0290a3b729f0c6972c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 210 zcmeAS@N?(olHy`uVBq!ia0vp^%0SG?!3HFEyqn4iq*#ibJVQ8upoSx*10-4C5n0T@ zz}*SLjOHg#uLTO0c)B=-SoEHqWXRQEAi$#Do{%{8Q2x(pHmdR;g#VpAbZjf6f^k_BY9!3HEJJUw_8NJ*BsMwA5Sr?ic(Aw2{Hn)z4*}Q$iB};WR^U literal 0 HcmV?d00001 diff --git a/core/res/res/drawable-mdpi/tab_unselected_holo.9.png b/core/res/res/drawable-mdpi/tab_unselected_holo.9.png new file mode 100644 index 0000000000000000000000000000000000000000..848f3f13363cb940353382afd94e8fdcbb13bf34 GIT binary patch literal 128 zcmeAS@N?(olHy`uVBq!ia0vp^%s|Y_!3HE73d0rwDajJoh?3y^w370~qErUQl>DSr z1<%~X^wgl##FWaylc_d9MM|D7jv*Ddl79UEZ_g~yz?s6<;y3q~@R1+qk2LU1_{zW{ a!SH4(?<>94hd6<%89ZJ6T-G@yGywo*Iw!3F literal 0 HcmV?d00001 diff --git a/core/res/res/drawable-mdpi/tab_unselected_pressed_focused_holo.9.png b/core/res/res/drawable-mdpi/tab_unselected_pressed_focused_holo.9.png new file mode 100644 index 0000000000000000000000000000000000000000..3845135847312f61d9874eb4e4e9c703dcc168d6 GIT binary patch literal 459 zcmV;+0W|)JP)>s>b==;?%5h#oym!sb@v)nwLuGD#ddt4nJoq6c_90P317A`GSu=PO9R)W#5 zDoaABnMTGa0uGz~EeLH68Wa=l)Td^P5+Sox5E5soyX1+}R%o%6Ok|l5&k`DTj?>9t zrmYnc83`4B*cEsysCPvJ%vNa@o7Zgfu@GZSP|Fg6NwNUTGnHA}qB1pY383j2O1-J@ zZma!t*zvto$O*a5bHX<>!aG|^edb_0!U{u0FiVM3J|^%rn{`X!mWcowRGV*^%Lll& zO`wIX7002ovPDHLkV1hC_ Bz{LOn literal 0 HcmV?d00001 diff --git a/core/res/res/drawable-mdpi/tab_unselected_pressed_holo.9.png b/core/res/res/drawable-mdpi/tab_unselected_pressed_holo.9.png new file mode 100644 index 0000000000000000000000000000000000000000..23fd8c9b351c7dc4ca7d61bdf8b0fa0b3357afc0 GIT binary patch literal 223 zcmeAS@N?(olHy`uVBq!ia0vp^%s_0!!3HE}@+EEuQj#UE5hcO-X(i=}MX3yqDfvmM z3ZA)%>8U}fi7AzZCsS>JiW)s#978H@^#nQcH7M}h?kex!cUt|2fc?W{-#r$B;+r&$ zCmhJwwN<*&rR9^B`%azPhW7=3CfsE?TiI|eAXVmsigepfZQY<^*$T$v9;+|bZ{5Ls z@x~N43;ta!61B<)ywtP1E|{=7D7Ecj;BU-)@wqN;rGn!(u4Nx%>`hbb@2ehQSYT@5 Uszopr0E4hlYXATM literal 0 HcmV?d00001 diff --git a/core/res/res/drawable/tab_bottom_right.xml b/core/res/res/drawable/tab_bottom_right.xml index f7f5c2f5a07c0..450c461e983bf 100644 --- a/core/res/res/drawable/tab_bottom_right.xml +++ b/core/res/res/drawable/tab_bottom_right.xml @@ -16,6 +16,6 @@ - - + + diff --git a/core/res/res/drawable/tab_indicator_holo.xml b/core/res/res/drawable/tab_indicator_holo.xml new file mode 100644 index 0000000000000..0d46e0c471fd6 --- /dev/null +++ b/core/res/res/drawable/tab_indicator_holo.xml @@ -0,0 +1,34 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/core/res/res/layout/tab_indicator.xml b/core/res/res/layout/tab_indicator.xml index 71e400180898e..bc657c399c265 100644 --- a/core/res/res/layout/tab_indicator.xml +++ b/core/res/res/layout/tab_indicator.xml @@ -20,7 +20,6 @@ android:layout_weight="1" android:layout_marginLeft="-3dip" android:layout_marginRight="-3dip" - android:orientation="vertical" android:background="@android:drawable/tab_indicator"> + + + + + + + + + + + diff --git a/core/res/res/values/attrs.xml b/core/res/res/values/attrs.xml index d5f1610a23ac9..dab627c8a39f1 100755 --- a/core/res/res/values/attrs.xml +++ b/core/res/res/values/attrs.xml @@ -2137,6 +2137,8 @@ + + diff --git a/core/res/res/values/styles.xml b/core/res/res/values/styles.xml index c441f5a193afa..76a3c34abb221 100644 --- a/core/res/res/values/styles.xml +++ b/core/res/res/values/styles.xml @@ -560,6 +560,12 @@ @style/TextAppearance.Widget.TabWidget marquee true + @android:drawable/tab_bottom_left + @android:drawable/tab_bottom_right + true + @null + fill_horizontal|center_vertical + @android:layout/tab_indicator @@ -1421,6 +1427,13 @@ -