Add icon rendering and list scroll gesture support
Implement orientation-aware icon rendering using freeink::Icon format that applies rotation transforms per-pixel. Add wasListScroll helper for touch-based list navigation with swipe gestures. Switch vertical centering from x-height to cap-height for better visual alignment with capital-led UI labels.
This commit is contained in:
@@ -409,6 +409,14 @@ void WifiSelectionActivity::loop() {
|
||||
|
||||
// Handle network list state
|
||||
if (state == WifiSelectionState::NETWORK_LIST) {
|
||||
// Vertical swipe page-scrolls the network list (touch nav without the side buttons).
|
||||
int scrollIdx = static_cast<int>(selectedNetworkIndex);
|
||||
if (mappedInput.wasListScroll(scrollIdx, static_cast<int>(networks.size()),
|
||||
UITheme::getInstance().getNumberOfItemsPerPage(renderer, true, false, true, false))) {
|
||||
selectedNetworkIndex = scrollIdx;
|
||||
requestUpdate();
|
||||
return;
|
||||
}
|
||||
// Touch: down-select highlights the pressed network, tap selects it (like Confirm).
|
||||
int downId = -1;
|
||||
if (mappedInput.wasItemTouchedDown(downId) && downId >= 0 && downId < static_cast<int>(networks.size())) {
|
||||
|
||||
Reference in New Issue
Block a user