feat: FREETEXT 模式添加滚动条和光标移动\n\n- 添加 textScrollOffset 变量跟踪滚动位置\n- UP/DOWN 按钮移动光标\n- 文本输入时自动滚动保持光标可见\n- 绘制滚动条显示当前位置\n- 进入 FREETEXT 时重置滚动偏移"

This commit is contained in:
2026-03-30 21:19:45 +08:00
parent b173fe55d6
commit 24da610e0d
2 changed files with 71 additions and 2 deletions
@@ -181,6 +181,7 @@ class CannedMessageModule : public SinglePortModule, public Observable<const UIF
char highlight = 0x00;
char payload = 0x00;
unsigned int cursor = 0;
unsigned int textScrollOffset = 0; // 文本滚动偏移(用于 FREETEXT 模式)
unsigned long lastTouchMillis = 0;
uint32_t lastFilterUpdate = 0;
static constexpr uint32_t filterDebounceMs = 30;