summaryrefslogtreecommitdiffstats
path: root/res/layout
diff options
context:
space:
mode:
authorDave Kover <kover@cyngn.com>2016-01-19 15:22:47 -0800
committerGerrit Code Review <gerrit@cyanogenmod.org>2016-01-26 14:05:07 -0800
commit41a3a31e1727de4a3810099d5ef97bd7abc54633 (patch)
treebd03cc6de6454919de1351253f46e2be1ce7bc53 /res/layout
parent815e878a6dcf86b6e90bf6120351872011a767a4 (diff)
downloadpackages_apps_Settings-41a3a31e1727de4a3810099d5ef97bd7abc54633.tar.gz
packages_apps_Settings-41a3a31e1727de4a3810099d5ef97bd7abc54633.tar.bz2
packages_apps_Settings-41a3a31e1727de4a3810099d5ef97bd7abc54633.zip
Fix alignment on dashboard.
When the switch is present, the text is aligning to the top instead of centering to the iconography on the left. Shuffle the layout to make it center where it belongs. Change-Id: I5f2b497385c9370473df441c79e8fc7ddf3b740f Ticket: CYNGNOS-1669
Diffstat (limited to 'res/layout')
-rw-r--r--res/layout/dashboard_tile.xml23
1 files changed, 10 insertions, 13 deletions
diff --git a/res/layout/dashboard_tile.xml b/res/layout/dashboard_tile.xml
index 0fe8fc02b..c844faf03 100644
--- a/res/layout/dashboard_tile.xml
+++ b/res/layout/dashboard_tile.xml
@@ -37,21 +37,14 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="0dip"
- android:orientation="vertical"
+ android:orientation="horizontal"
android:gravity="center_vertical"
android:layout_weight="1">
<RelativeLayout
- android:layout_width="wrap_content"
- android:layout_height="wrap_content">
-
- <Switch
- android:id="@+id/dashboard_switch"
- android:visibility="gone"
- android:layout_alignParentRight="true"
- android:paddingRight="@dimen/action_bar_switch_padding"
- android:layout_height="wrap_content"
- android:layout_width="wrap_content"/>
+ android:layout_width="0dp"
+ android:layout_height="wrap_content"
+ android:layout_weight="1">
<TextView android:id="@+id/title"
android:layout_width="wrap_content"
@@ -59,8 +52,6 @@
android:singleLine="true"
android:textAppearance="@style/TextAppearance.TileTitle"
android:ellipsize="marquee"
- android:layout_alignParentStart="true"
- android:layout_toStartOf="@+id/dashboard_switch"
android:fadingEdge="horizontal"
android:layout_alignParentEnd="false"/>
@@ -76,6 +67,12 @@
</RelativeLayout>
+ <Switch android:id="@+id/dashboard_switch"
+ android:visibility="gone"
+ android:paddingEnd="@dimen/action_bar_switch_padding"
+ android:layout_height="wrap_content"
+ android:layout_width="wrap_content"/>
+
</LinearLayout>
<View android:id="@+id/tile_divider"