Retract on top layer option. (#6188)

Co-authored-by: SoftFever <softfeverever@gmail.com>
This commit is contained in:
Vovodroid 2024-11-23 17:23:04 +02:00 committed by GitHub
parent 717fe35ebd
commit ca35ba4107
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 20 additions and 8 deletions

View file

@ -4322,6 +4322,7 @@ if (is_marlin_flavor)
optgroup->append_single_option_line("deretraction_speed", "", extruder_idx);
optgroup->append_single_option_line("retraction_minimum_travel", "", extruder_idx);
optgroup->append_single_option_line("retract_when_changing_layer", "", extruder_idx);
optgroup->append_single_option_line("retract_on_top_layer", "", extruder_idx);
optgroup->append_single_option_line("wipe", "", extruder_idx);
optgroup->append_single_option_line("wipe_distance", "", extruder_idx);
optgroup->append_single_option_line("retract_before_wipe", "", extruder_idx);
@ -4538,7 +4539,7 @@ void TabPrinter::toggle_options()
// user can customize other retraction options if retraction is enabled
//BBS
bool retraction = have_retract_length || use_firmware_retraction;
std::vector<std::string> vec = { "z_hop", "retract_when_changing_layer" };
std::vector<std::string> vec = {"z_hop", "retract_when_changing_layer", "retract_on_top_layer"};
for (auto el : vec)
toggle_option(el, retraction, i);