fix(color): Lua scripts do not see selected language when using ALL_LANGS build (#6937)

This commit is contained in:
philmoz
2026-01-04 08:09:34 +10:00
committed by GitHub
parent 900ce6316e
commit d96ddbb8a7
2 changed files with 16 additions and 1 deletions
+8 -1
View File
@@ -110,7 +110,14 @@ void LuaWidgetFactory::translateOptions(WidgetOption * options)
// No translations provided
if (!translateFunction) return;
auto lang = TRANSLATIONS;
#if defined(ALL_LANGS)
char lang[3];
lang[0] = toupper(g_eeGeneral.ttsLanguage[0]);
lang[1] = toupper(g_eeGeneral.ttsLanguage[1]);
lang[2] = 0;
#else
char* lang = TRANSLATIONS;
#endif
auto option = options;
while (option && option->name != nullptr) {