Merge "If zen settings are updated, don't show onboarding" into pi-dev

am: aaac61eb5e

Change-Id: I96929a31ab8f644f83db74ce12b201bd0852c782
This commit is contained in:
Beverly
2018-06-06 18:34:25 -07:00
committed by android-build-merger
2 changed files with 38 additions and 4 deletions

View File

@@ -156,6 +156,12 @@ public class ZenOnboardingActivity extends Activity {
// ZEN_SETTINGS_UPDATED is true for:
// - fresh P+ device
// - if zen visual effects values were changed by the user in Settings
NotificationManager nm = context.getSystemService(NotificationManager.class);
if (NotificationManager.Policy.areAllVisualEffectsSuppressed(
nm.getNotificationPolicy().suppressedVisualEffects)) {
Settings.Global.putInt(context.getContentResolver(),
Settings.Global.ZEN_SETTINGS_UPDATED, 1);
}
return Settings.Global.getInt(context.getContentResolver(),
Settings.Global.ZEN_SETTINGS_UPDATED, 0) != 0;
}