mirror of
https://github.com/pelgraine/Meck.git
synced 2026-08-08 01:32:42 +02:00
T-Watch - fix touch and ui bugs so that ticker scroll display works for longer text rows, and long press to open rx log
This commit is contained in:
@@ -2371,7 +2371,9 @@ public:
|
||||
|
||||
#if defined(MECK_TWATCH)
|
||||
if (selected && tickerPass == 0) {
|
||||
rowTextW = ((LGFXDisplay*)&display)->getCursorX() - rowStartX;
|
||||
// getCursorX() is unusable here: LGFXDisplay::print() calls buffer.println(),
|
||||
// whose newline resets the cursor X to 0. Measure the string directly.
|
||||
rowTextW = display.getTextWidth(tmp);
|
||||
}
|
||||
} // ticker pass loop
|
||||
if (selected) _tickerTextW = rowTextW;
|
||||
|
||||
@@ -2689,6 +2689,13 @@ if (curr) curr->poll();
|
||||
setCurrScreen(watch_channel_cfg_screen);
|
||||
}
|
||||
}
|
||||
// Touch activates rows via injectKey->handleInput, which bypasses the
|
||||
// main.cpp key handler that consumes this flag. Consume it here too so a
|
||||
// watch long-press opens the Rx Log (mirrors wantsWatchChannels above).
|
||||
if (ss->isRxLogRequested()) {
|
||||
ss->clearRxLogRequest();
|
||||
gotoRxLogScreen();
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
Reference in New Issue
Block a user