Browse Source

Fix lcd_custom_bootscreen compiler warning

Scott Lahteine 7 years ago
parent
commit
19ba91f77a
1 changed files with 5 additions and 3 deletions
  1. 5
    3
      Marlin/src/lcd/ultralcd_impl_DOGM.h

+ 5
- 3
Marlin/src/lcd/ultralcd_impl_DOGM.h View File

@@ -296,9 +296,11 @@ void lcd_printPGM_utf(const char *str, uint8_t n=LCD_WIDTH) {
296 296
 
297 297
     void lcd_custom_bootscreen() {
298 298
       constexpr u8g_uint_t left = (LCD_PIXEL_WIDTH  - (CUSTOM_BOOTSCREEN_BMPWIDTH)) / 2,
299
-                           top = (LCD_PIXEL_HEIGHT - (CUSTOM_BOOTSCREEN_BMPHEIGHT)) / 2,
300
-                           right = left + CUSTOM_BOOTSCREEN_BMPWIDTH,
301
-                           bottom = top + CUSTOM_BOOTSCREEN_BMPHEIGHT;
299
+                           top = (LCD_PIXEL_HEIGHT - (CUSTOM_BOOTSCREEN_BMPHEIGHT)) / 2;
300
+      #if ENABLED(CUSTOM_BOOTSCREEN_INVERTED)
301
+        constexpr u8g_uint_t right = left + CUSTOM_BOOTSCREEN_BMPWIDTH,
302
+                            bottom = top + CUSTOM_BOOTSCREEN_BMPHEIGHT;
303
+      #endif
302 304
       u8g.firstPage();
303 305
       do {
304 306
         u8g.drawBitmapP(

Loading…
Cancel
Save