Loading packages/SystemUI/src/com/android/systemui/statusbar/notification/NotificationEntryManager.java +11 −10 Original line number Diff line number Diff line Loading @@ -35,7 +35,6 @@ import com.android.systemui.Dependency; import com.android.systemui.Dumpable; import com.android.systemui.ForegroundServiceController; import com.android.systemui.bubbles.BubbleController; import com.android.systemui.statusbar.AmbientPulseManager; import com.android.systemui.statusbar.NotificationLifetimeExtender; import com.android.systemui.statusbar.NotificationPresenter; import com.android.systemui.statusbar.NotificationRemoteInputManager; Loading Loading @@ -83,8 +82,6 @@ public class NotificationEntryManager implements Dependency.get(DeviceProvisionedController.class); private final ForegroundServiceController mForegroundServiceController = Dependency.get(ForegroundServiceController.class); private final AmbientPulseManager mAmbientPulseManager = Dependency.get(AmbientPulseManager.class); private final BubbleController mBubbleController = Dependency.get(BubbleController.class); // Lazily retrieved dependencies Loading Loading @@ -170,16 +167,20 @@ public class NotificationEntryManager implements mNotificationData.setHeadsUpManager(mHeadsUpManager); mListContainer = listContainer; mNotificationLifetimeExtenders.add(mHeadsUpManager); mNotificationLifetimeExtenders.add(mAmbientPulseManager); mNotificationLifetimeExtenders.add(mGutsManager); mNotificationLifetimeExtenders.addAll(getRemoteInputManager().getLifetimeExtenders()); mDeviceProvisionedController.addCallback(mDeviceProvisionedListener); } for (NotificationLifetimeExtender extender : mNotificationLifetimeExtenders) { extender.setCallback(key -> removeNotification(key, mLatestRankingMap)); /** Adds multiple {@link NotificationLifetimeExtender}s. */ public void addNotificationLifetimeExtenders(List<NotificationLifetimeExtender> extenders) { for (NotificationLifetimeExtender extender : extenders) { addNotificationLifetimeExtender(extender); } } mDeviceProvisionedController.addCallback(mDeviceProvisionedListener); /** Adds a {@link NotificationLifetimeExtender}. */ public void addNotificationLifetimeExtender(NotificationLifetimeExtender extender) { mNotificationLifetimeExtenders.add(extender); extender.setCallback(key -> removeNotification(key, mLatestRankingMap)); } public NotificationData getNotificationData() { Loading packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarNotificationPresenter.java +8 −1 Original line number Diff line number Diff line Loading @@ -208,9 +208,16 @@ public class StatusBarNotificationPresenter implements NotificationPresenter, } }; NotificationGutsManager gutsManager = Dependency.get(NotificationGutsManager.class); mViewHierarchyManager.setUpWithPresenter(this, notifListContainer); mEntryManager.setUpWithPresenter(this, notifListContainer, mHeadsUpManager); mEntryManager.addNotificationEntryListener(notificationEntryListener); mEntryManager.addNotificationLifetimeExtender(mHeadsUpManager); mEntryManager.addNotificationLifetimeExtender(mAmbientPulseManager); mEntryManager.addNotificationLifetimeExtender(gutsManager); mEntryManager.addNotificationLifetimeExtenders( remoteInputManager.getLifetimeExtenders()); mNotificationRowBinder.setUpWithPresenter(this, notifListContainer, mHeadsUpManager, mEntryManager, this); mNotificationInterruptionStateProvider.setUpWithPresenter( Loading @@ -218,7 +225,7 @@ public class StatusBarNotificationPresenter implements NotificationPresenter, mLockscreenUserManager.setUpWithPresenter(this); mMediaManager.setUpWithPresenter(this); mVisualStabilityManager.setUpWithPresenter(this); Dependency.get(NotificationGutsManager.class).setUpWithPresenter(this, gutsManager.setUpWithPresenter(this, notifListContainer, mCheckSaveListener, mOnSettingsClickListener); onUserSwitched(mLockscreenUserManager.getCurrentUserId()); Loading Loading
packages/SystemUI/src/com/android/systemui/statusbar/notification/NotificationEntryManager.java +11 −10 Original line number Diff line number Diff line Loading @@ -35,7 +35,6 @@ import com.android.systemui.Dependency; import com.android.systemui.Dumpable; import com.android.systemui.ForegroundServiceController; import com.android.systemui.bubbles.BubbleController; import com.android.systemui.statusbar.AmbientPulseManager; import com.android.systemui.statusbar.NotificationLifetimeExtender; import com.android.systemui.statusbar.NotificationPresenter; import com.android.systemui.statusbar.NotificationRemoteInputManager; Loading Loading @@ -83,8 +82,6 @@ public class NotificationEntryManager implements Dependency.get(DeviceProvisionedController.class); private final ForegroundServiceController mForegroundServiceController = Dependency.get(ForegroundServiceController.class); private final AmbientPulseManager mAmbientPulseManager = Dependency.get(AmbientPulseManager.class); private final BubbleController mBubbleController = Dependency.get(BubbleController.class); // Lazily retrieved dependencies Loading Loading @@ -170,16 +167,20 @@ public class NotificationEntryManager implements mNotificationData.setHeadsUpManager(mHeadsUpManager); mListContainer = listContainer; mNotificationLifetimeExtenders.add(mHeadsUpManager); mNotificationLifetimeExtenders.add(mAmbientPulseManager); mNotificationLifetimeExtenders.add(mGutsManager); mNotificationLifetimeExtenders.addAll(getRemoteInputManager().getLifetimeExtenders()); mDeviceProvisionedController.addCallback(mDeviceProvisionedListener); } for (NotificationLifetimeExtender extender : mNotificationLifetimeExtenders) { extender.setCallback(key -> removeNotification(key, mLatestRankingMap)); /** Adds multiple {@link NotificationLifetimeExtender}s. */ public void addNotificationLifetimeExtenders(List<NotificationLifetimeExtender> extenders) { for (NotificationLifetimeExtender extender : extenders) { addNotificationLifetimeExtender(extender); } } mDeviceProvisionedController.addCallback(mDeviceProvisionedListener); /** Adds a {@link NotificationLifetimeExtender}. */ public void addNotificationLifetimeExtender(NotificationLifetimeExtender extender) { mNotificationLifetimeExtenders.add(extender); extender.setCallback(key -> removeNotification(key, mLatestRankingMap)); } public NotificationData getNotificationData() { Loading
packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarNotificationPresenter.java +8 −1 Original line number Diff line number Diff line Loading @@ -208,9 +208,16 @@ public class StatusBarNotificationPresenter implements NotificationPresenter, } }; NotificationGutsManager gutsManager = Dependency.get(NotificationGutsManager.class); mViewHierarchyManager.setUpWithPresenter(this, notifListContainer); mEntryManager.setUpWithPresenter(this, notifListContainer, mHeadsUpManager); mEntryManager.addNotificationEntryListener(notificationEntryListener); mEntryManager.addNotificationLifetimeExtender(mHeadsUpManager); mEntryManager.addNotificationLifetimeExtender(mAmbientPulseManager); mEntryManager.addNotificationLifetimeExtender(gutsManager); mEntryManager.addNotificationLifetimeExtenders( remoteInputManager.getLifetimeExtenders()); mNotificationRowBinder.setUpWithPresenter(this, notifListContainer, mHeadsUpManager, mEntryManager, this); mNotificationInterruptionStateProvider.setUpWithPresenter( Loading @@ -218,7 +225,7 @@ public class StatusBarNotificationPresenter implements NotificationPresenter, mLockscreenUserManager.setUpWithPresenter(this); mMediaManager.setUpWithPresenter(this); mVisualStabilityManager.setUpWithPresenter(this); Dependency.get(NotificationGutsManager.class).setUpWithPresenter(this, gutsManager.setUpWithPresenter(this, notifListContainer, mCheckSaveListener, mOnSettingsClickListener); onUserSwitched(mLockscreenUserManager.getCurrentUserId()); Loading