Loading packages/SystemUI/src/com/android/systemui/keyguard/KeyguardUnlockAnimationController.kt +1 −1 Original line number Diff line number Diff line Loading @@ -933,7 +933,7 @@ class KeyguardUnlockAnimationController @Inject constructor( } // The smartspace is not visible if the bouncer is showing, so don't shared element it. if (keyguardStateController.isBouncerShowing) { if (keyguardStateController.isPrimaryBouncerShowing) { return false } Loading packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java +3 −3 Original line number Diff line number Diff line Loading @@ -1148,12 +1148,12 @@ public class KeyguardViewMediator implements CoreStartable, Dumpable, private final KeyguardStateController.Callback mKeyguardStateControllerCallback = new KeyguardStateController.Callback() { @Override public void onBouncerShowingChanged() { public void onPrimaryBouncerShowingChanged() { synchronized (KeyguardViewMediator.this) { if (mKeyguardStateController.isBouncerShowing()) { if (mKeyguardStateController.isPrimaryBouncerShowing()) { mPendingPinLock = false; } adjustStatusBarLocked(mKeyguardStateController.isBouncerShowing(), false); adjustStatusBarLocked(mKeyguardStateController.isPrimaryBouncerShowing(), false); } } }; Loading packages/SystemUI/src/com/android/systemui/keyguard/data/repository/KeyguardBouncerRepository.kt +11 −11 Original line number Diff line number Diff line Loading @@ -68,8 +68,8 @@ interface KeyguardBouncerRepository { val resourceUpdateRequests: StateFlow<Boolean> val bouncerPromptReason: Int val bouncerErrorMessage: CharSequence? val isAlternateBouncerVisible: StateFlow<Boolean> val isAlternateBouncerUIAvailable: StateFlow<Boolean> val alternateBouncerVisible: StateFlow<Boolean> val alternateBouncerUIAvailable: StateFlow<Boolean> var lastAlternateBouncerVisibleTime: Long fun setPrimaryScrimmed(isScrimmed: Boolean) Loading Loading @@ -159,12 +159,12 @@ constructor( get() = viewMediatorCallback.consumeCustomMessage() /** Values associated with the AlternateBouncer */ private val _isAlternateBouncerVisible = MutableStateFlow(false) override val isAlternateBouncerVisible = _isAlternateBouncerVisible.asStateFlow() private val _alternateBouncerVisible = MutableStateFlow(false) override val alternateBouncerVisible = _alternateBouncerVisible.asStateFlow() override var lastAlternateBouncerVisibleTime: Long = NOT_VISIBLE private val _isAlternateBouncerUIAvailable = MutableStateFlow(false) override val isAlternateBouncerUIAvailable: StateFlow<Boolean> = _isAlternateBouncerUIAvailable.asStateFlow() private val _alternateBouncerUIAvailable = MutableStateFlow(false) override val alternateBouncerUIAvailable: StateFlow<Boolean> = _alternateBouncerUIAvailable.asStateFlow() init { setUpLogging() Loading @@ -179,16 +179,16 @@ constructor( } override fun setAlternateVisible(isVisible: Boolean) { if (isVisible && !_isAlternateBouncerVisible.value) { if (isVisible && !_alternateBouncerVisible.value) { lastAlternateBouncerVisibleTime = clock.uptimeMillis() } else if (!isVisible) { lastAlternateBouncerVisibleTime = NOT_VISIBLE } _isAlternateBouncerVisible.value = isVisible _alternateBouncerVisible.value = isVisible } override fun setAlternateBouncerUIAvailable(isAvailable: Boolean) { _isAlternateBouncerUIAvailable.value = isAvailable _alternateBouncerUIAvailable.value = isAvailable } override fun setPrimaryShow(keyguardBouncerModel: KeyguardBouncerModel?) { Loading Loading @@ -290,7 +290,7 @@ constructor( resourceUpdateRequests .logDiffsForTable(buffer, "", "ResourceUpdateRequests", false) .launchIn(applicationScope) isAlternateBouncerUIAvailable alternateBouncerUIAvailable .logDiffsForTable(buffer, "", "IsAlternateBouncerUIAvailable", false) .launchIn(applicationScope) } Loading packages/SystemUI/src/com/android/systemui/keyguard/data/repository/KeyguardRepository.kt +0 −26 Original line number Diff line number Diff line Loading @@ -86,9 +86,6 @@ interface KeyguardRepository { /** Observable for the signal that keyguard is about to go away. */ val isKeyguardGoingAway: Flow<Boolean> /** Observable for whether the bouncer is showing. */ val isBouncerShowing: Flow<Boolean> /** Is the always-on display available to be used? */ val isAodAvailable: Flow<Boolean> Loading Loading @@ -304,29 +301,6 @@ constructor( awaitClose { keyguardStateController.removeCallback(callback) } } override val isBouncerShowing: Flow<Boolean> = conflatedCallbackFlow { val callback = object : KeyguardStateController.Callback { override fun onBouncerShowingChanged() { trySendWithFailureLogging( keyguardStateController.isBouncerShowing, TAG, "updated isBouncerShowing" ) } } keyguardStateController.addCallback(callback) // Adding the callback does not send an initial update. trySendWithFailureLogging( keyguardStateController.isBouncerShowing, TAG, "initial isBouncerShowing" ) awaitClose { keyguardStateController.removeCallback(callback) } } override val isDozing: Flow<Boolean> = conflatedCallbackFlow { val callback = Loading packages/SystemUI/src/com/android/systemui/keyguard/domain/interactor/AlternateBouncerInteractor.kt +3 −3 Original line number Diff line number Diff line Loading @@ -44,7 +44,7 @@ constructor( var legacyAlternateBouncer: LegacyAlternateBouncer? = null var legacyAlternateBouncerVisibleTime: Long = NOT_VISIBLE val isVisible: Flow<Boolean> = bouncerRepository.isAlternateBouncerVisible val isVisible: Flow<Boolean> = bouncerRepository.alternateBouncerVisible /** * Sets the correct bouncer states to show the alternate bouncer if it can show. Loading Loading @@ -86,7 +86,7 @@ constructor( fun isVisibleState(): Boolean { return if (isModernAlternateBouncerEnabled) { bouncerRepository.isAlternateBouncerVisible.value bouncerRepository.alternateBouncerVisible.value } else { legacyAlternateBouncer?.isShowingAlternateBouncer ?: false } Loading @@ -98,7 +98,7 @@ constructor( fun canShowAlternateBouncerForFingerprint(): Boolean { return if (isModernAlternateBouncerEnabled) { bouncerRepository.isAlternateBouncerUIAvailable.value && bouncerRepository.alternateBouncerUIAvailable.value && biometricSettingsRepository.isFingerprintEnrolled.value && biometricSettingsRepository.isStrongBiometricAllowed.value && biometricSettingsRepository.isFingerprintEnabledByDevicePolicy.value && Loading Loading
packages/SystemUI/src/com/android/systemui/keyguard/KeyguardUnlockAnimationController.kt +1 −1 Original line number Diff line number Diff line Loading @@ -933,7 +933,7 @@ class KeyguardUnlockAnimationController @Inject constructor( } // The smartspace is not visible if the bouncer is showing, so don't shared element it. if (keyguardStateController.isBouncerShowing) { if (keyguardStateController.isPrimaryBouncerShowing) { return false } Loading
packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java +3 −3 Original line number Diff line number Diff line Loading @@ -1148,12 +1148,12 @@ public class KeyguardViewMediator implements CoreStartable, Dumpable, private final KeyguardStateController.Callback mKeyguardStateControllerCallback = new KeyguardStateController.Callback() { @Override public void onBouncerShowingChanged() { public void onPrimaryBouncerShowingChanged() { synchronized (KeyguardViewMediator.this) { if (mKeyguardStateController.isBouncerShowing()) { if (mKeyguardStateController.isPrimaryBouncerShowing()) { mPendingPinLock = false; } adjustStatusBarLocked(mKeyguardStateController.isBouncerShowing(), false); adjustStatusBarLocked(mKeyguardStateController.isPrimaryBouncerShowing(), false); } } }; Loading
packages/SystemUI/src/com/android/systemui/keyguard/data/repository/KeyguardBouncerRepository.kt +11 −11 Original line number Diff line number Diff line Loading @@ -68,8 +68,8 @@ interface KeyguardBouncerRepository { val resourceUpdateRequests: StateFlow<Boolean> val bouncerPromptReason: Int val bouncerErrorMessage: CharSequence? val isAlternateBouncerVisible: StateFlow<Boolean> val isAlternateBouncerUIAvailable: StateFlow<Boolean> val alternateBouncerVisible: StateFlow<Boolean> val alternateBouncerUIAvailable: StateFlow<Boolean> var lastAlternateBouncerVisibleTime: Long fun setPrimaryScrimmed(isScrimmed: Boolean) Loading Loading @@ -159,12 +159,12 @@ constructor( get() = viewMediatorCallback.consumeCustomMessage() /** Values associated with the AlternateBouncer */ private val _isAlternateBouncerVisible = MutableStateFlow(false) override val isAlternateBouncerVisible = _isAlternateBouncerVisible.asStateFlow() private val _alternateBouncerVisible = MutableStateFlow(false) override val alternateBouncerVisible = _alternateBouncerVisible.asStateFlow() override var lastAlternateBouncerVisibleTime: Long = NOT_VISIBLE private val _isAlternateBouncerUIAvailable = MutableStateFlow(false) override val isAlternateBouncerUIAvailable: StateFlow<Boolean> = _isAlternateBouncerUIAvailable.asStateFlow() private val _alternateBouncerUIAvailable = MutableStateFlow(false) override val alternateBouncerUIAvailable: StateFlow<Boolean> = _alternateBouncerUIAvailable.asStateFlow() init { setUpLogging() Loading @@ -179,16 +179,16 @@ constructor( } override fun setAlternateVisible(isVisible: Boolean) { if (isVisible && !_isAlternateBouncerVisible.value) { if (isVisible && !_alternateBouncerVisible.value) { lastAlternateBouncerVisibleTime = clock.uptimeMillis() } else if (!isVisible) { lastAlternateBouncerVisibleTime = NOT_VISIBLE } _isAlternateBouncerVisible.value = isVisible _alternateBouncerVisible.value = isVisible } override fun setAlternateBouncerUIAvailable(isAvailable: Boolean) { _isAlternateBouncerUIAvailable.value = isAvailable _alternateBouncerUIAvailable.value = isAvailable } override fun setPrimaryShow(keyguardBouncerModel: KeyguardBouncerModel?) { Loading Loading @@ -290,7 +290,7 @@ constructor( resourceUpdateRequests .logDiffsForTable(buffer, "", "ResourceUpdateRequests", false) .launchIn(applicationScope) isAlternateBouncerUIAvailable alternateBouncerUIAvailable .logDiffsForTable(buffer, "", "IsAlternateBouncerUIAvailable", false) .launchIn(applicationScope) } Loading
packages/SystemUI/src/com/android/systemui/keyguard/data/repository/KeyguardRepository.kt +0 −26 Original line number Diff line number Diff line Loading @@ -86,9 +86,6 @@ interface KeyguardRepository { /** Observable for the signal that keyguard is about to go away. */ val isKeyguardGoingAway: Flow<Boolean> /** Observable for whether the bouncer is showing. */ val isBouncerShowing: Flow<Boolean> /** Is the always-on display available to be used? */ val isAodAvailable: Flow<Boolean> Loading Loading @@ -304,29 +301,6 @@ constructor( awaitClose { keyguardStateController.removeCallback(callback) } } override val isBouncerShowing: Flow<Boolean> = conflatedCallbackFlow { val callback = object : KeyguardStateController.Callback { override fun onBouncerShowingChanged() { trySendWithFailureLogging( keyguardStateController.isBouncerShowing, TAG, "updated isBouncerShowing" ) } } keyguardStateController.addCallback(callback) // Adding the callback does not send an initial update. trySendWithFailureLogging( keyguardStateController.isBouncerShowing, TAG, "initial isBouncerShowing" ) awaitClose { keyguardStateController.removeCallback(callback) } } override val isDozing: Flow<Boolean> = conflatedCallbackFlow { val callback = Loading
packages/SystemUI/src/com/android/systemui/keyguard/domain/interactor/AlternateBouncerInteractor.kt +3 −3 Original line number Diff line number Diff line Loading @@ -44,7 +44,7 @@ constructor( var legacyAlternateBouncer: LegacyAlternateBouncer? = null var legacyAlternateBouncerVisibleTime: Long = NOT_VISIBLE val isVisible: Flow<Boolean> = bouncerRepository.isAlternateBouncerVisible val isVisible: Flow<Boolean> = bouncerRepository.alternateBouncerVisible /** * Sets the correct bouncer states to show the alternate bouncer if it can show. Loading Loading @@ -86,7 +86,7 @@ constructor( fun isVisibleState(): Boolean { return if (isModernAlternateBouncerEnabled) { bouncerRepository.isAlternateBouncerVisible.value bouncerRepository.alternateBouncerVisible.value } else { legacyAlternateBouncer?.isShowingAlternateBouncer ?: false } Loading @@ -98,7 +98,7 @@ constructor( fun canShowAlternateBouncerForFingerprint(): Boolean { return if (isModernAlternateBouncerEnabled) { bouncerRepository.isAlternateBouncerUIAvailable.value && bouncerRepository.alternateBouncerUIAvailable.value && biometricSettingsRepository.isFingerprintEnrolled.value && biometricSettingsRepository.isStrongBiometricAllowed.value && biometricSettingsRepository.isFingerprintEnabledByDevicePolicy.value && Loading