Centralize retained node teardown

This commit is contained in:
2026-06-12 16:15:43 +02:00
parent 9ac2c541dc
commit adb61795a6
7 changed files with 31 additions and 10 deletions

View File

@@ -437,7 +437,7 @@ public:
}
const bool new_current = !p->m_current || p->m_container->get_child_index(p->m_current) == current_index;
p->m_container->m_children[current_index]->destroy();
pp::panopainter::destroy_legacy_node(*p->m_container->m_children[current_index]);
if (clears_selection) {
p->m_current = nullptr;
} else if (new_current && selects_target) {