From b1c6d28411fc2b6a564d756296ddedd2c910fac7 Mon Sep 17 00:00:00 2001 From: Joseph Lenox Date: Sun, 6 May 2018 20:37:49 -0500 Subject: [PATCH] Ported clean_instance_thumbnails --- src/GUI/Plater/Plate2D.cpp | 4 ++++ src/GUI/Plater/Plate2D.hpp | 3 +++ 2 files changed, 7 insertions(+) diff --git a/src/GUI/Plater/Plate2D.cpp b/src/GUI/Plater/Plate2D.cpp index e2a4162bf..36997560e 100644 --- a/src/GUI/Plater/Plate2D.cpp +++ b/src/GUI/Plater/Plate2D.cpp @@ -97,6 +97,10 @@ void Plate2D::repaint(wxPaintEvent& e) { } +void Plate2D::clean_instance_thumbnails() { + for (auto& obj : this->objects) { + obj.instance_thumbnails.clear(); + } } void Plate2D::mouse_drag(wxMouseEvent& e) { diff --git a/src/GUI/Plater/Plate2D.hpp b/src/GUI/Plater/Plate2D.hpp index 1db726a11..42ec6f786 100644 --- a/src/GUI/Plater/Plate2D.hpp +++ b/src/GUI/Plater/Plate2D.hpp @@ -119,6 +119,9 @@ private: return this->point_to_model_units(pt.x, pt.y); } + /// Remove all instance thumbnails. + void clean_instance_thumbnails(); + }; } } // Namespace Slic3r::GUI