🎨 ExtUI "user click" and other tweaks (#22122)

Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com>
This commit is contained in:
InsanityAutomation
2021-06-13 23:08:46 -04:00
committed by GitHub
parent ef321cb723
commit a3e8bb99e4
8 changed files with 125 additions and 103 deletions

View File

@@ -474,9 +474,6 @@ public:
static void set_selection(const bool sel) { selection = sel; }
static bool update_selection();
static bool lcd_clicked;
static bool use_click();
static void synchronize(PGM_P const msg=nullptr);
static screenFunc_t currentScreen;
@@ -527,12 +524,23 @@ public:
#elif HAS_WIRED_LCD
static constexpr bool lcd_clicked = false;
static constexpr bool on_status_screen() { return true; }
FORCE_INLINE static void run_current_screen() { status_screen(); }
#endif
#if EITHER(HAS_LCD_MENU, EXTENSIBLE_UI)
static bool lcd_clicked;
static inline bool use_click() {
const bool click = lcd_clicked;
lcd_clicked = false;
return click;
}
#else
static constexpr bool lcd_clicked = false;
static inline bool use_click() { return false; }
#endif
#if BOTH(HAS_LCD_MENU, ADVANCED_PAUSE_FEATURE)
static void pause_show_message(const PauseMessage message, const PauseMode mode=PAUSE_MODE_SAME, const uint8_t extruder=active_extruder);
#else