Wipe tower: remove 'Purging volumes' button for printers with separate extruders:
the setting really only makes sense for single extruder MM, the others can use filament_minimal_purge_on_wipe_tower
This commit is contained in:
parent
9775bf213d
commit
b14855beda
@ -1352,6 +1352,11 @@ std::vector<std::vector<float>> WipeTower::extract_wipe_volumes(const PrintConfi
|
|||||||
// Get wiping matrix to get number of extruders and convert vector<double> to vector<float>:
|
// Get wiping matrix to get number of extruders and convert vector<double> to vector<float>:
|
||||||
std::vector<float> wiping_matrix(cast<float>(config.wiping_volumes_matrix.values));
|
std::vector<float> wiping_matrix(cast<float>(config.wiping_volumes_matrix.values));
|
||||||
|
|
||||||
|
// The values shall only be used when SEMM is enabled. The purging for other printers
|
||||||
|
// is determined by filament_minimal_purge_on_wipe_tower.
|
||||||
|
if (! config.single_extruder_multi_material.value)
|
||||||
|
std::fill(wiping_matrix.begin(), wiping_matrix.end(), 0.f);
|
||||||
|
|
||||||
// Extract purging volumes for each extruder pair:
|
// Extract purging volumes for each extruder pair:
|
||||||
std::vector<std::vector<float>> wipe_volumes;
|
std::vector<std::vector<float>> wipe_volumes;
|
||||||
const unsigned int number_of_extruders = (unsigned int)(sqrt(wiping_matrix.size())+EPSILON);
|
const unsigned int number_of_extruders = (unsigned int)(sqrt(wiping_matrix.size())+EPSILON);
|
||||||
|
@ -1122,10 +1122,11 @@ void Tab::update_wiping_button_visibility() {
|
|||||||
return; // ys_FIXME
|
return; // ys_FIXME
|
||||||
bool wipe_tower_enabled = dynamic_cast<ConfigOptionBool*>( (m_preset_bundle->prints.get_edited_preset().config ).option("wipe_tower"))->value;
|
bool wipe_tower_enabled = dynamic_cast<ConfigOptionBool*>( (m_preset_bundle->prints.get_edited_preset().config ).option("wipe_tower"))->value;
|
||||||
bool multiple_extruders = dynamic_cast<ConfigOptionFloats*>((m_preset_bundle->printers.get_edited_preset().config).option("nozzle_diameter"))->values.size() > 1;
|
bool multiple_extruders = dynamic_cast<ConfigOptionFloats*>((m_preset_bundle->printers.get_edited_preset().config).option("nozzle_diameter"))->values.size() > 1;
|
||||||
|
bool single_extruder_multi_material = dynamic_cast<ConfigOptionBool*>((m_preset_bundle->printers.get_edited_preset().config).option("single_extruder_multi_material"))->value;
|
||||||
|
|
||||||
auto wiping_dialog_button = wxGetApp().sidebar().get_wiping_dialog_button();
|
auto wiping_dialog_button = wxGetApp().sidebar().get_wiping_dialog_button();
|
||||||
if (wiping_dialog_button) {
|
if (wiping_dialog_button) {
|
||||||
wiping_dialog_button->Show(wipe_tower_enabled && multiple_extruders);
|
wiping_dialog_button->Show(wipe_tower_enabled && multiple_extruders && single_extruder_multi_material);
|
||||||
wiping_dialog_button->GetParent()->Layout();
|
wiping_dialog_button->GetParent()->Layout();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user