From: Matheus Afonso Martins Moreira Date: Sun, 8 Sep 2024 21:38:53 +0000 (-0300) Subject: faces/tally: make mtg presets optin via macros X-Git-Url: https://git.earman.xyz/?a=commitdiff_plain;h=531bcfd28593f15476f129056986bccaeea2879b;p=sensor-watch.git faces/tally: make mtg presets optin via macros Use preprocessor macros to conditionally compile in Magic the Gathering initial value presets for the tally mark, thereby making them opt in. --- diff --git a/movement/watch_faces/complication/tally_face.c b/movement/watch_faces/complication/tally_face.c index 3893fc7..fb44df2 100644 --- a/movement/watch_faces/complication/tally_face.c +++ b/movement/watch_faces/complication/tally_face.c @@ -32,7 +32,17 @@ static bool _init_val; static bool _quick_ticks_running; -static const int16_t _tally_default[] = {0, 100, 40, 20, 10}; + +static const int16_t _tally_default[] = { + 0, + +#ifdef TALLY_FACE_PRESETS_MTG + 20, + 40, +#endif /* TALLY_FACE_PRESETS_MTG */ + +}; + static const uint8_t _tally_default_size = sizeof(_tally_default) / sizeof(int16_t); void tally_face_setup(movement_settings_t *settings, uint8_t watch_face_index, void ** context_ptr) {