Cleanup show current tab
This commit is contained in:
parent
d268fcd389
commit
27526151b0
7 changed files with 38 additions and 57 deletions
|
@ -2,17 +2,8 @@ package be.ugent.sel.studeez
|
||||||
|
|
||||||
import android.content.res.Resources
|
import android.content.res.Resources
|
||||||
import androidx.compose.foundation.layout.padding
|
import androidx.compose.foundation.layout.padding
|
||||||
import androidx.compose.material.MaterialTheme
|
import androidx.compose.material.*
|
||||||
import androidx.compose.material.Scaffold
|
import androidx.compose.runtime.*
|
||||||
import androidx.compose.material.ScaffoldState
|
|
||||||
import androidx.compose.material.Snackbar
|
|
||||||
import androidx.compose.material.SnackbarHost
|
|
||||||
import androidx.compose.material.Surface
|
|
||||||
import androidx.compose.material.rememberScaffoldState
|
|
||||||
import androidx.compose.runtime.Composable
|
|
||||||
import androidx.compose.runtime.ReadOnlyComposable
|
|
||||||
import androidx.compose.runtime.remember
|
|
||||||
import androidx.compose.runtime.rememberCoroutineScope
|
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import androidx.compose.ui.platform.LocalConfiguration
|
import androidx.compose.ui.platform.LocalConfiguration
|
||||||
import androidx.compose.ui.platform.LocalContext
|
import androidx.compose.ui.platform.LocalContext
|
||||||
|
@ -21,6 +12,7 @@ import androidx.hilt.navigation.compose.hiltViewModel
|
||||||
import androidx.navigation.NavHostController
|
import androidx.navigation.NavHostController
|
||||||
import androidx.navigation.compose.NavHost
|
import androidx.navigation.compose.NavHost
|
||||||
import androidx.navigation.compose.composable
|
import androidx.navigation.compose.composable
|
||||||
|
import androidx.navigation.compose.currentBackStackEntryAsState
|
||||||
import androidx.navigation.compose.rememberNavController
|
import androidx.navigation.compose.rememberNavController
|
||||||
import be.ugent.sel.studeez.common.composable.drawer.DrawerViewModel
|
import be.ugent.sel.studeez.common.composable.drawer.DrawerViewModel
|
||||||
import be.ugent.sel.studeez.common.composable.navbar.NavigationBarViewModel
|
import be.ugent.sel.studeez.common.composable.navbar.NavigationBarViewModel
|
||||||
|
@ -89,6 +81,8 @@ fun StudeezNavGraph(
|
||||||
val drawerViewModel: DrawerViewModel = hiltViewModel()
|
val drawerViewModel: DrawerViewModel = hiltViewModel()
|
||||||
val navBarViewModel: NavigationBarViewModel = hiltViewModel()
|
val navBarViewModel: NavigationBarViewModel = hiltViewModel()
|
||||||
|
|
||||||
|
val backStackEntry by appState.navController.currentBackStackEntryAsState()
|
||||||
|
|
||||||
NavHost(
|
NavHost(
|
||||||
navController = appState.navController,
|
navController = appState.navController,
|
||||||
startDestination = StudeezDestinations.SPLASH_SCREEN,
|
startDestination = StudeezDestinations.SPLASH_SCREEN,
|
||||||
|
@ -106,6 +100,9 @@ fun StudeezNavGraph(
|
||||||
appState.navigateAndPopUp(route, popUp)
|
appState.navigateAndPopUp(route, popUp)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
val getCurrentScreen: () -> String? = {
|
||||||
|
backStackEntry?.destination?.route
|
||||||
|
}
|
||||||
|
|
||||||
composable(StudeezDestinations.SPLASH_SCREEN) {
|
composable(StudeezDestinations.SPLASH_SCREEN) {
|
||||||
SplashRoute(openAndPopUp, viewModel = hiltViewModel())
|
SplashRoute(openAndPopUp, viewModel = hiltViewModel())
|
||||||
|
@ -123,6 +120,7 @@ fun StudeezNavGraph(
|
||||||
HomeRoute(
|
HomeRoute(
|
||||||
open,
|
open,
|
||||||
openAndPopUp,
|
openAndPopUp,
|
||||||
|
getCurrentScreen,
|
||||||
viewModel = hiltViewModel(),
|
viewModel = hiltViewModel(),
|
||||||
drawerViewModel = drawerViewModel,
|
drawerViewModel = drawerViewModel,
|
||||||
navBarViewModel = navBarViewModel,
|
navBarViewModel = navBarViewModel,
|
||||||
|
@ -133,7 +131,7 @@ fun StudeezNavGraph(
|
||||||
// TODO Sessions screen
|
// TODO Sessions screen
|
||||||
|
|
||||||
composable(StudeezDestinations.PROFILE_SCREEN) {
|
composable(StudeezDestinations.PROFILE_SCREEN) {
|
||||||
ProfileRoute(open, openAndPopUp, viewModel = hiltViewModel())
|
ProfileRoute(open, openAndPopUp, getCurrentScreen, viewModel = hiltViewModel())
|
||||||
}
|
}
|
||||||
|
|
||||||
composable(StudeezDestinations.TIMER_OVERVIEW_SCREEN) {
|
composable(StudeezDestinations.TIMER_OVERVIEW_SCREEN) {
|
||||||
|
@ -161,6 +159,7 @@ fun StudeezNavGraph(
|
||||||
TimerSelectionRoute(
|
TimerSelectionRoute(
|
||||||
open,
|
open,
|
||||||
openAndPopUp,
|
openAndPopUp,
|
||||||
|
getCurrentScreen,
|
||||||
viewModel = hiltViewModel(),
|
viewModel = hiltViewModel(),
|
||||||
drawerViewModel = drawerViewModel,
|
drawerViewModel = drawerViewModel,
|
||||||
navBarViewModel = navBarViewModel,
|
navBarViewModel = navBarViewModel,
|
||||||
|
|
|
@ -2,26 +2,19 @@ package be.ugent.sel.studeez.common.composable
|
||||||
|
|
||||||
import androidx.compose.foundation.layout.PaddingValues
|
import androidx.compose.foundation.layout.PaddingValues
|
||||||
import androidx.compose.foundation.layout.RowScope
|
import androidx.compose.foundation.layout.RowScope
|
||||||
import androidx.compose.material.FabPosition
|
import androidx.compose.material.*
|
||||||
import androidx.compose.material.Icon
|
|
||||||
import androidx.compose.material.IconButton
|
|
||||||
import androidx.compose.material.Scaffold
|
|
||||||
import androidx.compose.material.ScaffoldState
|
|
||||||
import androidx.compose.material.Text
|
|
||||||
import androidx.compose.material.TopAppBar
|
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.Edit
|
import androidx.compose.material.icons.filled.Edit
|
||||||
import androidx.compose.material.icons.filled.Menu
|
import androidx.compose.material.icons.filled.Menu
|
||||||
import androidx.compose.material.rememberScaffoldState
|
|
||||||
import androidx.compose.runtime.Composable
|
import androidx.compose.runtime.Composable
|
||||||
import androidx.compose.runtime.rememberCoroutineScope
|
import androidx.compose.runtime.rememberCoroutineScope
|
||||||
import androidx.compose.ui.tooling.preview.Preview
|
import androidx.compose.ui.tooling.preview.Preview
|
||||||
import be.ugent.sel.studeez.R
|
import be.ugent.sel.studeez.R
|
||||||
import be.ugent.sel.studeez.resources
|
|
||||||
import be.ugent.sel.studeez.common.composable.drawer.Drawer
|
import be.ugent.sel.studeez.common.composable.drawer.Drawer
|
||||||
import be.ugent.sel.studeez.common.composable.drawer.DrawerActions
|
import be.ugent.sel.studeez.common.composable.drawer.DrawerActions
|
||||||
import be.ugent.sel.studeez.common.composable.navbar.NavigationBar
|
import be.ugent.sel.studeez.common.composable.navbar.NavigationBar
|
||||||
import be.ugent.sel.studeez.common.composable.navbar.NavigationBarActions
|
import be.ugent.sel.studeez.common.composable.navbar.NavigationBarActions
|
||||||
|
import be.ugent.sel.studeez.resources
|
||||||
import be.ugent.sel.studeez.ui.theme.StudeezTheme
|
import be.ugent.sel.studeez.ui.theme.StudeezTheme
|
||||||
import kotlinx.coroutines.CoroutineScope
|
import kotlinx.coroutines.CoroutineScope
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
package be.ugent.sel.studeez.common.composable.navbar
|
package be.ugent.sel.studeez.common.composable.navbar
|
||||||
|
|
||||||
|
import android.util.Log
|
||||||
import androidx.compose.material.BottomNavigation
|
import androidx.compose.material.BottomNavigation
|
||||||
import androidx.compose.material.BottomNavigationItem
|
import androidx.compose.material.BottomNavigationItem
|
||||||
import androidx.compose.material.Icon
|
import androidx.compose.material.Icon
|
||||||
|
@ -19,7 +20,7 @@ import be.ugent.sel.studeez.ui.theme.StudeezTheme
|
||||||
import be.ugent.sel.studeez.R.string as AppText
|
import be.ugent.sel.studeez.R.string as AppText
|
||||||
|
|
||||||
data class NavigationBarActions(
|
data class NavigationBarActions(
|
||||||
val selectedTab: (String) -> Boolean,
|
val isSelectedTab: (String) -> Boolean,
|
||||||
val onHomeClick: () -> Unit,
|
val onHomeClick: () -> Unit,
|
||||||
val onTasksClick: () -> Unit,
|
val onTasksClick: () -> Unit,
|
||||||
val onSessionsClick: () -> Unit,
|
val onSessionsClick: () -> Unit,
|
||||||
|
@ -29,9 +30,13 @@ data class NavigationBarActions(
|
||||||
fun getNavigationBarActions(
|
fun getNavigationBarActions(
|
||||||
navigationBarViewModel: NavigationBarViewModel,
|
navigationBarViewModel: NavigationBarViewModel,
|
||||||
open: (String) -> Unit,
|
open: (String) -> Unit,
|
||||||
|
getCurrentScreen: () -> String?
|
||||||
): NavigationBarActions {
|
): NavigationBarActions {
|
||||||
return NavigationBarActions(
|
return NavigationBarActions(
|
||||||
selectedTab = { navigationBarViewModel.isSelected(it) },
|
isSelectedTab = { screen ->
|
||||||
|
Log.v("TEMP", getCurrentScreen().toString()) // TODO Remove
|
||||||
|
screen == getCurrentScreen()
|
||||||
|
},
|
||||||
onHomeClick = {
|
onHomeClick = {
|
||||||
navigationBarViewModel.onHomeClick(open)
|
navigationBarViewModel.onHomeClick(open)
|
||||||
},
|
},
|
||||||
|
@ -49,16 +54,15 @@ fun getNavigationBarActions(
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
fun NavigationBar(
|
fun NavigationBar(
|
||||||
navigationBarActions: NavigationBarActions,
|
navigationBarActions: NavigationBarActions
|
||||||
) {
|
) {
|
||||||
BottomNavigation(
|
BottomNavigation(
|
||||||
elevation = 10.dp
|
elevation = 10.dp
|
||||||
) {
|
) {
|
||||||
|
|
||||||
BottomNavigationItem(
|
BottomNavigationItem(
|
||||||
icon = { Icon(imageVector = Icons.Default.List, resources().getString(AppText.home)) },
|
icon = { Icon(imageVector = Icons.Default.List, resources().getString(AppText.home)) },
|
||||||
label = { Text(text = resources().getString(AppText.home)) },
|
label = { Text(text = resources().getString(AppText.home)) },
|
||||||
selected = navigationBarActions.selectedTab(HOME_SCREEN),
|
selected = navigationBarActions.isSelectedTab(HOME_SCREEN),
|
||||||
onClick = navigationBarActions.onHomeClick
|
onClick = navigationBarActions.onHomeClick
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -69,7 +73,7 @@ fun NavigationBar(
|
||||||
)
|
)
|
||||||
},
|
},
|
||||||
label = { Text(text = resources().getString(AppText.tasks)) },
|
label = { Text(text = resources().getString(AppText.tasks)) },
|
||||||
// TODO selected = navigationBarActions.selectedTab(TASKS_SCREEN),
|
// TODO selected = navigationBarActions.isSelectedTab(TASKS_SCREEN),
|
||||||
selected = false,
|
selected = false,
|
||||||
onClick = navigationBarActions.onTasksClick
|
onClick = navigationBarActions.onTasksClick
|
||||||
)
|
)
|
||||||
|
@ -84,7 +88,7 @@ fun NavigationBar(
|
||||||
)
|
)
|
||||||
},
|
},
|
||||||
label = { Text(text = resources().getString(AppText.sessions)) },
|
label = { Text(text = resources().getString(AppText.sessions)) },
|
||||||
// TODO selected = navigationBarActions.selectedTab(SESSIONS_SCREEN),
|
// TODO selected = navigationBarActions.isSelectedTab(SESSIONS_SCREEN),
|
||||||
selected = false,
|
selected = false,
|
||||||
onClick = navigationBarActions.onSessionsClick
|
onClick = navigationBarActions.onSessionsClick
|
||||||
)
|
)
|
||||||
|
@ -96,7 +100,7 @@ fun NavigationBar(
|
||||||
)
|
)
|
||||||
},
|
},
|
||||||
label = { Text(text = resources().getString(AppText.profile)) },
|
label = { Text(text = resources().getString(AppText.profile)) },
|
||||||
selected = navigationBarActions.selectedTab(PROFILE_SCREEN),
|
selected = navigationBarActions.isSelectedTab(PROFILE_SCREEN),
|
||||||
onClick = navigationBarActions.onProfileClick
|
onClick = navigationBarActions.onProfileClick
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -107,6 +111,8 @@ fun NavigationBar(
|
||||||
@Composable
|
@Composable
|
||||||
fun NavigationBarPreview() {
|
fun NavigationBarPreview() {
|
||||||
StudeezTheme {
|
StudeezTheme {
|
||||||
NavigationBar(NavigationBarActions({ false }, {}, {}, {}, {}))
|
NavigationBar(
|
||||||
|
navigationBarActions = NavigationBarActions({ false }, {}, {}, {}, {}),
|
||||||
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -7,41 +7,26 @@ import be.ugent.sel.studeez.navigation.StudeezDestinations.PROFILE_SCREEN
|
||||||
import be.ugent.sel.studeez.screens.StudeezViewModel
|
import be.ugent.sel.studeez.screens.StudeezViewModel
|
||||||
import dagger.hilt.android.lifecycle.HiltViewModel
|
import dagger.hilt.android.lifecycle.HiltViewModel
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
import javax.inject.Singleton
|
|
||||||
|
|
||||||
@HiltViewModel
|
@HiltViewModel
|
||||||
class NavigationBarViewModel @Inject constructor(
|
class NavigationBarViewModel @Inject constructor(
|
||||||
private val accountDAO: AccountDAO,
|
private val accountDAO: AccountDAO,
|
||||||
var selectedTab: SelectedTabState,
|
|
||||||
logService: LogService
|
logService: LogService
|
||||||
) : StudeezViewModel(logService) {
|
) : StudeezViewModel(logService) {
|
||||||
|
|
||||||
fun isSelected(screen: String): Boolean {
|
|
||||||
return screen == selectedTab.selectedTab
|
|
||||||
}
|
|
||||||
|
|
||||||
fun onHomeClick(open: (String) -> Unit) {
|
fun onHomeClick(open: (String) -> Unit) {
|
||||||
selectedTab.selectedTab = HOME_SCREEN
|
|
||||||
open(HOME_SCREEN)
|
open(HOME_SCREEN)
|
||||||
}
|
}
|
||||||
|
|
||||||
fun onTasksClick(open: (String) -> Unit) {
|
fun onTasksClick(open: (String) -> Unit) {
|
||||||
// TODO
|
// TODO
|
||||||
// selectedTab.selectedTab = TASKS_SCREEN
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun onSessionsClick(open: (String) -> Unit) {
|
fun onSessionsClick(open: (String) -> Unit) {
|
||||||
// TODO
|
// TODO
|
||||||
// selectedTab.selectedTab = SESSIONS_SCREEN
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun onProfileClick(open: (String) -> Unit) {
|
fun onProfileClick(open: (String) -> Unit) {
|
||||||
selectedTab.selectedTab = PROFILE_SCREEN
|
|
||||||
open(PROFILE_SCREEN)
|
open(PROFILE_SCREEN)
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
@Singleton
|
|
||||||
class SelectedTabState @Inject constructor() {
|
|
||||||
var selectedTab: String = HOME_SCREEN
|
|
||||||
}
|
}
|
|
@ -23,6 +23,7 @@ import be.ugent.sel.studeez.resources
|
||||||
fun HomeRoute(
|
fun HomeRoute(
|
||||||
open: (String) -> Unit,
|
open: (String) -> Unit,
|
||||||
openAndPopUp: (String, String) -> Unit,
|
openAndPopUp: (String, String) -> Unit,
|
||||||
|
getCurrentScreen: () -> String?,
|
||||||
viewModel: HomeViewModel,
|
viewModel: HomeViewModel,
|
||||||
drawerViewModel: DrawerViewModel,
|
drawerViewModel: DrawerViewModel,
|
||||||
navBarViewModel: NavigationBarViewModel,
|
navBarViewModel: NavigationBarViewModel,
|
||||||
|
@ -30,7 +31,7 @@ fun HomeRoute(
|
||||||
HomeScreen(
|
HomeScreen(
|
||||||
onStartSessionClick = { viewModel.onStartSessionClick(open) },
|
onStartSessionClick = { viewModel.onStartSessionClick(open) },
|
||||||
drawerActions = getDrawerActions(drawerViewModel, open, openAndPopUp),
|
drawerActions = getDrawerActions(drawerViewModel, open, openAndPopUp),
|
||||||
navigationBarActions = getNavigationBarActions(navBarViewModel, open),
|
navigationBarActions = getNavigationBarActions(navBarViewModel, open, getCurrentScreen),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -45,7 +46,7 @@ fun HomeScreen(
|
||||||
title = resources().getString(R.string.home),
|
title = resources().getString(R.string.home),
|
||||||
drawerActions = drawerActions,
|
drawerActions = drawerActions,
|
||||||
navigationBarActions = navigationBarActions,
|
navigationBarActions = navigationBarActions,
|
||||||
action = { FriendsAction() }
|
barAction = { FriendsAction() }
|
||||||
) {
|
) {
|
||||||
BasicButton(R.string.start_session, Modifier.basicButton()) {
|
BasicButton(R.string.start_session, Modifier.basicButton()) {
|
||||||
onStartSessionClick()
|
onStartSessionClick()
|
||||||
|
|
|
@ -4,22 +4,17 @@ import androidx.compose.material.Icon
|
||||||
import androidx.compose.material.IconButton
|
import androidx.compose.material.IconButton
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.filled.Edit
|
import androidx.compose.material.icons.filled.Edit
|
||||||
import androidx.compose.runtime.Composable
|
import androidx.compose.runtime.*
|
||||||
import androidx.compose.runtime.LaunchedEffect
|
|
||||||
import androidx.compose.runtime.getValue
|
|
||||||
import androidx.compose.runtime.mutableStateOf
|
|
||||||
import androidx.compose.runtime.remember
|
|
||||||
import androidx.compose.runtime.setValue
|
|
||||||
import androidx.compose.ui.tooling.preview.Preview
|
import androidx.compose.ui.tooling.preview.Preview
|
||||||
import androidx.hilt.navigation.compose.hiltViewModel
|
import androidx.hilt.navigation.compose.hiltViewModel
|
||||||
import be.ugent.sel.studeez.R
|
import be.ugent.sel.studeez.R
|
||||||
import be.ugent.sel.studeez.common.composable.Headline
|
import be.ugent.sel.studeez.common.composable.Headline
|
||||||
import be.ugent.sel.studeez.common.composable.PrimaryScreenTemplate
|
import be.ugent.sel.studeez.common.composable.PrimaryScreenTemplate
|
||||||
import be.ugent.sel.studeez.resources
|
|
||||||
import be.ugent.sel.studeez.common.composable.drawer.DrawerActions
|
import be.ugent.sel.studeez.common.composable.drawer.DrawerActions
|
||||||
import be.ugent.sel.studeez.common.composable.drawer.getDrawerActions
|
import be.ugent.sel.studeez.common.composable.drawer.getDrawerActions
|
||||||
import be.ugent.sel.studeez.common.composable.navbar.NavigationBarActions
|
import be.ugent.sel.studeez.common.composable.navbar.NavigationBarActions
|
||||||
import be.ugent.sel.studeez.common.composable.navbar.getNavigationBarActions
|
import be.ugent.sel.studeez.common.composable.navbar.getNavigationBarActions
|
||||||
|
import be.ugent.sel.studeez.resources
|
||||||
import kotlinx.coroutines.CoroutineScope
|
import kotlinx.coroutines.CoroutineScope
|
||||||
import be.ugent.sel.studeez.R.string as AppText
|
import be.ugent.sel.studeez.R.string as AppText
|
||||||
|
|
||||||
|
@ -42,12 +37,13 @@ fun getProfileActions(
|
||||||
fun ProfileRoute(
|
fun ProfileRoute(
|
||||||
open: (String) -> Unit,
|
open: (String) -> Unit,
|
||||||
openAndPopUp: (String, String) -> Unit,
|
openAndPopUp: (String, String) -> Unit,
|
||||||
|
getCurrentScreen: () -> String?,
|
||||||
viewModel: ProfileViewModel,
|
viewModel: ProfileViewModel,
|
||||||
) {
|
) {
|
||||||
ProfileScreen(
|
ProfileScreen(
|
||||||
profileActions = getProfileActions(viewModel, open),
|
profileActions = getProfileActions(viewModel, open),
|
||||||
drawerActions = getDrawerActions(hiltViewModel(), open, openAndPopUp),
|
drawerActions = getDrawerActions(hiltViewModel(), open, openAndPopUp),
|
||||||
navigationBarActions = getNavigationBarActions(hiltViewModel(), open),
|
navigationBarActions = getNavigationBarActions(hiltViewModel(), open, getCurrentScreen),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -65,7 +61,7 @@ fun ProfileScreen(
|
||||||
title = resources().getString(AppText.profile),
|
title = resources().getString(AppText.profile),
|
||||||
drawerActions = drawerActions,
|
drawerActions = drawerActions,
|
||||||
navigationBarActions = navigationBarActions,
|
navigationBarActions = navigationBarActions,
|
||||||
action = { EditAction(onClick = profileActions.onEditProfileClick) }
|
barAction = { EditAction(onClick = profileActions.onEditProfileClick) }
|
||||||
) {
|
) {
|
||||||
Headline(text = (username ?: resources().getString(R.string.no_username)))
|
Headline(text = (username ?: resources().getString(R.string.no_username)))
|
||||||
}
|
}
|
||||||
|
|
|
@ -41,6 +41,7 @@ fun getTimerSelectionActions(
|
||||||
fun TimerSelectionRoute(
|
fun TimerSelectionRoute(
|
||||||
open: (String) -> Unit,
|
open: (String) -> Unit,
|
||||||
openAndPopUp: (String, String) -> Unit,
|
openAndPopUp: (String, String) -> Unit,
|
||||||
|
getCurrentScreen: () -> String?,
|
||||||
viewModel: TimerSelectionViewModel,
|
viewModel: TimerSelectionViewModel,
|
||||||
drawerViewModel: DrawerViewModel,
|
drawerViewModel: DrawerViewModel,
|
||||||
navBarViewModel: NavigationBarViewModel,
|
navBarViewModel: NavigationBarViewModel,
|
||||||
|
@ -48,7 +49,7 @@ fun TimerSelectionRoute(
|
||||||
TimerSelectionScreen(
|
TimerSelectionScreen(
|
||||||
timerSelectionActions = getTimerSelectionActions(viewModel, open),
|
timerSelectionActions = getTimerSelectionActions(viewModel, open),
|
||||||
drawerActions = getDrawerActions(drawerViewModel, open, openAndPopUp),
|
drawerActions = getDrawerActions(drawerViewModel, open, openAndPopUp),
|
||||||
navigationBarActions = getNavigationBarActions(navBarViewModel, open),
|
navigationBarActions = getNavigationBarActions(navBarViewModel, open, getCurrentScreen),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Reference in a new issue