select timer type string resource and package refactor
This commit is contained in:
parent
86c7a0e6a8
commit
853a2d8c28
2 changed files with 6 additions and 6 deletions
|
@ -1,4 +1,4 @@
|
|||
package be.ugent.sel.studeez.screens.timer_form.timer_add
|
||||
package be.ugent.sel.studeez.screens.timer_form.timer_type_select
|
||||
|
||||
import androidx.compose.foundation.layout.Column
|
||||
import androidx.compose.foundation.layout.fillMaxWidth
|
||||
|
@ -7,16 +7,18 @@ import androidx.compose.material.Text
|
|||
import androidx.compose.runtime.Composable
|
||||
import androidx.compose.ui.Alignment
|
||||
import androidx.compose.ui.Modifier
|
||||
import androidx.compose.ui.res.stringResource
|
||||
import androidx.hilt.navigation.compose.hiltViewModel
|
||||
import be.ugent.sel.studeez.common.composable.SecondaryScreenTemplate
|
||||
import be.ugent.sel.studeez.data.local.models.timer_info.*
|
||||
import be.ugent.sel.studeez.R.string as AppText
|
||||
import be.ugent.sel.studeez.data.local.models.timer_info.TimerType.CUSTOM
|
||||
import be.ugent.sel.studeez.data.local.models.timer_info.TimerType.BREAK
|
||||
import be.ugent.sel.studeez.data.local.models.timer_info.TimerType.ENDLESS
|
||||
|
||||
val defaultTimerInfo: Map<TimerType, TimerInfo> = mapOf(
|
||||
CUSTOM to CustomTimerInfo("", "", 0),
|
||||
BREAK to PomodoroTimerInfo("", "", 0, 0, 0),
|
||||
BREAK to PomodoroTimerInfo("", "", 0, 0, 1),
|
||||
ENDLESS to EndlessTimerInfo("", ""),
|
||||
)
|
||||
|
||||
|
@ -28,7 +30,7 @@ fun TimerTypeSelectScreen(
|
|||
viewModel: TimerTypeSelectViewModel = hiltViewModel()
|
||||
) {
|
||||
|
||||
SecondaryScreenTemplate(title = "Edit Timer", popUp = popUp) {
|
||||
SecondaryScreenTemplate(title = stringResource(id = AppText.timer_type_select), popUp = popUp) {
|
||||
Column(
|
||||
horizontalAlignment = Alignment.CenterHorizontally,
|
||||
modifier = Modifier.fillMaxWidth()
|
||||
|
|
|
@ -1,13 +1,11 @@
|
|||
package be.ugent.sel.studeez.screens.timer_form.timer_add
|
||||
package be.ugent.sel.studeez.screens.timer_form.timer_type_select
|
||||
|
||||
import be.ugent.sel.studeez.data.EditTimerState
|
||||
import be.ugent.sel.studeez.data.local.models.timer_info.TimerInfo
|
||||
import be.ugent.sel.studeez.domain.LogService
|
||||
import be.ugent.sel.studeez.domain.TimerDAO
|
||||
import be.ugent.sel.studeez.navigation.StudeezDestinations
|
||||
import be.ugent.sel.studeez.screens.StudeezViewModel
|
||||
import dagger.hilt.android.lifecycle.HiltViewModel
|
||||
import kotlinx.coroutines.flow.Flow
|
||||
import javax.inject.Inject
|
||||
|
||||
@HiltViewModel
|
||||
|
|
Reference in a new issue