mirror of
https://github.com/MarekZegare4/MeshCore-Solo.git
synced 2026-11-03 03:11:57 +00:00
fix(ui-lvgl): quick panel over a frozen screen; slider not taken by Home's swipe
- Quick panel: the screen under it is frozen and dimmed in one snapshot
(freeze::early), so the slide redraws an image and the panel; a tap or
swipe up under it closes it and nothing under it takes a touch. Tiles are
two pages of four with dots; tiles restyle only when their state changes.
- Home: a touch that starts on the top layer (the quick panel, the status
bar) is not a page swipe -- a sideways drag of the brightness slider over
Home ended the drag and turned the page under it.
- Keyboard: OK and hide don't put the cursor back on a field whose keyboard
is gone.
- BotScreen: adminRowBox -> centerRow (the sim build broke in 3293ac09).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -491,7 +491,14 @@ void UITask::homeSwipePoll() {
|
||||
lv_point_t p;
|
||||
lv_indev_get_point(in, &p);
|
||||
if (!down) { home::s_touching = false; return; }
|
||||
if (!home::s_touching) { home::s_touching = true; home::s_swiped = false; home::s_start = p; return; }
|
||||
if (!home::s_touching) {
|
||||
home::s_touching = true;
|
||||
home::s_start = p;
|
||||
// A touch on the top layer (the quick panel's slider, the status bar) isn't
|
||||
// Home's: a sideways drag there would end it and turn the page under it.
|
||||
home::s_swiped = lv_indev_search_obj(lv_layer_top(), &p) != nullptr;
|
||||
return;
|
||||
}
|
||||
if (home::s_swiped || home::s_drag_pos >= 0) return; // a tile being dragged isn't a swipe
|
||||
int dx = p.x - home::s_start.x, dy = p.y - home::s_start.y;
|
||||
if (abs(dx) < home::SWIPE_PX || abs(dx) < 2 * abs(dy)) return;
|
||||
|
||||
Reference in New Issue
Block a user