Squish lcd_advanced_pause_show_message
This commit is contained in:
parent
3b3b7e09ec
commit
3d34dddbc0
@ -4538,6 +4538,24 @@ void kill_screen(const char* lcd_msg) {
|
|||||||
END_SCREEN();
|
END_SCREEN();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
FORCE_INLINE screenFunc_t ap_message_screen(const AdvancedPauseMessage message) {
|
||||||
|
switch (message) {
|
||||||
|
case ADVANCED_PAUSE_MESSAGE_INIT: return lcd_advanced_pause_init_message;
|
||||||
|
case ADVANCED_PAUSE_MESSAGE_UNLOAD: return lcd_advanced_pause_unload_message;
|
||||||
|
case ADVANCED_PAUSE_MESSAGE_INSERT: return lcd_advanced_pause_insert_message;
|
||||||
|
case ADVANCED_PAUSE_MESSAGE_LOAD: return lcd_advanced_pause_load_message;
|
||||||
|
case ADVANCED_PAUSE_MESSAGE_PURGE: return lcd_advanced_pause_purge_message;
|
||||||
|
case ADVANCED_PAUSE_MESSAGE_RESUME: return lcd_advanced_pause_resume_message;
|
||||||
|
case ADVANCED_PAUSE_MESSAGE_CLICK_TO_HEAT_NOZZLE: return lcd_advanced_pause_heat_nozzle;
|
||||||
|
case ADVANCED_PAUSE_MESSAGE_WAIT_FOR_NOZZLES_TO_HEAT: return lcd_advanced_pause_wait_for_nozzles_to_heat;
|
||||||
|
case ADVANCED_PAUSE_MESSAGE_OPTION: advanced_pause_menu_response = ADVANCED_PAUSE_RESPONSE_WAIT_FOR;
|
||||||
|
return lcd_advanced_pause_option_menu;
|
||||||
|
case ADVANCED_PAUSE_MESSAGE_STATUS:
|
||||||
|
default: break;
|
||||||
|
}
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
void lcd_advanced_pause_show_message(
|
void lcd_advanced_pause_show_message(
|
||||||
const AdvancedPauseMessage message,
|
const AdvancedPauseMessage message,
|
||||||
const AdvancedPauseMode mode/*=ADVANCED_PAUSE_MODE_PAUSE_PRINT*/,
|
const AdvancedPauseMode mode/*=ADVANCED_PAUSE_MODE_PAUSE_PRINT*/,
|
||||||
@ -4545,48 +4563,13 @@ void kill_screen(const char* lcd_msg) {
|
|||||||
) {
|
) {
|
||||||
advanced_pause_mode = mode;
|
advanced_pause_mode = mode;
|
||||||
hotend_status_extruder = extruder;
|
hotend_status_extruder = extruder;
|
||||||
switch (message) {
|
const screenFunc_t next_screen = ap_message_screen(message);
|
||||||
case ADVANCED_PAUSE_MESSAGE_INIT:
|
if (next_screen) {
|
||||||
defer_return_to_status = true;
|
defer_return_to_status = true;
|
||||||
lcd_goto_screen(lcd_advanced_pause_init_message);
|
lcd_goto_screen(next_screen);
|
||||||
break;
|
|
||||||
case ADVANCED_PAUSE_MESSAGE_UNLOAD:
|
|
||||||
defer_return_to_status = true;
|
|
||||||
lcd_goto_screen(lcd_advanced_pause_unload_message);
|
|
||||||
break;
|
|
||||||
case ADVANCED_PAUSE_MESSAGE_INSERT:
|
|
||||||
defer_return_to_status = true;
|
|
||||||
lcd_goto_screen(lcd_advanced_pause_insert_message);
|
|
||||||
break;
|
|
||||||
case ADVANCED_PAUSE_MESSAGE_LOAD:
|
|
||||||
defer_return_to_status = true;
|
|
||||||
lcd_goto_screen(lcd_advanced_pause_load_message);
|
|
||||||
break;
|
|
||||||
case ADVANCED_PAUSE_MESSAGE_PURGE:
|
|
||||||
defer_return_to_status = true;
|
|
||||||
lcd_goto_screen(lcd_advanced_pause_purge_message);
|
|
||||||
break;
|
|
||||||
case ADVANCED_PAUSE_MESSAGE_CLICK_TO_HEAT_NOZZLE:
|
|
||||||
defer_return_to_status = true;
|
|
||||||
lcd_goto_screen(lcd_advanced_pause_heat_nozzle);
|
|
||||||
break;
|
|
||||||
case ADVANCED_PAUSE_MESSAGE_WAIT_FOR_NOZZLES_TO_HEAT:
|
|
||||||
defer_return_to_status = true;
|
|
||||||
lcd_goto_screen(lcd_advanced_pause_wait_for_nozzles_to_heat);
|
|
||||||
break;
|
|
||||||
case ADVANCED_PAUSE_MESSAGE_OPTION:
|
|
||||||
defer_return_to_status = true;
|
|
||||||
advanced_pause_menu_response = ADVANCED_PAUSE_RESPONSE_WAIT_FOR;
|
|
||||||
lcd_goto_screen(lcd_advanced_pause_option_menu);
|
|
||||||
break;
|
|
||||||
case ADVANCED_PAUSE_MESSAGE_RESUME:
|
|
||||||
defer_return_to_status = true;
|
|
||||||
lcd_goto_screen(lcd_advanced_pause_resume_message);
|
|
||||||
break;
|
|
||||||
case ADVANCED_PAUSE_MESSAGE_STATUS:
|
|
||||||
lcd_return_to_status();
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
lcd_return_to_status();
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif // ADVANCED_PAUSE_FEATURE
|
#endif // ADVANCED_PAUSE_FEATURE
|
||||||
|
Loading…
Reference in New Issue
Block a user