mirror of
https://github.com/MarekZegare4/MeshCore-Solo.git
synced 2026-07-26 14:58:12 +00:00
pageBit/bitToPage in HomeScreen and homePageBitIndex in SettingsScreen each spelled out the bit assignment with magic numbers 0..10. Lift the numbering into a NodePrefs::HomePageBit enum (HPB_CLOCK … HPB_QUICK_MSG, HPB_COUNT) and route every reference through it: mapping functions, the HP_* bitmasks, the homePageLabel table sizing, loop bounds over page_order, the bounds check on page_order[0], the "always-visible" discriminator for SETTINGS/QUICK_MSG. Per-class enums (HomeScreen::HomePage, SettingsScreen::SettingItem) stay — they index different concerns (navigation page vs. settings row). The mapping functions still exist, but now reference a single source of truth for the bit values. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>