From 6698db29de554753b1b195ced0d325b9d53f8663 Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Sun, 29 Oct 2017 19:17:32 -0500 Subject: [PATCH] Update LCD draw condition --- Marlin/ultralcd.cpp | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/Marlin/ultralcd.cpp b/Marlin/ultralcd.cpp index b0bb36780..16f2e7b82 100644 --- a/Marlin/ultralcd.cpp +++ b/Marlin/ultralcd.cpp @@ -4745,16 +4745,18 @@ void lcd_update() { // then we want to use 1/2 of the time only. uint16_t bbr2 = planner.block_buffer_runtime() >> 1; - #if ENABLED(DOGLCD) - if ((lcdDrawUpdate || drawing_screen) && (!bbr2 || (bbr2 > max_display_update_time) - #if ENABLED(SDSUPPORT) - || (currentScreen == lcd_sdcard_menu) + if ( + #if ENABLED(DOGLCD) + (lcdDrawUpdate || drawing_screen) && ( + !bbr2 || (bbr2 > max_display_update_time) + #if ENABLED(SDSUPPORT) + || currentScreen == lcd_sdcard_menu + #endif + ) + #else + lcdDrawUpdate && (!bbr2 || (bbr2 > max_display_update_time)) #endif - )) - #else - if (lcdDrawUpdate && (!bbr2 || (bbr2 > max_display_update_time))) - #endif - { + ) { #if ENABLED(DOGLCD) if (!drawing_screen) #endif