summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Pavel Grafov <pgrafov@google.com> 2023-07-27 17:14:47 +0000
committer Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> 2023-07-27 17:14:47 +0000
commit276d752a5d205c945fcc42daee29cc54dce9046a (patch)
treef54361f135d898fcbd9a4c1091d6805de1d50799
parent7cce89bb4507dde505eb0ca3c9440821774ecef5 (diff)
parentb39bfaf35a33f4388193a8eeb740d953fc37bcfc (diff)
Merge "Clarify reasons for notification removal." into udc-dev am: ebf1af8511 am: b39bfaf35a
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/24211145 Change-Id: I003e729b41fe82a2ee9e15416934c8b81a2187cc Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
-rw-r--r--core/java/android/service/notification/NotificationListenerService.java12
1 files changed, 1 insertions, 11 deletions
diff --git a/core/java/android/service/notification/NotificationListenerService.java b/core/java/android/service/notification/NotificationListenerService.java
index 1d49049ab7d4..07f8aac43bf5 100644
--- a/core/java/android/service/notification/NotificationListenerService.java
+++ b/core/java/android/service/notification/NotificationListenerService.java
@@ -485,9 +485,6 @@ public abstract class NotificationListenerService extends Service {
/**
* Implement this method to learn when notifications are removed.
* <p>
- * This might occur because the user has dismissed the notification using system UI (or another
- * notification listener) or because the app has withdrawn the notification.
- * <p>
* NOTE: The {@link StatusBarNotification} object you receive will be "light"; that is, the
* result from {@link StatusBarNotification#getNotification} may be missing some heavyweight
* fields such as {@link android.app.Notification#contentView} and
@@ -506,9 +503,6 @@ public abstract class NotificationListenerService extends Service {
/**
* Implement this method to learn when notifications are removed.
* <p>
- * This might occur because the user has dismissed the notification using system UI (or another
- * notification listener) or because the app has withdrawn the notification.
- * <p>
* NOTE: The {@link StatusBarNotification} object you receive will be "light"; that is, the
* result from {@link StatusBarNotification#getNotification} may be missing some heavyweight
* fields such as {@link android.app.Notification#contentView} and
@@ -531,9 +525,6 @@ public abstract class NotificationListenerService extends Service {
/**
* Implement this method to learn when notifications are removed and why.
* <p>
- * This might occur because the user has dismissed the notification using system UI (or another
- * notification listener) or because the app has withdrawn the notification.
- * <p>
* NOTE: The {@link StatusBarNotification} object you receive will be "light"; that is, the
* result from {@link StatusBarNotification#getNotification} may be missing some heavyweight
* fields such as {@link android.app.Notification#contentView} and
@@ -546,10 +537,9 @@ public abstract class NotificationListenerService extends Service {
* was just removed.
* @param rankingMap The current ranking map that can be used to retrieve ranking information
* for active notifications.
- * @param reason see {@link #REASON_LISTENER_CANCEL}, etc.
*/
public void onNotificationRemoved(StatusBarNotification sbn, RankingMap rankingMap,
- int reason) {
+ @NotificationCancelReason int reason) {
onNotificationRemoved(sbn, rankingMap);
}