Settings: Update to follow new volume design.

- "Sound & Notification"  (not Notifications)
- Remove ringer-mode pref.
- Add zen-mode pref to renamed "Interruptions" screen.
- Implement two separate "Sound" & "Notification" sections.
- Remove "Showing notifications" screen, migrate settings.
- Remove custom category styling now that we have a platform style.
- Implement new "days" sleep mode and corresponding dialog pref.
- Corresponding changes to indexable resources.

Associated frameworks/base change:
  I35afe38646f04d2ba0dbac11c2c6356120a33694

Bug:15831713
Change-Id: I6ed56791784968adfbd684f490dbbebed285a2dd
This commit is contained in:
John Spurlock
2014-07-05 12:57:08 -04:00
parent 5fc8214555
commit 07f7efba67
18 changed files with 521 additions and 619 deletions

View File

@@ -60,7 +60,7 @@ public class SettingPref {
throw new UnsupportedOperationException();
}
public void init(SettingsPreferenceFragment settings) {
public Preference init(SettingsPreferenceFragment settings) {
final Context context = settings.getActivity();
Preference p = settings.getPreferenceScreen().findPreference(mKey);
if (p != null && !isApplicable(context)) {
@@ -84,14 +84,18 @@ public class SettingPref {
return true;
}
});
} else if (mDropDown != null) {
return mTwoState;
}
if (mDropDown != null) {
mDropDown.setCallback(new DropDownPreference.Callback() {
@Override
public boolean onItemSelected(int pos, Object value) {
return setSetting(context, (Integer) value);
}
});
return mDropDown;
}
return null;
}
protected boolean setSetting(Context context, int value) {