Add a little bit of documentation on summary vs. stacked notifications

This commit is contained in:
cketti 2015-09-25 00:31:09 +02:00
parent 5bbb7b7164
commit ae092e1c6e
2 changed files with 10 additions and 1 deletions

View file

@ -12,6 +12,16 @@ import com.fsck.k9.activity.MessageReference;
import com.fsck.k9.mailstore.LocalMessage;
/**
* Handle notifications for new messages.
* <p>
* We call the notification shown on the device <em>summary notification</em>, even when there's only one new message.
* Notifications on an Android Wear device are displayed as a stack of cards and that's why we call them <em>stacked
* notifications</em>. We have to keep track of stacked notifications individually and recreate/update the summary
* notification when one or more of the stacked notifications are added/removed.<br>
* {@link NotificationData} keeps track of all data required to (re)create the actual system notifications.
* </p>
*/
class NewMailNotifications {
private final NotificationController controller;
private final NotificationContentCreator contentCreator;

View file

@ -131,7 +131,6 @@ class WearNotifications extends BaseNotifications {
int icon = R.drawable.ic_action_mark_as_read_dark;
String title = context.getString(R.string.notification_action_mark_as_read);
MessageReference messageReference = holder.content.messageReference;
int notificationId = holder.notificationId;
PendingIntent action = actionCreator.createMarkMessageAsReadPendingIntent(messageReference, notificationId);