Add Switch BackLight action

This commit is contained in:
Armel FAUVEAU
2024-03-11 02:48:21 +01:00
parent f31e8c319e
commit ad3b8b5b9a
13 changed files with 53 additions and 14 deletions

View File

@@ -424,6 +424,7 @@ const t_sidefunction gSubMenu_SIDEFUNCTIONS[] =
{"SWITCH\nRX MODE", ACTION_OPT_RXMODE},
{"SWITCH\nPTT", ACTION_OPT_PTT},
{"SWITCH\nWIDE\nNARROW", ACTION_OPT_WN},
{"SWITCH\nBACKLIGHT", ACTION_OPT_BACKLIGHT},
#endif
};

View File

@@ -160,11 +160,6 @@ void UI_DisplayStatus()
x1 = x;
}
else if (gWasFKeyPressed) {
/*
memcpy(line + x, gFontF, sizeof(gFontF));
x += sizeof(gFontF);
*/
UI_PrintStringSmallBufferNormal("F", line + x + 1);
x += sizeof(gFontKeyLock);
@@ -174,6 +169,12 @@ void UI_DisplayStatus()
}
x1 = x;
}
else if(gBackLight)
{
memcpy(line + x + 1, gFontLight, sizeof(gFontLight));
x += sizeof(gFontLight);
x1 = x;
}
{ // battery voltage or percentage
char s[8] = "";