From e43f7632013dcb312513444512c5f2531b4cbd7d Mon Sep 17 00:00:00 2001 From: cottongin Date: Sun, 8 Mar 2026 04:42:34 -0400 Subject: [PATCH] port: dynamic settings tab label (upstream PR #1325) Adapted from upstream PR #1325 (not yet merged). When focused on the tab bar (selectedSettingIndex == 0), the confirm button label now shows the name of the next category instead of the generic "Toggle" text. If/when #1325 is merged upstream, this commit should be dropped during the next sync and the upstream version used instead. Made-with: Cursor --- src/activities/settings/SettingsActivity.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/activities/settings/SettingsActivity.cpp b/src/activities/settings/SettingsActivity.cpp index d6eaa684..d2983f57 100644 --- a/src/activities/settings/SettingsActivity.cpp +++ b/src/activities/settings/SettingsActivity.cpp @@ -297,7 +297,10 @@ void SettingsActivity::render(RenderLock&&) { true); // Draw help text - const auto labels = mappedInput.mapLabels(tr(STR_BACK), tr(STR_TOGGLE), tr(STR_DIR_UP), tr(STR_DIR_DOWN)); + const auto confirmLabel = (selectedSettingIndex == 0) + ? I18N.get(categoryNames[(selectedCategoryIndex + 1) % categoryCount]) + : tr(STR_TOGGLE); + const auto labels = mappedInput.mapLabels(tr(STR_BACK), confirmLabel, tr(STR_DIR_UP), tr(STR_DIR_DOWN)); GUI.drawButtonHints(renderer, labels.btn1, labels.btn2, labels.btn3, labels.btn4); // Always use standard refresh for settings screen