]> git.earman.xyz Git - sensor-watch.git/commitdiff
countdown: have timeout exit setting mode
authorjoeycastillo <joeycastillo@utexas.edu>
Sun, 29 Sep 2024 01:39:19 +0000 (21:39 -0400)
committerjoeycastillo <joeycastillo@utexas.edu>
Sun, 29 Sep 2024 01:39:19 +0000 (21:39 -0400)
watch-faces/complication/countdown_face.c

index 9a51c37b8e7195d2dec6eb893f652a5847757cef..a0b860600a20047b28ff5eb635043f674ff63286 100644 (file)
@@ -329,8 +329,13 @@ bool countdown_face_loop(movement_event_t event, movement_settings_t *settings,
             times_up(settings, state);
             break;
         case EVENT_TIMEOUT:
-            abort_quick_ticks(state);
-            movement_move_to_face(0);
+            if (state->mode == cd_setting) {
+                state->selection = 0;
+                state->mode = cd_reset;
+                store_countdown(state);
+                movement_request_tick_frequency(1);
+                button_beep(settings);
+            }
             break;
         case EVENT_LOW_ENERGY_UPDATE:
         case EVENT_LIGHT_BUTTON_DOWN: