From d994ce8b48d752148d1218c5b647d6a7c1921495 Mon Sep 17 00:00:00 2001 From: James Haggerty Date: Sun, 30 Oct 2022 09:01:05 +1100 Subject: Make countdown face reset to 0 (#90) * Make countdown face reset to 0 It was annoying to have countdowns less than DEFAULT_MINUTES. Admittedly, this does make DEFAULT_MINUTES fairly useless, since we only ever see it the first time... * Undo accidental change to movement_config.h --- movement/watch_faces/complication/countdown_face.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/movement/watch_faces/complication/countdown_face.c b/movement/watch_faces/complication/countdown_face.c index 81836f37..ee523b41 100644 --- a/movement/watch_faces/complication/countdown_face.c +++ b/movement/watch_faces/complication/countdown_face.c @@ -179,7 +179,10 @@ bool countdown_face_loop(movement_event_t event, movement_settings_t *settings, reset(state); break; case cd_waiting: - start(state, settings); + if (!(state->minutes == 0 && state->seconds == 0)) { + // Only start the timer if we have a valid time. + start(state, settings); + } break; case cd_setting: settings_increment(state); @@ -192,7 +195,7 @@ bool countdown_face_loop(movement_event_t event, movement_settings_t *settings, break; case EVENT_ALARM_LONG_PRESS: if (state->mode == cd_setting) { - state->minutes = DEFAULT_MINUTES; + state->minutes = 0; state->seconds = 0; draw(state, event.subsecond); break; -- cgit v1.2.3