Common gizmos data are now handled by the CommonGizmosDataPool object

This commit is contained in:
Lukas Matena 2020-04-02 17:07:15 +02:00
parent 7c4071c541
commit 3b06332999
6 changed files with 19 additions and 9 deletions

View file

@ -102,11 +102,14 @@ bool GLGizmosManager::init()
//dynamic_cast<GLGizmoHollow*>(m_gizmos[Hollow].get())->set_common_data_ptr(m_common_gizmos_data.get());
//dynamic_cast<GLGizmoSlaSupports*>(m_gizmos[SlaSupports].get())->set_common_data_ptr(m_common_gizmos_data.get());
m_common_gizmos_data.reset(new CommonGizmosDataPool(&m_parent));
for (auto& gizmo : m_gizmos) {
if (! gizmo->init()) {
m_gizmos.clear();
return false;
}
gizmo->set_common_data_pool(m_common_gizmos_data.get());
}
m_current = Undefined;
@ -1335,5 +1338,6 @@ void CommonGizmosData::build_AABB_if_needed()
m_schedule_aabb_calculation = false;
}
} // namespace GUI
} // namespace Slic3r