Loading packages/SystemUI/src/com/android/systemui/statusbar/policy/AvalancheController.kt +17 −11 Original line number Diff line number Diff line Loading @@ -37,7 +37,8 @@ import javax.inject.Inject @SysUISingleton class AvalancheController @Inject constructor(dumpManager: DumpManager, constructor( dumpManager: DumpManager, private val uiEventLogger: UiEventLogger, @Background private val bgHandler: Handler ) : Dumpable { Loading @@ -53,6 +54,9 @@ constructor(dumpManager: DumpManager, logDroppedHunsInBackground(getWaitingKeys().size) clearNext() } if (field != value) { field = value } } // HUN showing right now, in the floating state where full shade is hidden, on launcher or AOD Loading Loading @@ -110,7 +114,7 @@ constructor(dumpManager: DumpManager, log { "Runnable is NULL, stop update." } return } if (!NotificationThrottleHun.isEnabled) { if (!isEnabled()) { runnable.run() return } Loading Loading @@ -170,7 +174,7 @@ constructor(dumpManager: DumpManager, log { "Runnable is NULL, stop delete." } return } if (!NotificationThrottleHun.isEnabled) { if (!isEnabled()) { runnable.run() return } Loading Loading @@ -356,12 +360,14 @@ constructor(dumpManager: DumpManager, } private fun logDroppedHunsInBackground(numDropped: Int) { bgHandler.post(Runnable { bgHandler.post( Runnable { // Do this in the background to avoid missing frames when closing the shade for (n in 1..numDropped) { uiEventLogger.log(ThrottleEvent.AVALANCHE_THROTTLING_HUN_DROPPED) } }) } ) } fun clearNext() { Loading Loading
packages/SystemUI/src/com/android/systemui/statusbar/policy/AvalancheController.kt +17 −11 Original line number Diff line number Diff line Loading @@ -37,7 +37,8 @@ import javax.inject.Inject @SysUISingleton class AvalancheController @Inject constructor(dumpManager: DumpManager, constructor( dumpManager: DumpManager, private val uiEventLogger: UiEventLogger, @Background private val bgHandler: Handler ) : Dumpable { Loading @@ -53,6 +54,9 @@ constructor(dumpManager: DumpManager, logDroppedHunsInBackground(getWaitingKeys().size) clearNext() } if (field != value) { field = value } } // HUN showing right now, in the floating state where full shade is hidden, on launcher or AOD Loading Loading @@ -110,7 +114,7 @@ constructor(dumpManager: DumpManager, log { "Runnable is NULL, stop update." } return } if (!NotificationThrottleHun.isEnabled) { if (!isEnabled()) { runnable.run() return } Loading Loading @@ -170,7 +174,7 @@ constructor(dumpManager: DumpManager, log { "Runnable is NULL, stop delete." } return } if (!NotificationThrottleHun.isEnabled) { if (!isEnabled()) { runnable.run() return } Loading Loading @@ -356,12 +360,14 @@ constructor(dumpManager: DumpManager, } private fun logDroppedHunsInBackground(numDropped: Int) { bgHandler.post(Runnable { bgHandler.post( Runnable { // Do this in the background to avoid missing frames when closing the shade for (n in 1..numDropped) { uiEventLogger.log(ThrottleEvent.AVALANCHE_THROTTLING_HUN_DROPPED) } }) } ) } fun clearNext() { Loading