Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ca259f40 authored by Adam Powell's avatar Adam Powell
Browse files

Added resources and styles for ActionBar tabs

Change-Id: I7ba5502146dec2d71b3e9ff57d90e7b5bd2bc2a0
parent d5948d23
Loading
Loading
Loading
Loading
+33 −0
Original line number Diff line number Diff line
@@ -2088,6 +2088,39 @@
 visibility="public"
>
</field>
<field name="actionBarTabBarStyle"
 type="int"
 transient="false"
 volatile="false"
 value="16843572"
 static="true"
 final="true"
 deprecated="not deprecated"
 visibility="public"
>
</field>
<field name="actionBarTabStyle"
 type="int"
 transient="false"
 volatile="false"
 value="16843571"
 static="true"
 final="true"
 deprecated="not deprecated"
 visibility="public"
>
</field>
<field name="actionBarTabTextStyle"
 type="int"
 transient="false"
 volatile="false"
 value="16843573"
 static="true"
 final="true"
 deprecated="not deprecated"
 visibility="public"
>
</field>
<field name="actionButtonPadding"
 type="int"
 transient="false"
+6 −4
Original line number Diff line number Diff line
@@ -371,7 +371,8 @@ public class ActionBarView extends ViewGroup {
                break;
            case ActionBar.NAVIGATION_MODE_TABS:
                mTabScrollView = new HorizontalScrollView(getContext());
                mTabLayout = new LinearLayout(getContext());
                mTabLayout = new LinearLayout(getContext(), null,
                        com.android.internal.R.attr.actionBarTabBarStyle);
                mTabScrollView.addView(mTabLayout);
                addView(mTabScrollView);
                break;
@@ -609,7 +610,7 @@ public class ActionBarView extends ViewGroup {
            if (mTabScrollView != null) {
                mTabScrollView.measure(
                        MeasureSpec.makeMeasureSpec(availableWidth, MeasureSpec.AT_MOST),
                        MeasureSpec.makeMeasureSpec(height, MeasureSpec.AT_MOST));
                        MeasureSpec.makeMeasureSpec(height, MeasureSpec.EXACTLY));
            }
            break;
        }
@@ -711,7 +712,7 @@ public class ActionBarView extends ViewGroup {
        private ActionBar.Tab mTab;

        public TabView(Context context, ActionBar.Tab tab) {
            super(context);
            super(context, null, com.android.internal.R.attr.actionBarTabStyle);
            mTab = tab;

            final View custom = tab.getCustomView();
@@ -734,7 +735,8 @@ public class ActionBarView extends ViewGroup {
                }

                if (text != null) {
                    TextView textView = new TextView(context);
                    TextView textView = new TextView(context, null,
                            com.android.internal.R.attr.actionBarTabTextStyle);
                    textView.setText(text);
                    textView.setSingleLine();
                    textView.setEllipsize(TruncateAt.END);
+182 B
Loading image diff...
+181 B
Loading image diff...
+183 B
Loading image diff...
Loading