Improve Preference highlighting

- use PreferenceFragment.onBindPreferences() to launch  highlighting
- improve SettingsPreferenceFragment code for highlighting: now we can
find the View to highlight thru its Tag if there is no ListAdapter available
- add HighlightingFragment for highlighting a View from its tag/key. This
is dealing with cases when the content is custom and not relying on
SettingsPreferenceFragment (like DataUsageSummary)

Also:

- improve DataUsageSummary so that onResume() is not recreating the
Tabs all the time
- add missing "android:keys" on some Security Settings preference files

Change-Id: Ib1dd8238fe2fb57c151d584c0810a0e0a5ad97c4
This commit is contained in:
Fabrice Di Meglio
2014-04-17 17:20:27 -07:00
parent 5035ec6944
commit f2a5226c1e
12 changed files with 291 additions and 88 deletions

View File

@@ -43,8 +43,8 @@
android:title="@string/security_enable_widgets_title"/>
<PreferenceScreen
android:fragment="com.android.settings.OwnerInfoSettings"
android:key="owner_info_settings"
android:fragment="com.android.settings.OwnerInfoSettings"
android:title="@string/owner_info_settings_title"
android:summary="@string/owner_info_settings_summary"/>