Move common strings (#20846)

This commit is contained in:
Scott Lahteine
2021-01-22 15:01:19 -06:00
committed by GitHub
parent 7b9f7d8aba
commit d33fe2378c
38 changed files with 54 additions and 83 deletions

View File

@ -35,8 +35,6 @@
#include "lib/dgus/DGUSDisplayDef.h"
#include "lib/dgus/DGUSScreenHandler.h"
extern const char NUL_STR[];
namespace ExtUI {
void onStartup() {

View File

@ -28,7 +28,7 @@
#include "../../../../libs/numtostr.h"
#include "../../../../module/motion.h" // for quickstop_stepper, A20 read printing speed, feedrate_percentage
#include "../../../../MarlinCore.h" // for disable_steppers, G28_STR
#include "../../../../MarlinCore.h" // for disable_steppers
#include "../../../../inc/MarlinConfig.h"
// command sending macro's with debugging capability

View File

@ -36,7 +36,6 @@ void FilamentRunoutScreen::onRedraw(draw_mode_t what) {
w.toggle( 2, GET_TEXT_F(MSG_RUNOUT_SENSOR), getFilamentRunoutEnabled());
#if HAS_FILAMENT_RUNOUT_DISTANCE
extern const char NUL_STR[];
w.heading(GET_TEXT_F(MSG_RUNOUT_DISTANCE_MM));
w.units(GET_TEXT_F(MSG_UNITS_MM));
w.precision(0);

View File

@ -120,7 +120,6 @@ void StressTestScreen::onIdle() {
if (!commandsInQueue()) {
if (!isPositionKnown()) {
extern const char G28_STR[];
injectCommands_P(G28_STR);
}
else {

View File

@ -31,8 +31,6 @@
#include "../../../../gcode/queue.h"
#include "../../../../inc/MarlinConfig.h"
extern const char G28_STR[];
extern lv_group_t *g;
static lv_obj_t *scr;

View File

@ -29,8 +29,6 @@
#include "../../../../gcode/queue.h"
#include "../../../../inc/MarlinConfig.h"
extern const char G28_STR[];
extern lv_group_t *g;
static lv_obj_t *scr;

View File

@ -21,15 +21,13 @@
*/
#include "../../../../inc/MarlinConfigPre.h"
#if HAS_TFT_LVGL_UI
#if BOTH(HAS_TFT_LVGL_UI, MKS_WIFI_MODULE)
#include "draw_ui.h"
#include "wifi_module.h"
#include "wifi_upload.h"
#include "SPI_TFT.h"
#if ENABLED(MKS_WIFI_MODULE)
#include "../../../../MarlinCore.h"
#include "../../../../module/temperature.h"
#include "../../../../gcode/queue.h"
@ -459,7 +457,6 @@ int package_to_wifi(WIFI_RET_TYPE type, uint8_t *buf, int len) {
return 1;
}
#define SEND_OK_TO_WIFI send_to_wifi((uint8_t *)"ok\r\n", strlen("ok\r\n"))
int send_to_wifi(uint8_t *buf, int len) { return package_to_wifi(WIFI_TRANS_INF, buf, len); }
@ -553,7 +550,6 @@ typedef struct {
uint8_t tail;
} ESP_PROTOC_FRAME;
static int cut_msg_head(uint8_t *msg, uint16_t msgLen, uint16_t cutLen) {
if (msgLen < cutLen) return 0;
@ -1707,7 +1703,6 @@ void mks_esp_wifi_init() {
wifi_link_state = WIFI_NOT_CONFIG;
}
void mks_wifi_firmware_update() {
card.openFileRead((char *)ESP_FIRMWARE_FILE);
@ -1826,5 +1821,4 @@ int readWifiBuf(int8_t *buf, int32_t len) {
return i;
}
#endif // MKS_WIFI_MODULE
#endif // HAS_TFT_LVGL_UI
#endif // HAS_TFT_LVGL_UI && MKS_WIFI_MODULE