Clock - If a timer is inactive, show the default time at the top, not 00:00

This commit is contained in:
Pavol Franek 2020-03-12 18:35:38 +01:00
parent db6c2ee4a4
commit 00994df725

View File

@ -42,7 +42,7 @@ class TimerFragment : Fragment() {
val config = requiredActivity.config val config = requiredActivity.config
val textColor = config.textColor val textColor = config.textColor
timer_time.text = 0.getFormattedDuration() timer_time.text = config.timerSeconds.getFormattedDuration()
requiredActivity.updateTextColors(timer_fragment) requiredActivity.updateTextColors(timer_fragment)
timer_play_pause.background = resources.getColoredDrawableWithColor(R.drawable.circle_background_filled, context!!.getAdjustedPrimaryColor()) timer_play_pause.background = resources.getColoredDrawableWithColor(R.drawable.circle_background_filled, context!!.getAdjustedPrimaryColor())
@ -121,7 +121,7 @@ class TimerFragment : Fragment() {
@Subscribe(threadMode = ThreadMode.MAIN) @Subscribe(threadMode = ThreadMode.MAIN)
fun onMessageEvent(state: TimerState.Idle) { fun onMessageEvent(state: TimerState.Idle) {
view.timer_time.text = 0.getFormattedDuration() view.timer_time.text = requiredActivity.config.timerSeconds.getFormattedDuration()
updateViewStates(state) updateViewStates(state)
} }