diff --git a/res/layout/dashboard_container_header.xml b/res/layout/dashboard_container_header.xml index a12f2498cb6..59e7eb18100 100644 --- a/res/layout/dashboard_container_header.xml +++ b/res/layout/dashboard_container_header.xml @@ -20,4 +20,6 @@ android:id="@+id/sliding_tabs" android:layout_width="match_parent" android:layout_height="wrap_content" + android:layout_marginLeft="@dimen/dashboard_header_margin_left" + android:layout_marginRight="@dimen/dashboard_header_margin_right" android:background="?android:attr/colorPrimary"/> diff --git a/res/layout/settings_main_dashboard.xml b/res/layout/settings_main_dashboard.xml index c10193cda90..1b7506ea9a4 100644 --- a/res/layout/settings_main_dashboard.xml +++ b/res/layout/settings_main_dashboard.xml @@ -21,4 +21,5 @@ android:id="@+id/main_content" android:layout_height="match_parent" android:layout_width="match_parent" + android:background="@color/material_grey_300" /> diff --git a/res/layout/support_tile_spacer.xml b/res/layout/support_tile_spacer.xml index 95aea0b87c2..41cc22176b3 100644 --- a/res/layout/support_tile_spacer.xml +++ b/res/layout/support_tile_spacer.xml @@ -15,7 +15,7 @@ limitations under the License. --> -112dp - 128dp - 128dp + 160dp + 160dp + + + 304dp + 304dp 128dp diff --git a/res/values-sw720dp/dimens.xml b/res/values-sw720dp/dimens.xml index 981c93602c9..0a2a1ce928b 100644 --- a/res/values-sw720dp/dimens.xml +++ b/res/values-sw720dp/dimens.xml @@ -42,6 +42,10 @@ 80dp 80dp + + 176dp + 176dp + 24dp 24dp diff --git a/res/values/dimens.xml b/res/values/dimens.xml index 2a2b40675e7..74441c20448 100755 --- a/res/values/dimens.xml +++ b/res/values/dimens.xml @@ -96,6 +96,10 @@ 0dp 0dp + + 0dp + 0dp + 0dp 0dp diff --git a/src/com/android/settings/widget/SlidingTabLayout.java b/src/com/android/settings/widget/SlidingTabLayout.java index 6e2d8c6be63..709964640ea 100644 --- a/src/com/android/settings/widget/SlidingTabLayout.java +++ b/src/com/android/settings/widget/SlidingTabLayout.java @@ -83,19 +83,21 @@ public final class SlidingTabLayout extends FrameLayout implements View.OnClickL @Override protected void onLayout(boolean changed, int left, int top, int right, int bottom) { if (mTitleView.getChildCount() > 0) { - mTitleView.layout(0, 0, mTitleView.getMeasuredWidth(), mTitleView.getMeasuredHeight()); final int indicatorBottom = getMeasuredHeight(); final int indicatorHeight = mIndicatorView.getMeasuredHeight(); final int indicatorWidth = mIndicatorView.getMeasuredWidth(); final int totalWidth = getMeasuredWidth(); + final int leftPadding = getPaddingLeft(); + final int rightPadding = getPaddingRight(); + mTitleView.layout(leftPadding, 0, mTitleView.getMeasuredWidth() + rightPadding, + mTitleView.getMeasuredHeight()); // IndicatorView should start on the right when RTL mode is enabled if (isRtlMode()) { mIndicatorView.layout(totalWidth - indicatorWidth, indicatorBottom - indicatorHeight, totalWidth, indicatorBottom); } else { - mIndicatorView.layout(0, indicatorBottom - indicatorHeight, indicatorWidth, indicatorBottom); }