Reorganize ana display for X7 (#5482)
This commit is contained in:
@@ -51,8 +51,15 @@ void menuRadioDiagKeys(event_t event)
|
||||
|
||||
if (i < 6) {
|
||||
y = MENU_HEADER_HEIGHT + FH + FH*i;
|
||||
#if defined(PCBX7)
|
||||
if (i > 1) {
|
||||
lcdDrawTextAtIndex(0, y, STR_VKEYS, (5-i), 0);
|
||||
displayKeyState(5*FW+4, y, KEY_MENU+(5-i));
|
||||
}
|
||||
#else
|
||||
lcdDrawTextAtIndex(0, y, STR_VKEYS, (5-i), 0);
|
||||
displayKeyState(5*FW+2, y, KEY_MENU+(5-i));
|
||||
#endif
|
||||
}
|
||||
|
||||
#if defined(PCBTARANIS)
|
||||
@@ -60,7 +67,7 @@ void menuRadioDiagKeys(event_t event)
|
||||
if (SWITCH_EXISTS(i)) {
|
||||
getvalue_t val = getValue(MIXSRC_FIRST_SWITCH+i);
|
||||
getvalue_t sw = ((val < 0) ? 3*i+1 : ((val == 0) ? 3*i+2 : 3*i+3));
|
||||
drawSwitch(8*FW, y, sw, 0);
|
||||
drawSwitch(8*FW+4, y, sw, 0);
|
||||
}
|
||||
}
|
||||
#else
|
||||
@@ -74,12 +81,22 @@ void menuRadioDiagKeys(event_t event)
|
||||
|
||||
#if defined(ROTARY_ENCODER_NAVIGATION)
|
||||
for (uint8_t i=0; i<DIM(rotencValue); i++) {
|
||||
|
||||
#if defined(PCBX7)
|
||||
coord_t y = MENU_HEADER_HEIGHT + FH;
|
||||
coord_t x = 6*FW+3;
|
||||
lcdDrawTextAtIndex(0, MENU_HEADER_HEIGHT + FH , STR_VRENCODERS, i, 0);
|
||||
#else
|
||||
coord_t y = MENU_HEADER_HEIGHT /* ??? + 1 ??? */ + i*FH;
|
||||
coord_t x = 19*FW;
|
||||
lcdDrawTextAtIndex(14*FW, y, STR_VRENCODERS, i, 0);
|
||||
#endif
|
||||
#if defined(ROTARY_ENCODERS)
|
||||
lcdDrawNumber(18*FW, y, rotencValue[i], LEFT|(keyState(BTN_REa+i) ? INVERS : 0));
|
||||
lcdDrawNumber(x, y, rotencValue[i], LEFT|(keyState(BTN_REa+i) ? INVERS : 0));
|
||||
#elif defined(PCBX7)
|
||||
lcdDrawNumber(x, y, rotencValue[i], RIGHT);
|
||||
#else
|
||||
lcdDrawNumber(18*FW, y, rotencValue[i], LEFT);
|
||||
lcdDrawNumber(x, y, rotencValue[i], LEFT);
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user