Zen: Simplify notification policy api, add zenmode api.
- Remove the concept of a notification policy management token
in favor of a simple grant/deny per app. Currently, all requests
are immediately granted.
- Add zen mode getter/setting, limit to apps that have been granted
policy access.
- Add intent for zen mode changes.
- Public name for zen mode = "interruption filter", moved from
NotificationListenerService to NotificationManager.
- Add settings metadata for new DND access Settings screen.
- Add the split sender settings for calls vs messages to the public
Policy api.
- This change is meant to finalize the public api, persisting
granted app status and showing the user-visible dialog will be
done as followups.
Bug: 18298798
Change-Id: I511be98d69939f057c0c7dc1a6dfe63d1c468193
diff --git a/core/java/android/provider/Settings.java b/core/java/android/provider/Settings.java
index 7c3c11b..dc70d7b 100644
--- a/core/java/android/provider/Settings.java
+++ b/core/java/android/provider/Settings.java
@@ -809,6 +809,18 @@
= "android.settings.ACTION_NOTIFICATION_LISTENER_SETTINGS";
/**
+ * Activity Action: Show Do Not Disturb access settings.
+ * <p>
+ * In some cases, a matching Activity may not exist, so ensure you safeguard against this.
+ * <p>
+ * Input: Nothing.
+ * <p>
+ * Output: Nothing.
+ */
+ @SdkConstant(SdkConstantType.ACTIVITY_INTENT_ACTION)
+ public static final String ACTION_ZEN_ACCESS_SETTINGS = "android.settings.ZEN_ACCESS_SETTINGS";
+
+ /**
* @hide
*/
@SdkConstant(SdkConstantType.ACTIVITY_INTENT_ACTION)