This aligns text on preferences on the same screen when some of them don't have icons. - Use a custom layout for preference EditPreference switch preference VolumeSeekPreference DialogPreferencei Restricted*Preference DropdownPreference - Moved related style defs into a new file styles_preference.xml, because current styles file is too large to read. - Switch <PreferenceScreen ...> to <Preference ...> for a bunch of regular preferences. - Also removed some dead style. Bug: 33430928 Test: runtest --path packages/apps/Settings/tests/app/src/com/android/settings/dashboard/PreferenceThemeTest.java Change-Id: Ic9b75d3f133f2a83cd999297b8596253d4b10161
58 lines
2.4 KiB
XML
58 lines
2.4 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!--
|
|
Copyright (C) 2016 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.
|
|
-->
|
|
|
|
<!-- This file only contains custom attribute and style definition for preferences -->
|
|
<!-- Things unrelated to preference framework UI customization should go to other styles files -->
|
|
<resources>
|
|
<style name="ApnPreference">
|
|
<item name="android:layout">@layout/apn_preference_layout</item>
|
|
</style>
|
|
|
|
<style name="EditTextPreference"
|
|
parent="@style/Preference.DialogPreference.EditTextPreference.Material">
|
|
<item name="android:layout">@layout/preference_material_settings</item>
|
|
<item name="android:dialogLayout">@layout/preference_dialog_edittext</item>
|
|
</style>
|
|
|
|
<style name="PreferenceFragmentStyle" parent="@*android:style/PreferenceFragment.Material">
|
|
<item name="android:layout">@layout/preference_list_fragment</item>
|
|
</style>
|
|
|
|
<style name="SettingsPreference">
|
|
<item name="android:layout">@layout/preference_material_settings</item>
|
|
</style>
|
|
|
|
<style name="SettingsDropdownPreference">
|
|
<item name="android:layout">@layout/preference_dropdown_material_settings</item>
|
|
</style>
|
|
|
|
<style name="SettingsDialogPreference" parent="SettingsPreference"/>
|
|
|
|
<style name="SettingsPreferenceCategory" parent="@style/Preference.Category.Material">
|
|
<item name="android:layout">@layout/preference_category_material_settings</item>
|
|
</style>
|
|
|
|
<style name="SettingsSwitchPreference" parent="SettingsPreference">
|
|
<item name="widgetLayout">@*android:layout/preference_widget_switch</item>
|
|
<item name="switchTextOn">@*android:string/capital_on</item>
|
|
<item name="switchTextOff">@*android:string/capital_off</item>
|
|
</style>
|
|
|
|
<style name="SyncSwitchPreference" parent="SettingsPreference">
|
|
<item name="android:widgetLayout">@layout/preference_widget_sync_toggle</item>
|
|
</style>
|
|
</resources> |