Loading packages/SystemUI/src/com/android/systemui/statusbar/policy/AvalancheController.kt +7 −2 Original line number Diff line number Diff line Loading @@ -54,6 +54,7 @@ constructor( // allowed again. logDroppedHunsInBackground(getWaitingKeys().size) clearNext() headsUpEntryShowing = null } if (field != value) { field = value Loading Loading @@ -226,11 +227,15 @@ constructor( * 2) The priority of the top HUN in the next batch Used by * BaseHeadsUpManager.HeadsUpEntry.calculateFinishTime to shorten display duration. */ fun getDurationMs(entry: HeadsUpEntry, autoDismissMs: Int): Int { fun getDurationMs(entry: HeadsUpEntry?, autoDismissMs: Int): Int { if (!isEnabled()) { // Use default duration, like we did before AvalancheController existed return autoDismissMs } if (entry == null) { // This should never happen return autoDismissMs } val showingList: MutableList<HeadsUpEntry> = mutableListOf() if (headsUpEntryShowing != null) { showingList.add(headsUpEntryShowing!!) Loading packages/SystemUI/src/com/android/systemui/statusbar/policy/BaseHeadsUpManager.java +9 −0 Original line number Diff line number Diff line Loading @@ -344,6 +344,15 @@ public abstract class BaseHeadsUpManager implements HeadsUpManager { } protected boolean hasFullScreenIntent(@NonNull NotificationEntry entry) { if (entry == null) { return false; } if (entry.getSbn() == null) { return false; } if (entry.getSbn().getNotification() == null) { return false; } return entry.getSbn().getNotification().fullScreenIntent != null; } Loading Loading
packages/SystemUI/src/com/android/systemui/statusbar/policy/AvalancheController.kt +7 −2 Original line number Diff line number Diff line Loading @@ -54,6 +54,7 @@ constructor( // allowed again. logDroppedHunsInBackground(getWaitingKeys().size) clearNext() headsUpEntryShowing = null } if (field != value) { field = value Loading Loading @@ -226,11 +227,15 @@ constructor( * 2) The priority of the top HUN in the next batch Used by * BaseHeadsUpManager.HeadsUpEntry.calculateFinishTime to shorten display duration. */ fun getDurationMs(entry: HeadsUpEntry, autoDismissMs: Int): Int { fun getDurationMs(entry: HeadsUpEntry?, autoDismissMs: Int): Int { if (!isEnabled()) { // Use default duration, like we did before AvalancheController existed return autoDismissMs } if (entry == null) { // This should never happen return autoDismissMs } val showingList: MutableList<HeadsUpEntry> = mutableListOf() if (headsUpEntryShowing != null) { showingList.add(headsUpEntryShowing!!) Loading
packages/SystemUI/src/com/android/systemui/statusbar/policy/BaseHeadsUpManager.java +9 −0 Original line number Diff line number Diff line Loading @@ -344,6 +344,15 @@ public abstract class BaseHeadsUpManager implements HeadsUpManager { } protected boolean hasFullScreenIntent(@NonNull NotificationEntry entry) { if (entry == null) { return false; } if (entry.getSbn() == null) { return false; } if (entry.getSbn().getNotification() == null) { return false; } return entry.getSbn().getNotification().fullScreenIntent != null; } Loading