diff options
3 files changed, 4 insertions, 3 deletions
diff --git a/packages/SystemUI/multivalentTests/src/com/android/systemui/statusbar/NotificationLockscreenUserManagerTest.java b/packages/SystemUI/multivalentTests/src/com/android/systemui/statusbar/NotificationLockscreenUserManagerTest.java index deaf57999b21..0713a247a4a3 100644 --- a/packages/SystemUI/multivalentTests/src/com/android/systemui/statusbar/NotificationLockscreenUserManagerTest.java +++ b/packages/SystemUI/multivalentTests/src/com/android/systemui/statusbar/NotificationLockscreenUserManagerTest.java @@ -225,6 +225,7 @@ public class NotificationLockscreenUserManagerTest extends SysuiTestCase { Notification notifWithPrivateVisibility = new Notification(); notifWithPrivateVisibility.visibility = VISIBILITY_PRIVATE; + notifWithPrivateVisibility.when = System.currentTimeMillis(); mCurrentUserNotif = new NotificationEntryBuilder() .setNotification(notifWithPrivateVisibility) .setUser(new UserHandle(mCurrentUser.id)) @@ -260,7 +261,7 @@ public class NotificationLockscreenUserManagerTest extends SysuiTestCase { .setChannel(channel) .setSensitiveContent(true) .setVisibilityOverride(VISIBILITY_NO_OVERRIDE).build()); - mSensitiveNotifPostTime = mSensitiveContentNotif.getSbn().getPostTime(); + mSensitiveNotifPostTime = mSensitiveContentNotif.getSbn().getNotification().getWhen(); when(mNotifCollection.getEntry(mWorkProfileNotif.getKey())).thenReturn(mWorkProfileNotif); when(mKeyguardInteractorLazy.get()).thenReturn(mKeyguardInteractor); when(mKeyguardInteractor.isKeyguardDismissible()) diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationLockscreenUserManagerImpl.java b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationLockscreenUserManagerImpl.java index 10b726b90894..c8f972774ab0 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationLockscreenUserManagerImpl.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationLockscreenUserManagerImpl.java @@ -121,7 +121,6 @@ public class NotificationLockscreenUserManagerImpl implements private static final long LOCK_TIME_FOR_SENSITIVE_REDACTION_MS = TimeUnit.MINUTES.toMillis(10); - private final Lazy<NotificationVisibilityProvider> mVisibilityProviderLazy; private final Lazy<CommonNotifCollection> mCommonNotifCollectionLazy; private final DevicePolicyManager mDevicePolicyManager; @@ -751,7 +750,7 @@ public class NotificationLockscreenUserManagerImpl implements } long lastLockedTime = mLastLockTime.get(); - if (ent.getSbn().getPostTime() < lastLockedTime) { + if (ent.getSbn().getNotification().getWhen() < lastLockedTime) { return false; } diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/NotificationRowContentBinderImpl.kt b/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/NotificationRowContentBinderImpl.kt index 49e38def98a6..0b299d965b09 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/NotificationRowContentBinderImpl.kt +++ b/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/NotificationRowContentBinderImpl.kt @@ -799,6 +799,7 @@ constructor( } redacted.setLargeIcon(original.getLargeIcon()) redacted.setSmallIcon(original.smallIcon) + redacted.setWhen(original.getWhen()) return redacted } |