mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-12 22:39:03 +08:00
Only on mouse up is emboss closed and only when no drag(move with scene) before was made.
This commit is contained in:
parent
adb6e00d4d
commit
85ee20dc8b
@ -407,7 +407,8 @@ bool GLGizmoEmboss::on_mouse_for_translate(const wxMouseEvent &mouse_event)
|
|||||||
|
|
||||||
void GLGizmoEmboss::on_mouse_change_selection(const wxMouseEvent &mouse_event)
|
void GLGizmoEmboss::on_mouse_change_selection(const wxMouseEvent &mouse_event)
|
||||||
{
|
{
|
||||||
if (mouse_event.LeftDown()) {
|
static bool was_dragging = true;
|
||||||
|
if ((mouse_event.LeftUp() || mouse_event.RightUp()) && !was_dragging) {
|
||||||
// is hovered volume closest hovered?
|
// is hovered volume closest hovered?
|
||||||
int hovered_idx = m_parent.get_first_hover_volume_idx();
|
int hovered_idx = m_parent.get_first_hover_volume_idx();
|
||||||
if (hovered_idx < 0)
|
if (hovered_idx < 0)
|
||||||
@ -430,6 +431,7 @@ void GLGizmoEmboss::on_mouse_change_selection(const wxMouseEvent &mouse_event)
|
|||||||
|
|
||||||
// Reselection of text to another text
|
// Reselection of text to another text
|
||||||
}
|
}
|
||||||
|
was_dragging = mouse_event.Dragging();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool GLGizmoEmboss::on_mouse(const wxMouseEvent &mouse_event)
|
bool GLGizmoEmboss::on_mouse(const wxMouseEvent &mouse_event)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user