diff --git a/src/slic3r/GUI/GUI_Preview.cpp b/src/slic3r/GUI/GUI_Preview.cpp index 2730544b7c..c2a59b5d50 100644 --- a/src/slic3r/GUI/GUI_Preview.cpp +++ b/src/slic3r/GUI/GUI_Preview.cpp @@ -483,10 +483,9 @@ void Preview::update_layers_slider_mode() can_change_color = false; } // check if whole model uses just only one extruder - if (!plate_extruders.empty()) { + if (plate_extruders.size() > 1) { //const int extruder = objects[0]->config.has("extruder") ? objects[0]->config.option("extruder")->getInt() : 0; - const int extruder = plate_extruders[0]; - only_extruder = extruder; + only_extruder = plate_extruders[0]; // auto is_one_extruder_printed_model = [objects, extruder]() { // for (ModelObject *object : objects) { // if (object->config.has("extruder") && object->config.option("extruder")->getInt() != extruder) /*return false*/; diff --git a/src/slic3r/GUI/IMSlider.cpp b/src/slic3r/GUI/IMSlider.cpp index 63f270e026..e2222cf542 100644 --- a/src/slic3r/GUI/IMSlider.cpp +++ b/src/slic3r/GUI/IMSlider.cpp @@ -597,8 +597,11 @@ void IMSlider::SetModeAndOnlyExtruder(const bool is_one_extruder_printed_model, UseDefaultColors(m_mode == SingleExtruder); - m_is_wipe_tower = m_mode != SingleExtruder; - + DynamicPrintConfig config = wxGetApp().preset_bundle->full_config(); + if (config.opt_enum("print_sequence") == PrintSequence::ByObject) + m_is_wipe_tower = false; + else + m_is_wipe_tower = m_mode != SingleExtruder; m_can_change_color = can_change_color; } @@ -1430,22 +1433,23 @@ void IMSlider::render_menu() ImGui::PushStyleVar(ImGuiStyleVar_::ImGuiStyleVar_ChildRounding, 4.0f * m_scale); if (ImGui::BeginPopup("slider_menu_popup")) { - if ((m_selection == ssLower && GetLowerValueD() == m_zero_layer_height) || (m_selection == ssHigher && GetHigherValueD() == m_zero_layer_height)) + bool menu_item_enable = m_draw_mode != dmSequentialFffPrint; + //if ((m_selection == ssLower && GetLowerValueD() == m_zero_layer_height) || (m_selection == ssHigher && GetHigherValueD() == m_zero_layer_height)) + //{ + // if (menu_item_with_icon(_u8L("Jump to Layer").c_str(), "")) { + // m_show_go_to_layer_dialog = true; + // } + //} + //else { - if (menu_item_with_icon(_u8L("Jump to Layer").c_str(), "")) { - m_show_go_to_layer_dialog = true; - } - } - else - { - if (menu_item_with_icon(_u8L("Add Pause").c_str(), "")) { + if (menu_item_with_icon(_u8L("Add Pause").c_str(), "", ImVec2(0, 0), 0, false, menu_item_enable)) { add_code_as_tick(PausePrint); } - if (menu_item_with_icon(_u8L("Add Custom G-code").c_str(), "")) { + if (menu_item_with_icon(_u8L("Add Custom G-code").c_str(), "", ImVec2(0, 0), 0, false, menu_item_enable)) { m_show_custom_gcode_window = true; } if (!gcode(Template).empty()) { - if (menu_item_with_icon(_u8L("Add Custom Template").c_str(), "")) { + if (menu_item_with_icon(_u8L("Add Custom Template").c_str(), "", ImVec2(0, 0), 0, false, menu_item_enable)) { add_code_as_tick(Template); } }