From 51d1e0bd8a533409d9eae4f44349abd1d8c76da2 Mon Sep 17 00:00:00 2001 From: 3d-gussner <3d.gussner@gmail.com> Date: Tue, 26 Jan 2021 10:42:56 +0100 Subject: [PATCH] Remove duplicate string `G-code sliced for a different printer type. Continue?` using `MSG_GCODE_DIFF_PRINTER_CONTINUE` --- Firmware/messages.c | 1 + Firmware/messages.h | 1 + Firmware/util.cpp | 4 ++-- lang/lang_en.txt | 2 +- lang/lang_en_cz.txt | 2 +- lang/lang_en_de.txt | 2 +- lang/lang_en_es.txt | 2 +- lang/lang_en_fr.txt | 2 +- lang/lang_en_it.txt | 2 +- lang/lang_en_pl.txt | 2 +- 10 files changed, 11 insertions(+), 9 deletions(-) diff --git a/Firmware/messages.c b/Firmware/messages.c index 433f2e7f..bd1d8155 100644 --- a/Firmware/messages.c +++ b/Firmware/messages.c @@ -130,6 +130,7 @@ const char MSG_STRICT[] PROGMEM_I1 = ISTR("Strict"); //// const char MSG_MODEL[] PROGMEM_I1 = ISTR("Model"); //// const char MSG_FIRMWARE[] PROGMEM_I1 = ISTR("Firmware"); //// const char MSG_GCODE[] PROGMEM_I1 = ISTR("Gcode"); //// +const char MSG_GCODE_DIFF_PRINTER_CONTINUE[] PROGMEM_I1 = ISTR("G-code sliced for a different printer type. Continue?"); ////c=20 r=5 const char MSG_NOZZLE_DIAMETER[] PROGMEM_I1 = ISTR("Nozzle d."); //// const char MSG_MMU_MODE[] PROGMEM_I1 = ISTR("MMU Mode"); //// const char MSG_SD_CARD[] PROGMEM_I1 = ISTR("SD card"); //// diff --git a/Firmware/messages.h b/Firmware/messages.h index e397ea0a..11f73183 100644 --- a/Firmware/messages.h +++ b/Firmware/messages.h @@ -130,6 +130,7 @@ extern const char MSG_STRICT[]; extern const char MSG_MODEL[]; extern const char MSG_FIRMWARE[]; extern const char MSG_GCODE[]; +extern const char MSG_GCODE_DIFF_PRINTER_CONTINUE[]; extern const char MSG_NOZZLE_DIAMETER[]; extern const char MSG_MMU_MODE[]; extern const char MSG_SD_CARD[]; diff --git a/Firmware/util.cpp b/Firmware/util.cpp index aac72ee0..325db466 100644 --- a/Firmware/util.cpp +++ b/Firmware/util.cpp @@ -428,7 +428,7 @@ switch(oCheckModel) { case ClCheckModel::_Warn: // lcd_show_fullscreen_message_and_wait_P(_i("Printer model differs from the G-code. Continue?")); -lcd_display_message_fullscreen_P(_i("G-code sliced for a different printer type. Continue?")); +lcd_display_message_fullscreen_P(_T(MSG_GCODE_DIFF_PRINTER_CONTINUE)); lcd_wait_for_click_delay(MSG_PRINT_CHECKING_FAILED_TIMEOUT); //???custom_message_type=CUSTOM_MSG_TYPE_STATUS; // display / status-line recovery lcd_update_enable(true); // display / status-line recovery @@ -577,7 +577,7 @@ switch(oCheckModel) { case ClCheckModel::_Warn: // lcd_show_fullscreen_message_and_wait_P(_i("Printer model differs from the G-code. Continue?")); -lcd_display_message_fullscreen_P(_i("G-code sliced for a different printer type. Continue?")); +lcd_display_message_fullscreen_P(_T(MSG_GCODE_DIFF_PRINTER_CONTINUE)); lcd_wait_for_click_delay(MSG_PRINT_CHECKING_FAILED_TIMEOUT); //???custom_message_type=CUSTOM_MSG_TYPE_STATUS; // display / status-line recovery lcd_update_enable(true); // display / status-line recovery diff --git a/lang/lang_en.txt b/lang/lang_en.txt index 21688a9d..207d0846 100644 --- a/lang/lang_en.txt +++ b/lang/lang_en.txt @@ -1045,7 +1045,7 @@ # "G-code sliced for a different level. Please re-slice the model again. Print cancelled." -# +#MSG_GCODE_DIFF_PRINTER_CONTINUE c=20 r=5 "G-code sliced for a different printer type. Continue?" # diff --git a/lang/lang_en_cz.txt b/lang/lang_en_cz.txt index 6be8dba7..320d2b99 100644 --- a/lang/lang_en_cz.txt +++ b/lang/lang_en_cz.txt @@ -1394,7 +1394,7 @@ "G-code sliced for a different level. Please re-slice the model again. Print cancelled." "\x00" -# +#MSG_GCODE_DIFF_PRINTER_CONTINUE c=20 r=5 "G-code sliced for a different printer type. Continue?" "G-code je pripraven pro jiny typ tiskarny. Pokracovat?" diff --git a/lang/lang_en_de.txt b/lang/lang_en_de.txt index 65c78d7c..9967e6d8 100644 --- a/lang/lang_en_de.txt +++ b/lang/lang_en_de.txt @@ -1394,7 +1394,7 @@ "G-code sliced for a different level. Please re-slice the model again. Print cancelled." "G-Code ist fuer einen anderen Level geslict. Bitte slicen Sie das Modell erneut. Druck abgebrochen." -# +#MSG_GCODE_DIFF_PRINTER_CONTINUE c=20 r=5 "G-code sliced for a different printer type. Continue?" "G-Code ist fuer einen anderen Drucker geslict. Fortfahren?" diff --git a/lang/lang_en_es.txt b/lang/lang_en_es.txt index e009c3f9..d2837bc9 100644 --- a/lang/lang_en_es.txt +++ b/lang/lang_en_es.txt @@ -1394,7 +1394,7 @@ "G-code sliced for a different level. Please re-slice the model again. Print cancelled." "Codigo G laminado para un nivel diferente. Por favor relamina el modelo de nuevo. Impresion cancelada." -# +#MSG_GCODE_DIFF_PRINTER_CONTINUE c=20 r=5 "G-code sliced for a different printer type. Continue?" "Codigo G laminado para un tipo de impresora diferente. ?Continuar?" diff --git a/lang/lang_en_fr.txt b/lang/lang_en_fr.txt index dfc7c1dc..8b6f88c5 100644 --- a/lang/lang_en_fr.txt +++ b/lang/lang_en_fr.txt @@ -1394,7 +1394,7 @@ "G-code sliced for a different level. Please re-slice the model again. Print cancelled." "Le G-code a ete prepare pour un niveau different. Veuillez decouper le modele a nouveau. L'impression a ete annulee." -# +#MSG_GCODE_DIFF_PRINTER_CONTINUE c=20 r=5 "G-code sliced for a different printer type. Continue?" "Le G-code a ete prepare pour une autre version de l'imprimante. Continuer?" diff --git a/lang/lang_en_it.txt b/lang/lang_en_it.txt index 336efb68..b36c7a39 100644 --- a/lang/lang_en_it.txt +++ b/lang/lang_en_it.txt @@ -1394,7 +1394,7 @@ "G-code sliced for a different level. Please re-slice the model again. Print cancelled." "G-code processato per un livello diverso. Per favore esegui nuovamente lo slice del modello. Stampa annullata." -# +#MSG_GCODE_DIFF_PRINTER_CONTINUE c=20 r=5 "G-code sliced for a different printer type. Continue?" "G-code processato per una stampante diversa. Continuare?" diff --git a/lang/lang_en_pl.txt b/lang/lang_en_pl.txt index 2feacf14..cc78b676 100644 --- a/lang/lang_en_pl.txt +++ b/lang/lang_en_pl.txt @@ -1394,7 +1394,7 @@ "G-code sliced for a different level. Please re-slice the model again. Print cancelled." "G-code pociety na innym poziomie. Potnij model ponownie. Druk anulowany." -# +#MSG_GCODE_DIFF_PRINTER_CONTINUE c=20 r=5 "G-code sliced for a different printer type. Continue?" "G-code pociety dla innej drukarki. Kontynuowac?"