🚸 Update LCD Manual Leveling display (#26088)

This commit is contained in:
lukasradek 2023-08-07 05:08:35 +02:00 committed by GitHub
parent 1dd3c9e73f
commit b956001d81
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 6 additions and 6 deletions

View file

@ -422,7 +422,7 @@ void MarlinUI::draw_status_message(const bool blink) {
const dwin_coord_t by = (row * MENU_LINE_HEIGHT) + MENU_FONT_HEIGHT + EXTRA_ROW_HEIGHT / 2;
dwinDrawString(true, font16x32, COLOR_YELLOW, COLOR_BG_BLACK, (LCD_PIXEL_WIDTH - vallen * 16) / 2, by, S(dwin_string.string()));
if (ui.can_show_slider()) {
if (ui.can_show_slider() && maxEditValue > 0) {
const dwin_coord_t slider_length = LCD_PIXEL_WIDTH - TERN(DWIN_MARLINUI_LANDSCAPE, 120, 20),
slider_height = 16,

View file

@ -139,8 +139,8 @@
void _lcd_level_bed_moving() {
if (ui.should_draw()) {
MString<9> msg;
msg.setf(F("%i / %u"), int(manual_probe_index + 1), total_probe_points);
MenuEditItemBase::draw_edit_screen(GET_TEXT_F(MSG_LEVEL_BED_NEXT_POINT), &msg);
msg.setf(F(" %i / %u"), int(manual_probe_index + 1), total_probe_points);
MenuItem_static::draw(LCD_HEIGHT / 2, GET_TEXT_F(MSG_LEVEL_BED_NEXT_POINT), SS_CENTER, msg);
}
ui.refresh(LCDVIEW_CALL_NO_REDRAW);
if (!ui.wait_for_move) ui.goto_screen(_lcd_level_bed_get_z);

View file

@ -113,8 +113,8 @@ void xatc_wizard_menu() {
void xatc_wizard_moving() {
if (ui.should_draw()) {
MString<9> msg;
msg.setf(F("%i / %u"), manual_probe_index + 1, XATC_MAX_POINTS);
MenuEditItemBase::draw_edit_screen(GET_TEXT_F(MSG_LEVEL_BED_NEXT_POINT), &msg);
msg.setf(F(" %i / %u"), manual_probe_index + 1, XATC_MAX_POINTS);
MenuItem_static::draw(LCD_HEIGHT / 2, GET_TEXT_F(MSG_LEVEL_BED_NEXT_POINT), SS_CENTER, msg);
}
ui.refresh(LCDVIEW_CALL_NO_REDRAW);
if (!ui.wait_for_move) ui.goto_screen(xatc_wizard_menu);

View file

@ -429,7 +429,7 @@ void MenuEditItemBase::draw_edit_screen(FSTR_P const fstr, const char * const va
}
#endif
if (ui.can_show_slider()) {
if (ui.can_show_slider() && maxEditValue > 0) {
tft.canvas((TFT_WIDTH - SLIDER_W) / 2, SLIDER_Y, SLIDER_W, 16);
tft.set_background(COLOR_BACKGROUND);