CLOCK_FACE_24H_ONLY hides the preference to change the setting and defaults the mode to 24Hr mode

This commit is contained in:
David Volovskiy 2024-07-08 18:32:41 -04:00
parent 226cda748c
commit b923d50652
3 changed files with 7 additions and 6 deletions

View File

@ -377,7 +377,11 @@ void app_init(void) {
memset(&movement_state, 0, sizeof(movement_state));
#ifdef CLOCK_FACE_24H_ONLY
movement_state.settings.bit.clock_mode_24h = true;
#else
movement_state.settings.bit.clock_mode_24h = MOVEMENT_DEFAULT_24H_MODE;
#endif
movement_state.settings.bit.led_red_color = MOVEMENT_DEFAULT_RED_COLOR;
movement_state.settings.bit.led_green_color = MOVEMENT_DEFAULT_GREEN_COLOR;
movement_state.settings.bit.button_should_sound = MOVEMENT_DEFAULT_BUTTON_SOUND;

View File

@ -42,10 +42,6 @@
#define CLOCK_FACE_LOW_BATTERY_VOLTAGE_THRESHOLD 2200
#endif
#ifndef CLOCK_FACE_24H_ONLY
#define CLOCK_FACE_24H_ONLY 0
#endif
typedef struct {
struct {
watch_date_time previous;
@ -57,7 +53,6 @@ typedef struct {
} clock_state_t;
static bool clock_is_in_24h_mode(movement_settings_t *settings) {
if (CLOCK_FACE_24H_ONLY) { return true; }
return settings->bit.clock_mode_24h;
}

View File

@ -99,7 +99,9 @@ bool preferences_face_loop(movement_event_t event, movement_settings_t *settings
default:
return movement_default_loop_handler(event, settings);
}
#ifdef CLOCK_FACE_24H_ONLY
if (current_page == 0) current_page++; // Skips past 12/24HR mode
#endif
watch_display_string((char *)preferences_face_titles[current_page], 0);
// blink active setting on even-numbered quarter-seconds