From 91280aa0f7c1876ff047724ba8549e0c312bf059 Mon Sep 17 00:00:00 2001 From: Randall Winkhart Date: Sun, 1 Nov 2026 10:45:29 -0500 Subject: [PATCH] Backport 787c080c43a1cb11a3a5f349ce17560ba88c6aa4 --- src/c/main.c | 7 +++++-- src/c/main.h | 2 -- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/c/main.c b/src/c/main.c index f24c1f7..b701877 100644 --- a/src/c/main.c +++ b/src/c/main.c @@ -94,6 +94,8 @@ static char *s_options_under[2]; ////////////////////// STATUS ////////////////////// +static void push_setter_window(); + static void click_handler_disable_tutorial(void *recognizer, void *ctx) { settings.TutorialEnabled = false; persist_write_data(STORAGE_KEY_SETTINGS, &settings, sizeof(settings)); @@ -172,6 +174,7 @@ static void status_window_load(StatusWindowPurpose purpose) { static void status_window_unload() { text_layer_destroy(s_status_txt_layer); + window_destroy(s_status_window); } static void push_status_window(StatusWindowPurpose purpose) { @@ -753,9 +756,9 @@ static void alarm_window_load() { (WindowHandlers){.load = drop_menu_window_load, .unload = drop_menu_window_unload}); // setup vibes - static const uint32_t VIBE_ON_FLOOR = 120; // ms: below this the motor never spins up + static const uint32_t VIBE_ON_FLOOR = 120; // ensure motor spins up enough to be felt static const uint32_t VIBE_ON_SCALE = 4; - static const uint32_t VIBE_GAP = 40; // short off-time -> reads as continuous buzzing + static const uint32_t VIBE_GAP = 40; s_vibe_segments[0] = VIBE_ON_FLOOR + (uint32_t)s_triangle_layer->angle_A * VIBE_ON_SCALE; s_vibe_segments[1] = VIBE_GAP; s_vibe_segments[2] = VIBE_ON_FLOOR + (uint32_t)s_triangle_layer->angle_B * VIBE_ON_SCALE; diff --git a/src/c/main.h b/src/c/main.h index 97c186b..15d84ad 100644 --- a/src/c/main.h +++ b/src/c/main.h @@ -7,5 +7,3 @@ typedef enum STATUS_SET_FAILURE = 2, STATUS_MATH_FAILURE = 3 } StatusWindowPurpose; - -static void push_setter_window();