perf(l2): long lists fill in over several loop passes

A widget costs ~1 ms on the L2, so Nodes with 48 rows held the screen for
~600 ms and a full contact list for over a second. fillStart() builds the
first screenful at once and fillTick() adds the rest ~25 ms a pass.

- Nodes: 6 rows first; the 2 s refresh rewrites built rows in place
- New message: contacts filled the same way
- Settings: a group at a time (all at once when coming back scrolled)
- Nodes 671 -> ~200 ms, Settings 376 -> ~190 ms longest UI stall

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Jakub
2026-09-30 00:24:57 +02:00
co-authored by Claude Opus 5.5
parent 247fab08d0
commit 34f739c45b
2 changed files with 179 additions and 97 deletions
@@ -322,7 +322,12 @@ private:
void homeSwipePoll();
void buildChats();
void buildContacts();
void contactRow(int i);
void fillStart(lv_obj_t* list, int n, int first, void (UITask::*row)(int));
void fillTick();
void buildSettings();
static const int SETTINGS_GROUPS = 5;
void settingsGroup(int i);
void buildSchemaSettings();
void schemaRows(lv_obj_t* body, uint8_t page);
void showMapOptions(uint8_t section);
@@ -338,6 +343,8 @@ private:
bool wifiInUse() const; // a map download or an update holds the WiFi
void buildNearby();
void refreshNearbyList();
void nearbyRow(int i);
void nearbyRowSet(lv_obj_t* row, int i);
uint32_t nearbySignature() const;
void showScanPopup();
void refreshScanPopup();