|
@@ -1110,23 +1110,24 @@ static void lcd_control_volumetric_menu() {
|
1110
|
1110
|
#ifdef HAS_LCD_CONTRAST
|
1111
|
1111
|
static void lcd_set_contrast() {
|
1112
|
1112
|
if (encoderPosition != 0) {
|
1113
|
|
-#ifdef ELB_FULL_GRAPHIC_CONTROLLER
|
1114
|
|
- lcd_contrast += encoderPosition;
|
1115
|
|
- lcd_contrast &= 0xFF;
|
1116
|
|
-#else
|
1117
|
|
- lcd_contrast -= encoderPosition;
|
1118
|
|
- lcd_contrast &= 0x3F;
|
1119
|
|
-#endif
|
|
1113
|
+ #ifdef U8GLIB_ST7920
|
|
1114
|
+ lcd_contrast += encoderPosition;
|
|
1115
|
+ lcd_contrast &= 0xFF;
|
|
1116
|
+ #else
|
|
1117
|
+ lcd_contrast -= encoderPosition;
|
|
1118
|
+ lcd_contrast &= 0x3F;
|
|
1119
|
+ #endif
|
1120
|
1120
|
encoderPosition = 0;
|
1121
|
1121
|
lcdDrawUpdate = 1;
|
1122
|
1122
|
u8g.setContrast(lcd_contrast);
|
1123
|
1123
|
}
|
1124
|
|
- if (lcdDrawUpdate)
|
1125
|
|
-#ifdef ELB_FULL_GRAPHIC_CONTROLLER
|
1126
|
|
- lcd_implementation_drawedit(PSTR(MSG_CONTRAST), itostr3(lcd_contrast));
|
1127
|
|
-#else
|
1128
|
|
- lcd_implementation_drawedit(PSTR(MSG_CONTRAST), itostr2(lcd_contrast));
|
1129
|
|
-#endif
|
|
1124
|
+ if (lcdDrawUpdate) {
|
|
1125
|
+ #ifdef U8GLIB_ST7920
|
|
1126
|
+ lcd_implementation_drawedit(PSTR(MSG_CONTRAST), itostr3(lcd_contrast));
|
|
1127
|
+ #else
|
|
1128
|
+ lcd_implementation_drawedit(PSTR(MSG_CONTRAST), itostr2(lcd_contrast));
|
|
1129
|
+ #endif
|
|
1130
|
+ }
|
1130
|
1131
|
if (LCD_CLICKED) lcd_goto_menu(lcd_control_menu);
|
1131
|
1132
|
}
|
1132
|
1133
|
#endif // HAS_LCD_CONTRAST
|