0
0
Fork 0
mirror of https://github.com/YTVanced/VancedManager synced 2024-12-01 07:23:02 +00:00

implement callback for finish button click

This commit is contained in:
X1nto 2021-11-27 16:15:02 +04:00
parent ea8b359e9e
commit b6533e3b37
2 changed files with 6 additions and 2 deletions

View file

@ -138,7 +138,10 @@ class MainActivity : ComponentActivity() {
InstallScreen(
appName = screen.appName,
appVersions = screen.appVersions,
viewModel = installViewModel
viewModel = installViewModel,
onFinishClick = {
backStack.newRoot(Screen.Home)
}
)
}
}

View file

@ -43,6 +43,7 @@ fun InstallScreen(
appName: String,
appVersions: List<String>?,
viewModel: InstallViewModel,
onFinishClick: () -> Unit
) {
var startedProcess by rememberSaveable { mutableStateOf(false) }
@ -82,7 +83,7 @@ fun InstallScreen(
icon = {
Icon(Icons.Rounded.Done, null)
},
onClick = { /*TODO*/ },
onClick = onFinishClick,
)
}
}