fix: change [M]=Discover hint to [Enter]=Discover in NearbyScreen

[M] key doesn't exist on the device; context menu is long-press Enter.
Also handle KEY_ENTER directly when the list is empty so the hint
is accurate — pressing Enter with no contacts enters discover mode
without going through the context menu.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Jakub
2026-05-21 08:13:13 +02:00
parent d851043059
commit 64098bc4dc

View File

@@ -328,7 +328,7 @@ public:
if (_count == 0) {
display.drawTextCentered(display.width() / 2, 28, "No contacts found");
display.drawTextCentered(display.width() / 2, 40, "[M]=Discover");
display.drawTextCentered(display.width() / 2, 40, "[Enter]=Discover");
} else {
for (int i = 0; i < VISIBLE && (_scroll + i) < _count; i++) {
int idx = _scroll + i;
@@ -411,6 +411,7 @@ public:
if (_sel >= _scroll + VISIBLE) _scroll = _sel - VISIBLE + 1;
return true;
}
if (c == KEY_ENTER && _count == 0) { enterDiscoverMode(); return true; }
if (c == KEY_ENTER && _count > 0) {
_detail = true;
_detail_refresh_ms = millis();