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

Commit ce2e23ff authored by Christoph Studer's avatar Christoph Studer
Browse files

NoMan: Fix speedbump when no low-prio notifs

Bug: 16705179
Change-Id: I32329710c27052c35b64ba91759200341ed0b127
parent e5aa75ca
Loading
Loading
Loading
Loading
+5 −1
Original line number Original line Diff line number Diff line
@@ -609,8 +609,12 @@ public abstract class NotificationListenerService extends Service {
        }
        }


        private boolean isAmbient(String key) {
        private boolean isAmbient(String key) {
            int firstAmbientIndex = mRankingUpdate.getFirstAmbientIndex();
            if (firstAmbientIndex < 0) {
                return false;
            }
            int rank = getRank(key);
            int rank = getRank(key);
            return rank >= 0 && rank >= mRankingUpdate.getFirstAmbientIndex();
            return rank >= 0 && rank >= firstAmbientIndex;
        }
        }


        private boolean isIntercepted(String key) {
        private boolean isIntercepted(String key) {
+1 −2
Original line number Original line Diff line number Diff line
@@ -1422,8 +1422,7 @@ public abstract class BaseStatusBar extends SystemUI implements
    }
    }


    private boolean shouldShowOnKeyguard(StatusBarNotification sbn) {
    private boolean shouldShowOnKeyguard(StatusBarNotification sbn) {
        return mShowLockscreenNotifications &&
        return mShowLockscreenNotifications && !mNotificationData.isAmbient(sbn.getKey());
                sbn.getNotification().priority >= Notification.PRIORITY_LOW;
    }
    }


    protected void setZenMode(int mode) {
    protected void setZenMode(int mode) {