summaryrefslogtreecommitdiffstats
path: root/res
diff options
context:
space:
mode:
authorBobby Georgescu <georgescu@google.com>2012-10-11 14:49:09 -0700
committerBobby Georgescu <georgescu@google.com>2012-10-11 15:20:07 -0700
commit40d60a4162f863380f228cd53d47eeb156114b2a (patch)
tree469e69ee07609e096fd0acea59906219f3a84d28 /res
parent353cdcead467a6d5ab57f1d86501239abe11a25a (diff)
downloadandroid_packages_apps_Snap-40d60a4162f863380f228cd53d47eeb156114b2a.tar.gz
android_packages_apps_Snap-40d60a4162f863380f228cd53d47eeb156114b2a.tar.bz2
android_packages_apps_Snap-40d60a4162f863380f228cd53d47eeb156114b2a.zip
Change ActionBar spinner text size on rotate
Bug: 7333151 Update the grid/filmstrip spinner switch text to look and behave like the text in the Gmail app, as requested by UX. Change-Id: If822b21899172a35402477868d4f146a8e00cfea
Diffstat (limited to 'res')
-rw-r--r--res/layout/action_bar_two_line_text.xml50
-rw-r--r--res/values-land/styles.xml22
-rw-r--r--res/values/styles.xml2
3 files changed, 49 insertions, 25 deletions
diff --git a/res/layout/action_bar_two_line_text.xml b/res/layout/action_bar_two_line_text.xml
index 9b76a8072..95faffa12 100644
--- a/res/layout/action_bar_two_line_text.xml
+++ b/res/layout/action_bar_two_line_text.xml
@@ -14,29 +14,29 @@
limitations under the License.
-->
<TwoLineListItem xmlns:android="http://schemas.android.com/apk/res/android"
- android:paddingLeft="18dp"
- android:paddingRight="18dp"
- android:background="?android:attr/activatedBackgroundIndicator"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:minHeight="?android:attr/listPreferredItemHeight"
- android:mode="twoLine"
- android:gravity="center_vertical"
->
- <TextView xmlns:android="http://schemas.android.com/apk/res/android"
- android:id="@android:id/text1"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:singleLine="true"
- android:ellipsize="end"
- android:textSize="15dp"
- />
- <TextView xmlns:android="http://schemas.android.com/apk/res/android"
- android:id="@android:id/text2"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:layout_below="@android:id/text1"
- android:textSize="9dp"
- android:singleLine="true"
- />
+ android:layout_height="match_parent"
+ android:orientation="vertical"
+ android:gravity="center_vertical"
+ android:background="?android:attr/activatedBackgroundIndicator"
+ android:duplicateParentState="false"
+ android:layout_alignParentLeft="true"
+ android:layout_width="wrap_content" >
+ <TextView
+ android:id="@android:id/text1"
+ style="@style/ActionBarTwoLinePrimary"
+ android:singleLine="true"
+ android:ellipsize="end"
+ android:includeFontPadding="false"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content" />
+ <TextView
+ android:id="@android:id/text2"
+ style="@style/ActionBarTwoLineSecondary"
+ android:singleLine="true"
+ android:ellipsize="end"
+ android:includeFontPadding="false"
+ android:layout_marginRight="4dp"
+ android:layout_below="@android:id/text1"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content" />
</TwoLineListItem>
diff --git a/res/values-land/styles.xml b/res/values-land/styles.xml
new file mode 100644
index 000000000..c10362ea0
--- /dev/null
+++ b/res/values-land/styles.xml
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2011 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- Spinner primary text is smaller than usual due to extra vertical padding in spinner asset -->
+ <style name="ActionBarTwoLinePrimary" parent="@android:style/TextAppearance.Holo.Widget.ActionBar.Title">
+ <item name="android:textSize">14sp</item>
+ </style>
+</resources>
diff --git a/res/values/styles.xml b/res/values/styles.xml
index abcd4dd10..c534ad895 100644
--- a/res/values/styles.xml
+++ b/res/values/styles.xml
@@ -41,4 +41,6 @@
</style>
<bool name="picker_is_dialog">false</bool>
<color name="darker_transparent">#C1000000</color>
+ <style name="ActionBarTwoLinePrimary" parent="@android:style/TextAppearance.Holo.Widget.ActionBar.Title"></style>
+ <style name="ActionBarTwoLineSecondary" parent="@android:style/TextAppearance.Holo.Widget.ActionBar.Subtitle"></style>
</resources>