LockScreen : avoid removing from composition the LoggedInFlowNode.Children when LockScreen is displayed.

This commit is contained in:
ganfra
2023-11-14 20:59:17 +01:00
parent 2f71be0404
commit b9a637458b
4 changed files with 32 additions and 57 deletions

View File

@@ -44,6 +44,12 @@ interface LockScreenService {
fun isPinSetup(): Flow<Boolean>
}
/**
* Check if the app is currently locked.
*/
val LockScreenService.isLocked: Boolean
get() = lockState.value == LockScreenLockState.Locked
/**
* Makes sure the secure flag is set on the activity if the pin is setup.
* @param activity the activity to set the flag on.