From: joeycastillo Date: Sun, 27 Nov 2022 22:52:25 +0000 (-0600) Subject: make stopwatch beep when started/stopped X-Git-Url: https://git.earman.xyz/?a=commitdiff_plain;h=9c2c9087bfcbea1938031b8f2e64f863f7a0ed61;p=sensor-watch.git make stopwatch beep when started/stopped --- diff --git a/movement/watch_faces/complication/stopwatch_face.c b/movement/watch_faces/complication/stopwatch_face.c index e85bbd6..5a46518 100644 --- a/movement/watch_faces/complication/stopwatch_face.c +++ b/movement/watch_faces/complication/stopwatch_face.c @@ -77,7 +77,6 @@ void stopwatch_face_activate(movement_settings_t *settings, void *context) { } bool stopwatch_face_loop(movement_event_t event, movement_settings_t *settings, void *context) { - (void) settings; stopwatch_state_t *stopwatch_state = (stopwatch_state_t *)context; switch (event.event_type) { @@ -103,6 +102,9 @@ bool stopwatch_face_loop(movement_event_t event, movement_settings_t *settings, } break; case EVENT_ALARM_BUTTON_DOWN: + if (settings->bit.button_should_sound) { + watch_buzzer_play_note(BUZZER_NOTE_C8, 50); + } stopwatch_state->running = !stopwatch_state->running; if (stopwatch_state->running) { // we're running now, so we need to set the start_time.