change light mode

day/night/simulation

Signed-off-by: Peter Siegmund <developer@mars3142.org>
This commit is contained in:
2026-01-18 16:09:09 +01:00
parent ccdc2bb63f
commit 3f32b791b7
6 changed files with 87 additions and 15 deletions

View File

@@ -130,8 +130,10 @@ static void init_ui(void)
static void on_message_received(const message_t *msg)
{
if (msg && msg->type == MESSAGE_TYPE_SETTINGS && msg->data.settings.type == SETTINGS_TYPE_BOOL &&
std::strcmp(msg->data.settings.key, "light_active") == 0)
if (msg && msg->type == MESSAGE_TYPE_SETTINGS &&
(std::strcmp(msg->data.settings.key, "light_active") == 0 ||
std::strcmp(msg->data.settings.key, "light_variant") == 0 ||
std::strcmp(msg->data.settings.key, "light_mode") == 0))
{
start_simulation();
}