summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Fabrice Di Meglio <fdimeglio@google.com> 2014-09-26 20:52:01 +0000
committer Android (Google) Code Review <android-gerrit@google.com> 2014-09-26 20:52:02 +0000
commit6b0a880e13b217b670f27bfe8ef3a13b3bb51af0 (patch)
treee50271a6b6c8d032e04cb8a2a903f4f23a36565c
parent245bd4ec8a6d785e77315eccf5a4556650f6df10 (diff)
parentb22be6fcf2689a7de3795f406678caf73180a990 (diff)
Merge "Fix bug #17521147 Settings activity looks terrible on Volantis" into lmp-dev
-rw-r--r--core/java/android/app/FragmentBreadCrumbs.java13
-rw-r--r--core/java/android/preference/PreferenceActivity.java48
-rw-r--r--core/res/res/layout-xlarge/breadcrumbs_in_fragment_material.xml34
-rw-r--r--core/res/res/layout/fragment_bread_crumb_item_material.xml41
-rw-r--r--core/res/res/layout/preference_header_item_material.xml63
-rw-r--r--core/res/res/layout/preference_list_content_material.xml117
-rw-r--r--core/res/res/values/attrs.xml17
-rw-r--r--core/res/res/values/dimens_material.xml15
-rw-r--r--core/res/res/values/styles.xml8
-rw-r--r--core/res/res/values/styles_material.xml25
-rw-r--r--core/res/res/values/symbols.xml1
-rw-r--r--core/res/res/values/themes.xml1
-rw-r--r--core/res/res/values/themes_holo.xml2
-rw-r--r--core/res/res/values/themes_material.xml4
14 files changed, 374 insertions, 15 deletions
diff --git a/core/java/android/app/FragmentBreadCrumbs.java b/core/java/android/app/FragmentBreadCrumbs.java
index ab0fc6659e33..d0aa0fd605bb 100644
--- a/core/java/android/app/FragmentBreadCrumbs.java
+++ b/core/java/android/app/FragmentBreadCrumbs.java
@@ -58,6 +58,8 @@ public class FragmentBreadCrumbs extends ViewGroup
private OnBreadCrumbClickListener mOnBreadCrumbClickListener;
private int mGravity;
+ private int mLayoutResId;
+ private int mTextColor;
private static final int DEFAULT_GRAVITY = Gravity.START | Gravity.CENTER_VERTICAL;
@@ -103,6 +105,12 @@ public class FragmentBreadCrumbs extends ViewGroup
mGravity = a.getInt(com.android.internal.R.styleable.FragmentBreadCrumbs_gravity,
DEFAULT_GRAVITY);
+ mLayoutResId = a.getResourceId(
+ com.android.internal.R.styleable.FragmentBreadCrumbs_itemLayout,
+ com.android.internal.R.layout.fragment_bread_crumb_item);
+ mTextColor = a.getColor(
+ com.android.internal.R.styleable.FragmentBreadCrumbs_itemColor,
+ 0);
a.recycle();
}
@@ -311,12 +319,11 @@ public class FragmentBreadCrumbs extends ViewGroup
}
}
if (i >= numViews) {
- final View item = mInflater.inflate(
- com.android.internal.R.layout.fragment_bread_crumb_item,
- this, false);
+ final View item = mInflater.inflate(mLayoutResId, this, false);
final TextView text = (TextView) item.findViewById(com.android.internal.R.id.title);
text.setText(bse.getBreadCrumbTitle());
text.setTag(bse);
+ text.setTextColor(mTextColor);
if (i == 0) {
item.findViewById(com.android.internal.R.id.left_icon).setVisibility(View.GONE);
}
diff --git a/core/java/android/preference/PreferenceActivity.java b/core/java/android/preference/PreferenceActivity.java
index 23b1e2c00022..04cd7d502f6e 100644
--- a/core/java/android/preference/PreferenceActivity.java
+++ b/core/java/android/preference/PreferenceActivity.java
@@ -212,6 +212,9 @@ public abstract class PreferenceActivity extends ListActivity implements
private Button mNextButton;
+ private int mPreferenceHeaderItemResId = 0;
+ private boolean mPreferenceHeaderRemoveEmptyIcon = false;
+
/**
* The starting request code given out to preference framework.
*/
@@ -258,10 +261,15 @@ public abstract class PreferenceActivity extends ListActivity implements
}
private LayoutInflater mInflater;
+ private int mLayoutResId;
+ private boolean mRemoveIconIfEmpty;
- public HeaderAdapter(Context context, List<Header> objects) {
+ public HeaderAdapter(Context context, List<Header> objects, int layoutResId,
+ boolean removeIconBehavior) {
super(context, 0, objects);
mInflater = (LayoutInflater)context.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
+ mLayoutResId = layoutResId;
+ mRemoveIconIfEmpty = removeIconBehavior;
}
@Override
@@ -270,8 +278,7 @@ public abstract class PreferenceActivity extends ListActivity implements
View view;
if (convertView == null) {
- view = mInflater.inflate(com.android.internal.R.layout.preference_header_item,
- parent, false);
+ view = mInflater.inflate(mLayoutResId, parent, false);
holder = new HeaderViewHolder();
holder.icon = (ImageView) view.findViewById(com.android.internal.R.id.icon);
holder.title = (TextView) view.findViewById(com.android.internal.R.id.title);
@@ -284,7 +291,16 @@ public abstract class PreferenceActivity extends ListActivity implements
// All view fields must be updated every time, because the view may be recycled
Header header = getItem(position);
- holder.icon.setImageResource(header.iconRes);
+ if (mRemoveIconIfEmpty) {
+ if (header.iconRes == 0) {
+ holder.icon.setVisibility(View.GONE);
+ } else {
+ holder.icon.setVisibility(View.VISIBLE);
+ holder.icon.setImageResource(header.iconRes);
+ }
+ } else {
+ holder.icon.setImageResource(header.iconRes);
+ }
holder.title.setText(header.getTitle(getContext().getResources()));
CharSequence summary = header.getSummary(getContext().getResources());
if (!TextUtils.isEmpty(summary)) {
@@ -512,7 +528,26 @@ public abstract class PreferenceActivity extends ListActivity implements
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
- setContentView(com.android.internal.R.layout.preference_list_content);
+ // Theming for the PreferenceActivity layout and for the Preference Header(s) layout
+ TypedArray sa = obtainStyledAttributes(null,
+ com.android.internal.R.styleable.PreferenceActivity,
+ com.android.internal.R.attr.preferenceActivityStyle,
+ 0);
+
+ final int layoutResId = sa.getResourceId(
+ com.android.internal.R.styleable.PreferenceActivity_layout,
+ com.android.internal.R.layout.preference_list_content);
+
+ mPreferenceHeaderItemResId = sa.getResourceId(
+ com.android.internal.R.styleable.PreferenceActivity_headerLayout,
+ com.android.internal.R.layout.preference_header_item);
+ mPreferenceHeaderRemoveEmptyIcon = sa.getBoolean(
+ com.android.internal.R.styleable.PreferenceActivity_headerRemoveIconIfEmpty,
+ false);
+
+ sa.recycle();
+
+ setContentView(layoutResId);
mListFooter = (FrameLayout)findViewById(com.android.internal.R.id.list_footer);
mPrefsContainer = (ViewGroup) findViewById(com.android.internal.R.id.prefs_frame);
@@ -582,7 +617,8 @@ public abstract class PreferenceActivity extends ListActivity implements
showBreadCrumbs(initialTitleStr, initialShortTitleStr);
}
} else if (mHeaders.size() > 0) {
- setListAdapter(new HeaderAdapter(this, mHeaders));
+ setListAdapter(new HeaderAdapter(this, mHeaders, mPreferenceHeaderItemResId,
+ mPreferenceHeaderRemoveEmptyIcon));
if (!mSinglePane) {
// Multi-pane.
getListView().setChoiceMode(AbsListView.CHOICE_MODE_SINGLE);
diff --git a/core/res/res/layout-xlarge/breadcrumbs_in_fragment_material.xml b/core/res/res/layout-xlarge/breadcrumbs_in_fragment_material.xml
new file mode 100644
index 000000000000..6fb6df56ffa0
--- /dev/null
+++ b/core/res/res/layout-xlarge/breadcrumbs_in_fragment_material.xml
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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:id="@+android:id/breadcrumb_section"
+ android:orientation="vertical"
+ android:layout_height="wrap_content"
+ android:layout_width="match_parent"
+ android:layout_marginStart="@dimen/preference_breadcrumbs_padding_start_material"
+ android:layout_marginEnd="@dimen/preference_breadcrumbs_padding_end_material"
+ >
+ <android.app.FragmentBreadCrumbs
+ android:id="@android:id/title"
+ android:layout_height="72dip"
+ android:layout_width="match_parent"
+ android:paddingTop="16dip"
+ android:paddingBottom="8dip"
+ android:gravity="center_vertical|start"
+ />
+
+</LinearLayout> \ No newline at end of file
diff --git a/core/res/res/layout/fragment_bread_crumb_item_material.xml b/core/res/res/layout/fragment_bread_crumb_item_material.xml
new file mode 100644
index 000000000000..ee4344f25cd3
--- /dev/null
+++ b/core/res/res/layout/fragment_bread_crumb_item_material.xml
@@ -0,0 +1,41 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2010 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="wrap_content"
+ android:layout_height="match_parent"
+ android:orientation="horizontal"
+ >
+ <ImageView
+ android:id="@android:id/left_icon"
+ android:src="?attr/dividerVertical"
+ android:layout_width="wrap_content"
+ android:layout_height="match_parent"
+ android:scaleType="fitXY"
+ android:layout_marginTop="12dip"
+ android:layout_marginBottom="12dip"
+ />
+
+ <TextView
+ android:id="@+id/title"
+ android:layout_width="wrap_content"
+ android:layout_height="match_parent"
+ android:paddingStart="8dip"
+ android:paddingEnd="8dip"
+ android:gravity="center_vertical"
+ android:textAppearance="?android:attr/textAppearanceMedium"
+ android:background="?android:attr/selectableItemBackground"
+ />
+</LinearLayout> \ No newline at end of file
diff --git a/core/res/res/layout/preference_header_item_material.xml b/core/res/res/layout/preference_header_item_material.xml
new file mode 100644
index 000000000000..594189fa6517
--- /dev/null
+++ b/core/res/res/layout/preference_header_item_material.xml
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<!-- Layout of a header item in PreferenceActivity. -->
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:minHeight="48dp"
+ android:background="?android:attr/activatedBackgroundIndicator"
+ android:gravity="center_vertical"
+ android:paddingStart="24dip"
+ android:paddingEnd="?android:attr/scrollbarSize">
+
+ <ImageView
+ android:id="@+id/icon"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_marginStart="0dip"
+ android:layout_marginEnd="8dip"
+ android:layout_gravity="center" />
+
+ <RelativeLayout
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_marginStart="0dip"
+ android:layout_marginEnd="6dip"
+ android:layout_marginTop="6dip"
+ android:layout_marginBottom="6dip"
+ android:layout_weight="1">
+
+ <TextView android:id="@+android: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" />
+
+ <TextView android:id="@+android:id/summary"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_below="@android:id/title"
+ android:layout_alignStart="@android:id/title"
+ android:textAppearance="?android:attr/textAppearanceSmall"
+ android:ellipsize="end"
+ android:maxLines="2" />
+
+ </RelativeLayout>
+
+</LinearLayout>
diff --git a/core/res/res/layout/preference_list_content_material.xml b/core/res/res/layout/preference_list_content_material.xml
new file mode 100644
index 000000000000..78567999be13
--- /dev/null
+++ b/core/res/res/layout/preference_list_content_material.xml
@@ -0,0 +1,117 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/* //device/apps/common/assets/res/layout/list_content.xml
+**
+** Copyright 2014, 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:orientation="vertical"
+ android:layout_height="match_parent"
+ android:layout_width="match_parent">
+
+ <LinearLayout
+ android:orientation="horizontal"
+ android:layout_width="match_parent"
+ android:layout_height="0px"
+ android:layout_weight="1">
+
+ <LinearLayout
+ style="?attr/preferenceHeaderPanelStyle"
+ android:id="@+id/headers"
+ android:orientation="vertical"
+ android:layout_width="0px"
+ android:layout_height="match_parent"
+ android:layout_weight="@integer/preferences_left_pane_weight"
+ android:background="?attr/windowBackground"
+ android:elevation="4dip" >
+
+ <ListView android:id="@android:id/list"
+ style="?attr/preferenceListStyle"
+ android:layout_width="match_parent"
+ android:layout_height="0px"
+ android:layout_weight="1"
+ android:clipToPadding="false"
+ android:drawSelectorOnTop="false"
+ android:cacheColorHint="@color/transparent"
+ android:listPreferredItemHeight="48dp"
+ android:scrollbarAlwaysDrawVerticalTrack="true" />
+
+ <FrameLayout android:id="@+id/list_footer"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="0" />
+
+ </LinearLayout>
+
+ <LinearLayout
+ android:id="@+id/prefs_frame"
+ style="?attr/preferencePanelStyle"
+ android:layout_width="0px"
+ android:layout_height="match_parent"
+ android:layout_weight="@integer/preferences_right_pane_weight"
+ android:orientation="vertical"
+ android:visibility="gone" >
+
+ <!-- Breadcrumb inserted here, in certain screen sizes. In others, it will be an
+ empty layout or just padding, and PreferenceActivity will put the breadcrumbs in
+ the action bar. -->
+ <include layout="@layout/breadcrumbs_in_fragment_material" />
+
+ <android.preference.PreferenceFrameLayout android:id="@+id/prefs"
+ android:layout_width="match_parent"
+ android:layout_height="0dip"
+ android:layout_weight="1"
+ />
+ </LinearLayout>
+ </LinearLayout>
+
+ <RelativeLayout android:id="@+id/button_bar"
+ android:layout_height="wrap_content"
+ android:layout_width="match_parent"
+ android:layout_weight="0"
+ android:visibility="gone">
+
+ <Button android:id="@+id/back_button"
+ android:layout_width="150dip"
+ android:layout_height="wrap_content"
+ android:layout_margin="5dip"
+ android:layout_alignParentStart="true"
+ android:text="@string/back_button_label"
+ />
+ <LinearLayout
+ android:orientation="horizontal"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignParentEnd="true">
+
+ <Button android:id="@+id/skip_button"
+ android:layout_width="150dip"
+ android:layout_height="wrap_content"
+ android:layout_margin="5dip"
+ android:text="@string/skip_button_label"
+ android:visibility="gone"
+ />
+
+ <Button android:id="@+id/next_button"
+ android:layout_width="150dip"
+ android:layout_height="wrap_content"
+ android:layout_margin="5dip"
+ android:text="@string/next_button_label"
+ />
+ </LinearLayout>
+ </RelativeLayout>
+</LinearLayout>
diff --git a/core/res/res/values/attrs.xml b/core/res/res/values/attrs.xml
index 90217e57a786..8ea181407c25 100644
--- a/core/res/res/values/attrs.xml
+++ b/core/res/res/values/attrs.xml
@@ -836,6 +836,8 @@
<!-- Default style for PreferenceScreen. -->
<attr name="preferenceScreenStyle" format="reference" />
+ <!-- Default style for the PreferenceActivity. -->
+ <attr name="preferenceActivityStyle" format="reference" />
<!-- Default style for Headers pane in PreferenceActivity. -->
<attr name="preferenceFragmentStyle" format="reference" />
<!-- Default style for PreferenceCategory. -->
@@ -7265,10 +7267,21 @@
<!-- Base attributes available to PreferenceFragment. -->
<declare-styleable name="PreferenceFragment">
- <!-- The layout for the PreferenceFragment. This should rarely need to be changed -->
+ <!-- The layout for the PreferenceFragment. This should rarely need to be changed. -->
<attr name="layout" />
</declare-styleable>
+ <!-- Base attributes available to PreferenceActivity. -->
+ <declare-styleable name="PreferenceActivity">
+ <!-- The layout for the Preference Activity. This should rarely need to be changed. -->
+ <attr name="layout" />
+ <!-- The layout for the Preference Header. This should rarely need to be changed. -->
+ <attr name="headerLayout" format="reference" />
+ <!-- true if the Icon view will be removed when there is none and thus not showing
+ the fixed margins. -->
+ <attr name="headerRemoveIconIfEmpty" format="boolean" />
+ </declare-styleable>
+
<!-- Use <code>tts-engine</code> as the root tag of the XML resource that
describes a text to speech engine implemented as a subclass of
{@link android.speech.tts.TextToSpeechService}.
@@ -7370,6 +7383,8 @@
tags. -->
<declare-styleable name="FragmentBreadCrumbs">
<attr name="gravity" />
+ <attr name="itemLayout" format="reference" />
+ <attr name="itemColor" format="color|reference" />
</declare-styleable>
<declare-styleable name="MultiPaneChallengeLayout">
diff --git a/core/res/res/values/dimens_material.xml b/core/res/res/values/dimens_material.xml
index 9836757b9f50..450658e22526 100644
--- a/core/res/res/values/dimens_material.xml
+++ b/core/res/res/values/dimens_material.xml
@@ -14,9 +14,22 @@
limitations under the License.
-->
<resources>
+ <!-- Preference activity, vertical padding for the header list -->
+ <dimen name="preference_screen_header_vertical_padding_material">8dp</dimen>
+
+ <!-- Preference activity side margins -->
+ <dimen name="preference_screen_side_margin_material">0dp</dimen>
+ <!-- Preference activity side margins negative-->
+ <dimen name="preference_screen_side_margin_negative_material">0dp</dimen>
<!-- Preference fragment padding, sides -->
- <dimen name="preference_fragment_padding_side_material">0dp</dimen>
+ <dimen name="preference_fragment_padding_side_material">8dp</dimen>
+
+ <!-- Preference breadcrumbs padding, start padding -->
+ <dimen name="preference_breadcrumbs_padding_start_material">12dp</dimen>
+
+ <!-- Preference breadcrumbs padding, end padding -->
+ <dimen name="preference_breadcrumbs_padding_end_material">24dp</dimen>
<dimen name="preference_screen_header_padding_side_material">0dp</dimen>
diff --git a/core/res/res/values/styles.xml b/core/res/res/values/styles.xml
index c6d0b0b50822..ba15e9cc28c0 100644
--- a/core/res/res/values/styles.xml
+++ b/core/res/res/values/styles.xml
@@ -533,6 +533,8 @@ please see styles_device_defaults.xml.
<style name="Widget.FragmentBreadCrumbs">
<item name="padding">4dp</item>
<item name="animateLayoutChanges">true</item>
+ <item name="itemLayout">@layout/fragment_bread_crumb_item</item>
+ <item name="itemColor">@null</item>
</style>
<style name="Widget.ImageWell">
@@ -954,6 +956,12 @@ please see styles_device_defaults.xml.
<item name="paddingEnd">0dp</item>
</style>
+ <style name="PreferenceActivity">
+ <item name="layout">@layout/preference_list_content</item>
+ <item name="headerLayout">@layout/preference_header_item</item>
+ <item name="headerRemoveIconIfEmpty">false</item>
+ </style>
+
<style name="Preference.Information">
<item name="layout">@layout/preference_information</item>
<item name="enabled">false</item>
diff --git a/core/res/res/values/styles_material.xml b/core/res/res/values/styles_material.xml
index e6e5cbb8e788..f9fca00d3ba4 100644
--- a/core/res/res/values/styles_material.xml
+++ b/core/res/res/values/styles_material.xml
@@ -42,6 +42,12 @@ please see styles_device_defaults.xml.
<item name="paddingEnd">@dimen/preference_fragment_padding_side_material</item>
</style>
+ <style name="PreferenceActivity.Material">
+ <item name="layout">@layout/preference_list_content_material</item>
+ <item name="headerLayout">@layout/preference_header_item_material</item>
+ <item name="headerRemoveIconIfEmpty">true</item>
+ </style>
+
<style name="Preference.Material.Information">
<item name="layout">@layout/preference_information_material</item>
<item name="enabled">false</item>
@@ -93,6 +99,8 @@ please see styles_device_defaults.xml.
<!-- No margins or background by default. Could be different for x-large screens -->
<style name="PreferencePanel.Material">
+ <item name="layout_marginStart">0dip</item>
+ <item name="layout_marginEnd">0dip</item>
</style>
<!-- The attributes are overridden here because the x-large or large resources may have
@@ -106,10 +114,10 @@ please see styles_device_defaults.xml.
</style>
<style name="PreferenceHeaderPanel.Material">
- <item name="layout_marginStart">@dimen/preference_screen_side_margin</item>
- <item name="layout_marginEnd">@dimen/preference_screen_side_margin_negative</item>
- <item name="paddingTop">@dimen/preference_screen_header_vertical_padding</item>
- <item name="paddingBottom">@dimen/preference_screen_header_vertical_padding</item>
+ <item name="layout_marginStart">@dimen/preference_screen_side_margin_material</item>
+ <item name="layout_marginEnd">@dimen/preference_screen_side_margin_negative_material</item>
+ <item name="paddingTop">@dimen/preference_screen_header_vertical_padding_material</item>
+ <item name="paddingBottom">@dimen/preference_screen_header_vertical_padding_material</item>
</style>
<style name="PreferenceHeaderList.Material">
@@ -585,6 +593,12 @@ please see styles_device_defaults.xml.
</style>
<style name="Widget.Material.ExpandableListView.White"/>
+
+ <style name="Widget.Material.FragmentBreadCrumbs" parent="Widget.FragmentBreadCrumbs">
+ <item name="itemLayout">@layout/fragment_bread_crumb_item_material</item>
+ <item name="itemColor">@color/primary_text_default_material_light</item>
+ </style>
+
<style name="Widget.Material.Gallery" parent="Widget.Gallery"/>
<style name="Widget.Material.GestureOverlayView" parent="Widget.GestureOverlayView"/>
@@ -972,6 +986,9 @@ please see styles_device_defaults.xml.
<style name="Widget.Material.Light.EditText" parent="Widget.Material.EditText"/>
<style name="Widget.Material.Light.ExpandableListView" parent="Widget.Material.ExpandableListView"/>
<style name="Widget.Material.Light.ExpandableListView.White" parent="Widget.Material.ExpandableListView.White"/>
+ <style name="Widget.Material.Light.FragmentBreadCrumbs" parent="Widget.Material.FragmentBreadCrumbs" >
+ <item name="itemColor">@color/primary_text_default_material_dark</item>
+ </style>
<style name="Widget.Material.Light.Gallery" parent="Widget.Material.Gallery"/>
<style name="Widget.Material.Light.GestureOverlayView" parent="Widget.Material.GestureOverlayView"/>
<style name="Widget.Material.Light.GridView" parent="Widget.Material.GridView"/>
diff --git a/core/res/res/values/symbols.xml b/core/res/res/values/symbols.xml
index 72f756af960e..f2b7d7be5f6f 100644
--- a/core/res/res/values/symbols.xml
+++ b/core/res/res/values/symbols.xml
@@ -2021,6 +2021,7 @@
<java-symbol type="style" name="TextAppearance.Material.TimePicker.TimeLabel" />
<java-symbol type="attr" name="seekBarPreferenceStyle" />
<java-symbol type="style" name="Theme.DeviceDefault.Resolver" />
+ <java-symbol type="attr" name="preferenceActivityStyle" />
<java-symbol type="attr" name="preferenceFragmentStyle" />
<java-symbol type="bool" name="skipHoldBeforeMerge" />
<java-symbol type="bool" name="imsServiceAllowTurnOff" />
diff --git a/core/res/res/values/themes.xml b/core/res/res/values/themes.xml
index 3a268a3264e5..7a9e1d59924c 100644
--- a/core/res/res/values/themes.xml
+++ b/core/res/res/values/themes.xml
@@ -317,6 +317,7 @@ please see themes_device_defaults.xml.
<!-- Preference styles -->
<item name="preferenceScreenStyle">@style/Preference.PreferenceScreen</item>
+ <item name="preferenceActivityStyle">@style/PreferenceActivity</item>
<item name="preferenceFragmentStyle">@style/PreferenceFragment</item>
<item name="preferenceCategoryStyle">@style/Preference.Category</item>
<item name="preferenceStyle">@style/Preference</item>
diff --git a/core/res/res/values/themes_holo.xml b/core/res/res/values/themes_holo.xml
index 208db977af4e..9c1d0f38faf9 100644
--- a/core/res/res/values/themes_holo.xml
+++ b/core/res/res/values/themes_holo.xml
@@ -308,6 +308,7 @@ please see themes_device_defaults.xml.
<!-- Preference styles -->
<item name="preferenceScreenStyle">@style/Preference.Holo.PreferenceScreen</item>
+ <item name="preferenceActivityStyle">@style/PreferenceActivity</item>
<item name="preferenceFragmentStyle">@style/PreferenceFragment.Holo</item>
<item name="preferenceCategoryStyle">@style/Preference.Holo.Category</item>
<item name="preferenceStyle">@style/Preference.Holo</item>
@@ -643,6 +644,7 @@ please see themes_device_defaults.xml.
<!-- Preference styles -->
<item name="preferenceScreenStyle">@style/Preference.Holo.PreferenceScreen</item>
+ <item name="preferenceActivityStyle">@style/PreferenceActivity</item>
<item name="preferenceFragmentStyle">@style/PreferenceFragment.Holo</item>
<item name="preferenceCategoryStyle">@style/Preference.Holo.Category</item>
<item name="preferenceStyle">@style/Preference.Holo</item>
diff --git a/core/res/res/values/themes_material.xml b/core/res/res/values/themes_material.xml
index 3c2e3020dbbe..64201537c0a2 100644
--- a/core/res/res/values/themes_material.xml
+++ b/core/res/res/values/themes_material.xml
@@ -275,9 +275,11 @@ please see themes_device_defaults.xml.
<item name="popupMenuStyle">@style/Widget.Material.PopupMenu</item>
<item name="stackViewStyle">@style/Widget.Material.StackView</item>
<item name="activityChooserViewStyle">@style/Widget.Material.ActivityChooserView</item>
+ <item name="fragmentBreadCrumbsStyle">@style/Widget.Material.FragmentBreadCrumbs</item>
<!-- Preference styles -->
<item name="preferenceScreenStyle">@style/Preference.Material.PreferenceScreen</item>
+ <item name="preferenceActivityStyle">@style/PreferenceActivity.Material</item>
<item name="preferenceFragmentStyle">@style/PreferenceFragment.Material</item>
<item name="preferenceCategoryStyle">@style/Preference.Material.Category</item>
<item name="preferenceStyle">@style/Preference.Material</item>
@@ -622,9 +624,11 @@ please see themes_device_defaults.xml.
<item name="popupMenuStyle">@style/Widget.Material.Light.PopupMenu</item>
<item name="stackViewStyle">@style/Widget.Material.Light.StackView</item>
<item name="activityChooserViewStyle">@style/Widget.Material.Light.ActivityChooserView</item>
+ <item name="fragmentBreadCrumbsStyle">@style/Widget.Material.FragmentBreadCrumbs</item>
<!-- Preference styles -->
<item name="preferenceScreenStyle">@style/Preference.Material.PreferenceScreen</item>
+ <item name="preferenceActivityStyle">@style/PreferenceActivity.Material</item>
<item name="preferenceFragmentStyle">@style/PreferenceFragment.Material</item>
<item name="preferenceCategoryStyle">@style/Preference.Material.Category</item>
<item name="preferenceStyle">@style/Preference.Material</item>