Forgot to reset the state of the scan...

Thus making scan innaccessible
This commit is contained in:
Nacho 2025-01-04 16:47:25 +01:00
parent d40758dc02
commit 2f0555484e
2 changed files with 5 additions and 0 deletions

View File

@ -63,6 +63,9 @@ class MainActivity : ComponentActivity() {
isDoneReadingCharacter = true
"Done reading character"
}
},
onClickScan = {
isDoneReadingCharacter = false
}
)
}

View File

@ -16,6 +16,7 @@ import com.github.nacabaro.vbhelper.screens.StorageScreen
@Composable
fun AppNavigation(
onClickRead: () -> Unit,
onClickScan: () -> Unit,
isDoneReadingCharacter: Boolean
) {
val navController = rememberNavController()
@ -41,6 +42,7 @@ fun AppNavigation(
StorageScreen()
}
composable(BottomNavItem.Scan.route) {
onClickScan()
ScanScreen(
navController = navController,
onClickRead = onClickRead,