From 87dadc9815139f209eb85d41842ef236873f6b23 Mon Sep 17 00:00:00 2001 From: Joseph Lenox Date: Fri, 11 May 2018 23:09:15 -0500 Subject: [PATCH] Object selection now functions on 2D plater. --- src/GUI/Plater/Plate2D.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/GUI/Plater/Plate2D.cpp b/src/GUI/Plater/Plate2D.cpp index bb5738701..598061be0 100644 --- a/src/GUI/Plater/Plate2D.cpp +++ b/src/GUI/Plater/Plate2D.cpp @@ -116,9 +116,9 @@ void Plate2D::repaint(wxPaintEvent& e) { if (0) { // object is dragged dc->SetBrush(dragged_brush); - } else if (0) { + } else if (obj.selected && obj.selected_instance >= 0 && obj.selected_instance == static_cast(instance_idx)) { dc->SetBrush(instance_brush); - } else if (0) { + } else if (obj.selected) { dc->SetBrush(selected_brush); } else { dc->SetBrush(objects_brush); @@ -147,6 +147,7 @@ void Plate2D::mouse_drag(wxMouseEvent& e) { const auto& point {this->point_to_model_units(e.GetPosition())}; if (e.Dragging()) { Slic3r::Log::info(LogChannel, L"Mouse dragging"); + this->Refresh(); } else { auto cursor = wxSTANDARD_CURSOR; /* @@ -198,9 +199,8 @@ void Plate2D::mouse_down(wxMouseEvent& e) { } } } - } - + this->Refresh(); } void Plate2D::mouse_up(wxMouseEvent& e) {