Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 6cb20df2 authored by Mady Mellor's avatar Mady Mellor
Browse files

Add notion of bubble to NotificationData

- indicate if an entry is a bubble
- indicate if an entry is a bubble that has been dismissed

Test: none
Bug: 111236845
Change-Id: I81a3ed92d438eb849995f80ed2ef2a3995c1cefe
parent 6497f530
Loading
Loading
Loading
Loading
+26 −0
Original line number Diff line number Diff line
@@ -142,6 +142,16 @@ public class NotificationData {
         */
        private boolean hasSentReply;

        /**
         * Whether this notification should be displayed as a bubble.
         */
        private boolean mIsBubble;

        /**
         * Whether the user has dismissed this notification when it was in bubble form.
         */
        private boolean mUserDismissedBubble;

        public Entry(StatusBarNotification n) {
            this(n, null);
        }
@@ -176,6 +186,22 @@ public class NotificationData {
            return interruption;
        }

        public void setIsBubble(boolean bubbleable) {
            mIsBubble = bubbleable;
        }

        public boolean isBubble() {
            return mIsBubble;
        }

        public void setBubbleDismissed(boolean userDismissed) {
            mUserDismissedBubble = userDismissed;
        }

        public boolean isBubbleDismissed() {
            return mUserDismissedBubble;
        }

        /**
         * Resets the notification entry to be re-used.
         */