Fix of : Crash after splitting an object into parts.

Now after splitting an object into parts, custom supports, seams, and multimaterial painting are removed, and the user is notified about it.

Also, this commit fixed the text of the notification about removing custom supports, seams, and multimaterial painting by Simplify gizmo. And it also fixed that info about custom supports, seams, and multimaterial painting was still shown in the right panel after the model simplification event when custom supports, seams, and multimaterial were removed.
This commit is contained in:
Lukáš Hejl 2023-02-21 13:48:16 +01:00
parent a41dd8eeed
commit db60d23c18
4 changed files with 22 additions and 6 deletions
src/slic3r/GUI

View file

@ -2175,6 +2175,10 @@ void ObjectList::split()
take_snapshot(_(L("Split to Parts")));
// Before splitting volume we have to remove all custom supports, seams, and multimaterial painting.
wxGetApp().plater()->clear_before_change_mesh(obj_idx, _u8L("Custom supports, seams and multimaterial painting were "
"removed after splitting the object."));
volume->split(nozzle_dmrs_cnt);
(*m_objects)[obj_idx]->input_file.clear();
@ -2186,6 +2190,10 @@ void ObjectList::split()
changed_object(obj_idx);
// update printable state for new volumes on canvas3D
wxGetApp().plater()->canvas3D()->update_instance_printable_state_for_object(obj_idx);
// After removing custom supports, seams, and multimaterial painting, we have to update info about the object to remove information about
// custom supports, seams, and multimaterial painting in the right panel.
wxGetApp().obj_list()->update_info_items(obj_idx);
}
void ObjectList::merge(bool to_multipart_object)
@ -4682,7 +4690,8 @@ void ObjectList::fix_through_netfabb()
msg += "\n";
}
plater->clear_before_change_mesh(obj_idx);
plater->clear_before_change_mesh(obj_idx, _u8L("Custom supports, seams and multimaterial painting were "
"removed after repairing the mesh."));
std::string res;
if (!fix_model_by_win10_sdk_gui(*(object(obj_idx)), vol_idx, progress_dlg, msg, res))
return false;