Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/prusa3d/PrusaSlicer.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLukas Matena <lukasmatena@seznam.cz>2020-08-18 16:17:26 +0300
committerLukas Matena <lukasmatena@seznam.cz>2020-08-21 10:49:39 +0300
commitc29171790930a1a9f9b0374b6a5ab8ccec1e88a9 (patch)
tree86629c45a82581bd1cb2a0eab4e2371323442aca /src/slic3r
parent739cd2a4a20f50dace8cd053b671f3451fb9160a (diff)
Forbid translation of objects when SLA/Hollow/FDM gizmos are active
Diffstat (limited to 'src/slic3r')
-rw-r--r--src/slic3r/GUI/GLCanvas3D.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/slic3r/GUI/GLCanvas3D.cpp b/src/slic3r/GUI/GLCanvas3D.cpp
index 9bed5fde7..94f6f6ef3 100644
--- a/src/slic3r/GUI/GLCanvas3D.cpp
+++ b/src/slic3r/GUI/GLCanvas3D.cpp
@@ -3658,6 +3658,13 @@ void GLCanvas3D::on_mouse(wxMouseEvent& evt)
{
m_mouse.dragging = true;
+ // Translation of objects is forbidden when SLA supports/hollowing/fdm
+ // supports gizmo is active.
+ if (m_gizmos.get_current_type() == GLGizmosManager::SlaSupports
+ || m_gizmos.get_current_type() == GLGizmosManager::FdmSupports
+ || m_gizmos.get_current_type() == GLGizmosManager::Hollow)
+ return;
+
Vec3d cur_pos = m_mouse.drag.start_position_3D;
// we do not want to translate objects if the user just clicked on an object while pressing shift to remove it from the selection and then drag
if (m_selection.contains_volume(get_first_hover_volume_idx()))