1
0
mirror of https://github.com/mist-devel/mist-firmware.git synced 2026-04-17 00:15:25 +00:00

menu: fix 'T' option for >32bit

This commit is contained in:
Gyorgy Szombathelyi
2024-01-04 21:02:40 +01:00
parent 4d0bafff73
commit cc01a3241f

View File

@@ -295,8 +295,8 @@ static char GetMenuItem_8bit(uint8_t idx, char action, menu_item_t *item) {
// check for 'T'oggle strings
if(p && (p[0] == 'T')) {
if (action == MENU_ACT_SEL || action == MENU_ACT_PLUS || action == MENU_ACT_MINUS) {
unsigned long long mask = 1<<getIdx(p);
menu_debugf("Option %s %x\n", p, status ^ mask);
unsigned long long mask = (unsigned long long)1<<getIdx(p);
menu_debugf("Option %s %llx\n", p, status ^ mask);
// change bit
user_io_8bit_set_status(status ^ mask, mask);
// ... and change it again in case of a toggle bit