From 0da673f02e542c644c300568807c80e196296860 Mon Sep 17 00:00:00 2001 From: Daniel Sandler Date: Wed, 11 Apr 2012 12:33:16 -0400 Subject: Notifications may now be disabled on a per-package basis. When a package's ability to post notifications is disabled, all outstanding notifications from that package are immediately canceled, and the score of any future notification from that package is set so low that the notification manager won't even send it to the status bar. No UI for this yet, but you can try it out: adb shell service call notification 8 s16 $PKG i32 (1|0) Bug: 5547401 Change-Id: Ieccac5746b40f60debd902a45d1dedbc91dcdc89 --- core/java/android/app/INotificationManager.aidl | 3 +++ 1 file changed, 3 insertions(+) (limited to 'core/java/android') diff --git a/core/java/android/app/INotificationManager.aidl b/core/java/android/app/INotificationManager.aidl index 4d5238c..6f95e26 100644 --- a/core/java/android/app/INotificationManager.aidl +++ b/core/java/android/app/INotificationManager.aidl @@ -34,5 +34,8 @@ interface INotificationManager void cancelToast(String pkg, ITransientNotification callback); void enqueueNotificationWithTag(String pkg, String tag, int id, in Notification notification, inout int[] idReceived); void cancelNotificationWithTag(String pkg, String tag, int id); + + void setNotificationsEnabledForPackage(String pkg, boolean enabled); + boolean areNotificationsEnabledForPackage(String pkg); } -- cgit v1.1