From 7a28f90dad264c969304187591a69755f2083f90 Mon Sep 17 00:00:00 2001 From: Cache8063 Date: Wed, 11 Mar 2026 18:35:48 -0500 Subject: [PATCH] fix: back button in settings returns to tab bar first (#1354) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## Summary - Pressing Back while browsing settings within a category now jumps focus to the category tab bar - Pressing Back again from the tab bar exits settings to home - Previously, Back always exited directly to home regardless of scroll position Closes #797 ## Test plan - [ ] Scroll deep into a settings category → press Back → tab bar is focused - [ ] Press Back again from tab bar → exits to home screen - [ ] Use category switching (continuous hold) → still works as before - [ ] Settings are saved on exit (not on tab-bar jump) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: bkb Co-authored-by: Claude Opus 4.6 --- src/activities/settings/SettingsActivity.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/activities/settings/SettingsActivity.cpp b/src/activities/settings/SettingsActivity.cpp index 659fd3e5..85e866e2 100644 --- a/src/activities/settings/SettingsActivity.cpp +++ b/src/activities/settings/SettingsActivity.cpp @@ -89,8 +89,13 @@ void SettingsActivity::loop() { } if (mappedInput.wasPressed(MappedInputManager::Button::Back)) { - SETTINGS.saveToFile(); - onGoHome(); + if (selectedSettingIndex > 0) { + selectedSettingIndex = 0; + requestUpdate(); + } else { + SETTINGS.saveToFile(); + onGoHome(); + } return; }