Browse Source

Hide mesh editing until a valid mesh exists

Scott Lahteine 6 years ago
parent
commit
93d5b945dd
1 changed files with 3 additions and 2 deletions
  1. 3
    2
      Marlin/src/lcd/menu/menu_bed_leveling.cpp

+ 3
- 2
Marlin/src/lcd/menu/menu_bed_leveling.cpp View File

@@ -206,7 +206,7 @@
206 206
     sync_plan_position();
207 207
   }
208 208
 
209
-  void menu_mbl_edit_mesh() {
209
+  void menu_edit_mesh() {
210 210
     static uint8_t xind, yind; // =0
211 211
     START_MENU();
212 212
     MENU_BACK(MSG_BED_LEVELING);
@@ -253,7 +253,8 @@ void menu_bed_leveling() {
253 253
   #endif
254 254
 
255 255
   #if ENABLED(MESH_EDIT_MENU)
256
-    MENU_ITEM(submenu, MSG_EDIT_MESH, menu_mbl_edit_mesh);
256
+    if (leveling_is_valid())
257
+      MENU_ITEM(submenu, MSG_EDIT_MESH, menu_edit_mesh);
257 258
   #endif
258 259
 
259 260
   // Homed and leveling is valid? Then leveling can be toggled.

Loading…
Cancel
Save