diff options
author | Amith Yamasani <yamasani@google.com> | 2012-05-03 12:46:53 -0700 |
---|---|---|
committer | Amith Yamasani <yamasani@google.com> | 2012-05-10 15:18:25 -0700 |
commit | 7a3221bb95efd2e38e2aea243bcb13577bb276b3 (patch) | |
tree | 1b5d463a3a424f0ea48f581034c5bc3e2539ef9b /res | |
parent | 7dabe4583c2bb12ed1d072139399f6bca8067994 (diff) | |
download | packages_apps_settings-7a3221bb95efd2e38e2aea243bcb13577bb276b3.zip packages_apps_settings-7a3221bb95efd2e38e2aea243bcb13577bb276b3.tar.gz packages_apps_settings-7a3221bb95efd2e38e2aea243bcb13577bb276b3.tar.bz2 |
Use Spinner instead of Tabs, so that a 4th entry doesn't disappear off the screen.
This is for the 3 to 4 lists that you can switch between in the Settings->Apps
screen.
Bug: 6375122
Change-Id: I8a4e46b8aa3e06bc79edb5f65400462060fe5a29
Diffstat (limited to 'res')
-rw-r--r-- | res/layout/apps_spinner_dropdown_item.xml (renamed from res/layout/manage_apps_tab_content.xml) | 31 | ||||
-rw-r--r-- | res/layout/apps_spinner_item.xml | 27 | ||||
-rw-r--r-- | res/layout/manage_apps_spinner_content.xml | 51 |
3 files changed, 86 insertions, 23 deletions
diff --git a/res/layout/manage_apps_tab_content.xml b/res/layout/apps_spinner_dropdown_item.xml index b36501b..6f641e7 100644 --- a/res/layout/manage_apps_tab_content.xml +++ b/res/layout/apps_spinner_dropdown_item.xml @@ -2,7 +2,7 @@ <!-- /* ** -** Copyright 2011, The Android Open Source Project +** Copyright 2012, 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. @@ -17,26 +17,11 @@ ** limitations under the License. */ --> - -<TabHost - xmlns:android="http://schemas.android.com/apk/res/android" - android:id="@android:id/tabhost" +<CheckedTextView xmlns:android="http://schemas.android.com/apk/res/android" + android:id="@android:id/text1" + style="?android:attr/spinnerDropDownItemStyle" + android:textAppearance="?android:attr/textAppearanceMedium" + android:singleLine="true" android:layout_width="match_parent" - android:layout_height="match_parent"> - - <LinearLayout - android:orientation="vertical" - android:layout_width="match_parent" - android:layout_height="match_parent" - > - - <include layout="@layout/tab_widget"/> - - <FrameLayout - android:id="@android:id/tabcontent" - android:layout_width="match_parent" - android:layout_height="0dip" - android:layout_weight="1" /> - - </LinearLayout> -</TabHost> + android:layout_height="?android:attr/listPreferredItemHeightSmall" + android:ellipsize="marquee" /> diff --git a/res/layout/apps_spinner_item.xml b/res/layout/apps_spinner_item.xml new file mode 100644 index 0000000..1ca6ffc --- /dev/null +++ b/res/layout/apps_spinner_item.xml @@ -0,0 +1,27 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- +/* +** +** Copyright 2012, 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. +*/ +--> +<TextView xmlns:android="http://schemas.android.com/apk/res/android" + android:id="@android:id/text1" + style="?android:attr/spinnerItemStyle" + android:textAppearance="?android:attr/textAppearanceMedium" + android:singleLine="true" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:ellipsize="marquee" /> diff --git a/res/layout/manage_apps_spinner_content.xml b/res/layout/manage_apps_spinner_content.xml new file mode 100644 index 0000000..cbf0a40 --- /dev/null +++ b/res/layout/manage_apps_spinner_content.xml @@ -0,0 +1,51 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- +/* +** +** Copyright 2012, 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. +*/ +--> + + +<LinearLayout + xmlns:android="http://schemas.android.com/apk/res/android" + android:layout_width="match_parent" + android:layout_height="match_parent" + android:orientation="vertical"> + + <Spinner + android:id="@+id/spinner" + android:layout_width="wrap_content" + android:layout_height="48sp" + android:minWidth="180dp" + android:layout_marginLeft="@*android:dimen/preference_fragment_padding_side" + android:layout_marginRight="@*android:dimen/preference_fragment_padding_side" + /> + + <ImageView + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_marginLeft="@*android:dimen/preference_fragment_padding_side" + android:layout_marginRight="@*android:dimen/preference_fragment_padding_side" + android:scaleType="fitXY" + android:src="?android:attr/listDivider" /> + + <FrameLayout + android:id="@+id/spinner_content" + android:layout_width="match_parent" + android:layout_height="0dip" + android:layout_weight="1" /> + +</LinearLayout> |