Don't transition to ongoing privacy dot if still animating

If privacy events come in very fast (during the debounce time), we
sometimes would transition to showing the ongoing privacy event dot
before the animation finished.

Test: manual
Fixes: 222554701
Change-Id: I270e0180655eb2a6254a17ce6f18f0fd4a77b081
This commit is contained in:
Evan Laird
2022-03-07 15:49:38 -05:00
parent 3900e2887b
commit b6d298a4d5

View File

@@ -116,7 +116,10 @@ class SystemStatusAnimationScheduler @Inject constructor(
scheduledEvent?.updateFromEvent(event)
if (event.forceVisible) {
hasPersistentDot = true
notifyTransitionToPersistentDot()
// If we missed the chance to show the persistent dot, do it now
if (animationState == IDLE) {
notifyTransitionToPersistentDot()
}
}
} else {
if (DEBUG) {