From 3f669e70b9a91f3eb6e3911e4baf86b9dbd6e150 Mon Sep 17 00:00:00 2001 From: enricoturri1966 Date: Wed, 27 Oct 2021 10:37:35 +0200 Subject: [PATCH] #7160 - Fixed drag object on mouse move cause wrong color when outside the print area --- src/slic3r/GUI/Selection.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/slic3r/GUI/Selection.cpp b/src/slic3r/GUI/Selection.cpp index b15d08c013..a6bcc0b38b 100644 --- a/src/slic3r/GUI/Selection.cpp +++ b/src/slic3r/GUI/Selection.cpp @@ -1712,7 +1712,10 @@ void Selection::set_caches() void Selection::do_add_volume(unsigned int volume_idx) { m_list.insert(volume_idx); - (*m_volumes)[volume_idx]->selected = true; + GLVolume* v = (*m_volumes)[volume_idx]; + v->selected = true; + if (v->hover == GLVolume::HS_Select || v->hover == GLVolume::HS_Deselect) + v->hover = GLVolume::HS_Hover; } void Selection::do_add_volumes(const std::vector& volume_idxs)