Skip to content

Commit

Permalink
Fix of #5619 - Copying Item with Printable Property
Browse files Browse the repository at this point in the history
  • Loading branch information
YuSanka committed Jan 18, 2021
1 parent 9a2310a commit 1efa129
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/slic3r/GUI/GLCanvas3D.cpp
Expand Up @@ -1377,7 +1377,7 @@ void GLCanvas3D::update_instance_printable_state_for_object(const size_t obj_idx
}
}

void GLCanvas3D::update_instance_printable_state_for_objects(std::vector<size_t>& object_idxs)
void GLCanvas3D::update_instance_printable_state_for_objects(const std::vector<size_t>& object_idxs)
{
for (size_t obj_idx : object_idxs)
update_instance_printable_state_for_object(obj_idx);
Expand Down
2 changes: 1 addition & 1 deletion src/slic3r/GUI/GLCanvas3D.hpp
Expand Up @@ -565,7 +565,7 @@ class GLCanvas3D
void toggle_sla_auxiliaries_visibility(bool visible, const ModelObject* mo = nullptr, int instance_idx = -1);
void toggle_model_objects_visibility(bool visible, const ModelObject* mo = nullptr, int instance_idx = -1);
void update_instance_printable_state_for_object(size_t obj_idx);
void update_instance_printable_state_for_objects(std::vector<size_t>& object_idxs);
void update_instance_printable_state_for_objects(const std::vector<size_t>& object_idxs);

void set_config(const DynamicPrintConfig* config);
void set_process(BackgroundSlicingProcess* process);
Expand Down
4 changes: 3 additions & 1 deletion src/slic3r/GUI/Plater.cpp
Expand Up @@ -6111,8 +6111,10 @@ void Plater::changed_objects(const std::vector<size_t>& object_idxs)
// pulls the correct data, update the 3D scene.
this->p->update_restart_background_process(true, false);
}
else
else {
p->view3D->reload_scene(false);
p->view3D->get_canvas3d()->update_instance_printable_state_for_objects(object_idxs);
}

// update print
this->p->schedule_background_process();
Expand Down

0 comments on commit 1efa129

Please sign in to comment.