From eeb81b1ef8d3e34d4b8cd755f2bb9bddde714a54 Mon Sep 17 00:00:00 2001 From: enricoturri1966 Date: Wed, 11 May 2022 11:54:01 +0200 Subject: [PATCH] Tech ENABLE_TRANSFORMATIONS_BY_MATRICES - Let reset buttons in object manipulator to be always visible when needed, no matter what is the current selected reference system --- src/slic3r/GUI/GUI_ObjectManipulation.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/slic3r/GUI/GUI_ObjectManipulation.cpp b/src/slic3r/GUI/GUI_ObjectManipulation.cpp index 871c90c51..141c34c9b 100644 --- a/src/slic3r/GUI/GUI_ObjectManipulation.cpp +++ b/src/slic3r/GUI/GUI_ObjectManipulation.cpp @@ -882,15 +882,21 @@ void ObjectManipulation::update_reset_buttons_visibility() bool show_drop_to_bed = false; #if ENABLE_WORLD_COORDINATE +#if ENABLE_TRANSFORMATIONS_BY_MATRICES + if (selection.is_single_full_instance() || selection.is_single_volume_or_modifier()) { +#else if ((m_coordinates_type == ECoordinatesType::World && selection.is_single_full_instance()) || (m_coordinates_type == ECoordinatesType::Instance && selection.is_single_volume_or_modifier())) { +#endif // ENABLE_TRANSFORMATIONS_BY_MATRICES const double min_z = selection.is_single_full_instance() ? selection.get_scaled_instance_bounding_box().min.z() : get_volume_min_z(*selection.get_first_volume()); show_drop_to_bed = std::abs(min_z) > EPSILON; +#if !ENABLE_TRANSFORMATIONS_BY_MATRICES } if (m_coordinates_type == ECoordinatesType::Local && (selection.is_single_full_instance() || selection.is_single_volume_or_modifier())) { +#endif // !ENABLE_TRANSFORMATIONS_BY_MATRICES const GLVolume* volume = selection.get_first_volume(); Vec3d rotation = Vec3d::Zero(); Vec3d scale = Vec3d::Ones();