diff options
| -rw-r--r-- | res/layout/search_panel.xml | 33 | ||||
| -rw-r--r-- | res/layout/search_suggestion_item.xml | 45 | ||||
| -rw-r--r-- | src/com/android/settings/dashboard/SearchResultsSummary.java | 4 |
3 files changed, 30 insertions, 52 deletions
diff --git a/res/layout/search_panel.xml b/res/layout/search_panel.xml index 22f2b5294..8837bc9d1 100644 --- a/res/layout/search_panel.xml +++ b/res/layout/search_panel.xml @@ -17,7 +17,10 @@ <FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/dashboard" android:layout_width="match_parent" - android:layout_height="match_parent"> + android:layout_height="match_parent" + android:paddingStart="@*android:dimen/preference_fragment_padding_side" + android:paddingEnd="@*android:dimen/preference_fragment_padding_side" + android:background="@color/dashboard_background_color"> <LinearLayout android:layout_width="match_parent" android:layout_height="match_parent" @@ -31,23 +34,19 @@ android:orientation="vertical"> <TextView android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_height="@dimen/dashboard_category_title_height" android:singleLine="true" android:ellipsize="marquee" - android:fadingEdge="horizontal" + android:gravity="center_vertical" android:textAppearance="?android:attr/textAppearanceMedium" - android:text="@string/search_recents_queries_label"/> + android:textAlignment="viewStart" + android:text="@string/search_recents_queries_label" + /> <ListView android:id="@+id/list_suggestions" android:layout_width="match_parent" - android:layout_height="match_parent" /> - - <ImageView android:src="?android:attr/dividerHorizontal" - android:layout_width="fill_parent" - android:layout_height="wrap_content" - android:scaleType="fitXY" - android:paddingBottom="2dp" - android:paddingTop="2dp" /> + android:layout_height="match_parent" + /> </LinearLayout> @@ -56,15 +55,17 @@ android:layout_height="match_parent" android:layout_gravity="center" android:orientation="vertical" - android:layout_weight="1" > + android:layout_weight="1"> <TextView android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_height="@dimen/dashboard_category_title_height" android:singleLine="true" android:ellipsize="marquee" - android:fadingEdge="horizontal" + android:gravity="center_vertical" android:textAppearance="?android:attr/textAppearanceMedium" - android:text="@string/search_results_label"/> + android:textAlignment="viewStart" + android:text="@string/search_results_label" + /> <ListView android:id="@+id/list_results" android:layout_width="match_parent" diff --git a/res/layout/search_suggestion_item.xml b/res/layout/search_suggestion_item.xml index c099892ff..49df3ca4e 100644 --- a/res/layout/search_suggestion_item.xml +++ b/res/layout/search_suggestion_item.xml @@ -22,41 +22,14 @@ android:paddingStart="@*android:dimen/preference_item_padding_side" android:paddingEnd="?android:attr/scrollbarSize"> - <LinearLayout - android:layout_width="wrap_content" - android:layout_height="match_parent" - android:gravity="center" - android:minWidth="@*android:dimen/preference_icon_minWidth" - android:orientation="horizontal"> - - <ImageView - android:id="@+id/icon" - android:layout_width="48dp" - android:layout_height="48dp" - android:layout_gravity="center" - android:minWidth="48dp" - android:scaleType="centerInside" - android:layout_marginEnd="@*android:dimen/preference_item_padding_inner" - /> - - </LinearLayout> - - <RelativeLayout - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_weight="1" - android:paddingEnd="@*android:dimen/preference_item_padding_inner" - android:paddingTop="6dip" - android:paddingBottom="6dip"> - - <TextView android:id="@+id/title" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:singleLine="true" - android:textAppearance="?android:attr/textAppearanceMedium" - android:ellipsize="marquee" - android:fadingEdge="horizontal" /> - - </RelativeLayout> + <TextView android:id="@+id/title" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:paddingStart="@*android:dimen/preference_item_padding_inner" + android:paddingEnd="@*android:dimen/preference_item_padding_inner" + android:singleLine="true" + android:textAppearance="?android:attr/textAppearanceMedium" + android:ellipsize="marquee" + android:fadingEdge="horizontal" /> </LinearLayout> diff --git a/src/com/android/settings/dashboard/SearchResultsSummary.java b/src/com/android/settings/dashboard/SearchResultsSummary.java index e45c5850c..862b53b12 100644 --- a/src/com/android/settings/dashboard/SearchResultsSummary.java +++ b/src/com/android/settings/dashboard/SearchResultsSummary.java @@ -448,6 +448,8 @@ public class SearchResultsSummary extends Fragment { SuggestionItem item = (SuggestionItem) getItem(position); query.setText(item.query); + view.setBackgroundResource(R.drawable.dashboard_tile_background); + return view; } } @@ -621,6 +623,8 @@ public class SearchResultsSummary extends Fragment { imageView.setBackgroundResource(R.drawable.empty_icon); } + view.setBackgroundResource(R.drawable.dashboard_tile_background); + return view; } } |
