Skip to content

Commit 22a6b5d

Browse files
rhapsodyvvgadreau
authored andcommitted
TFT: No timeout on Move Screen (MarlinFirmware#19426)
1 parent 35040ef commit 22a6b5d

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

Marlin/src/lcd/tft/ui_480x320.cpp

+2-8
Original file line numberDiff line numberDiff line change
@@ -956,24 +956,17 @@ static void drawBtn(int x, int y, const char* label, int32_t data, MarlinImage i
956956
uint16_t width = Images[imgBtn52Rounded].width;
957957
uint16_t height = Images[imgBtn52Rounded].height;
958958

959-
tft.queue.sync(); //need sync to change font
960-
961959
if (!enabled) bgColor = COLOR_CONTROL_DISABLED;
962960

963961
tft.canvas(x, y, width, height);
964962
tft.set_background(COLOR_BACKGROUND);
965963
tft.add_image(0, 0, imgBtn52Rounded, bgColor, COLOR_BACKGROUND, COLOR_DARKGREY);
966964

965+
// TODO: Make an add_text() taking a font arg
967966
if (label != NULL) {
968-
tft.set_font(Helvetica12Bold);
969-
tft_string.set_font(Helvetica12Bold);
970967
tft_string.set(label);
971968
tft_string.trim();
972969
tft.add_text(tft_string.center(width), height / 2 - tft_string.font_height() / 2, bgColor, tft_string);
973-
974-
tft.queue.sync();
975-
tft_string.set_font(Helvetica18);
976-
tft.set_font(Helvetica18);
977970
}
978971
else {
979972
tft.add_image(0, 0, img, bgColor, COLOR_BACKGROUND, COLOR_DARKGREY);
@@ -984,6 +977,7 @@ static void drawBtn(int x, int y, const char* label, int32_t data, MarlinImage i
984977

985978
void MarlinUI::move_axis_screen() {
986979
// Reset
980+
defer_status_screen(true);
987981
motionAxisState.blocked = false;
988982
touch.enable();
989983

0 commit comments

Comments
 (0)