Skip to content
This repository has been archived by the owner on Mar 15, 2022. It is now read-only.

Commit

Permalink
implement callback for finish button click
Browse files Browse the repository at this point in the history
  • Loading branch information
X1nto committed Nov 27, 2021
1 parent ea8b359 commit b6533e3
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
5 changes: 4 additions & 1 deletion app/src/main/java/com/vanced/manager/ui/MainActivity.kt
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,10 @@ class MainActivity : ComponentActivity() {
InstallScreen(
appName = screen.appName,
appVersions = screen.appVersions,
viewModel = installViewModel
viewModel = installViewModel,
onFinishClick = {
backStack.newRoot(Screen.Home)
}
)
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ fun InstallScreen(
appName: String,
appVersions: List<String>?,
viewModel: InstallViewModel,
onFinishClick: () -> Unit
) {
var startedProcess by rememberSaveable { mutableStateOf(false) }

Expand Down Expand Up @@ -82,7 +83,7 @@ fun InstallScreen(
icon = {
Icon(Icons.Rounded.Done, null)
},
onClick = { /*TODO*/ },
onClick = onFinishClick,
)
}
}
Expand Down

0 comments on commit b6533e3

Please sign in to comment.