diff --git a/src/slic3r/GUI/Gizmos/GLGizmoEmboss.cpp b/src/slic3r/GUI/Gizmos/GLGizmoEmboss.cpp index 7daabf3d7..b1ffee652 100644 --- a/src/slic3r/GUI/Gizmos/GLGizmoEmboss.cpp +++ b/src/slic3r/GUI/Gizmos/GLGizmoEmboss.cpp @@ -246,7 +246,7 @@ void GLGizmoEmboss::create_volume(ModelVolumeType volume_type, const Vec2d& mous if (!init_create(volume_type)) return; - GLVolume *gl_volume = get_first_hovered_gl_volume(m_parent); + const GLVolume *gl_volume = get_first_hovered_gl_volume(m_parent); DataBase emboss_data = priv::create_emboss_data_base(m_text, m_style_manager, m_job_cancel); if (gl_volume != nullptr) { // Try to cast ray into scene and find object for add volume @@ -558,10 +558,6 @@ bool GLGizmoEmboss::on_init() return true; } -bool GLGizmoEmboss::on_is_activable() const { - return wxGetApp().get_mode() != comSimple; -} - std::string GLGizmoEmboss::on_get_name() const { return _u8L("Emboss"); } void GLGizmoEmboss::on_render() { diff --git a/src/slic3r/GUI/Gizmos/GLGizmoEmboss.hpp b/src/slic3r/GUI/Gizmos/GLGizmoEmboss.hpp index db8de5e4e..318917863 100644 --- a/src/slic3r/GUI/Gizmos/GLGizmoEmboss.hpp +++ b/src/slic3r/GUI/Gizmos/GLGizmoEmboss.hpp @@ -53,13 +53,13 @@ public: void on_shortcut_key(); protected: bool on_init() override; - bool on_is_activable() const override; std::string on_get_name() const override; void on_render() override; void on_register_raycasters_for_picking() override; void on_unregister_raycasters_for_picking() override; void on_render_input_window(float x, float y, float bottom_limit) override; bool on_is_selectable() const override { return false; } + bool on_is_activable() const override { return true; }; void on_set_state() override; void data_changed(bool is_serializing) override; // selection changed void on_set_hover_id() override{ m_rotate_gizmo.set_hover_id(m_hover_id); }