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

Commit 1d86b617 authored by Sam Mortimer's avatar Sam Mortimer Committed by Steve Kondik
Browse files

Don't lookup application keyguard notification visibility unnecessarily

Change-Id: I7a70f2c9d9e813c71544f2446c9bc6502f061c4f
parent 48cb3d09
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -1821,6 +1821,9 @@ public abstract class BaseStatusBar extends SystemUI implements
    }

    private boolean shouldShowOnKeyguard(StatusBarNotification sbn) {
        if (!mShowLockscreenNotifications || mNotificationData.isAmbient(sbn.getKey())) {
            return false;
        }
        final int showOnKeyguard = mNoMan.getShowNotificationForPackageOnKeyguard(
                sbn.getPackageName(), sbn.getUid());
        boolean isKeyguardAllowedForApp =
@@ -1829,8 +1832,7 @@ public abstract class BaseStatusBar extends SystemUI implements
            isKeyguardAllowedForApp =
                    (showOnKeyguard & Notification.SHOW_NO_ONGOING_NOTI_ON_KEYGUARD) == 0;
        }
        return mShowLockscreenNotifications && !mNotificationData.isAmbient(sbn.getKey())
                && isKeyguardAllowedForApp;
        return isKeyguardAllowedForApp;
    }

    protected void setZenMode(int mode) {