Skip to content
Snippets Groups Projects
Commit 5fc3076f authored by Florent Berthaut's avatar Florent Berthaut
Browse files

Fix remove path crash

parent c212904a
No related branches found
No related tags found
No related merge requests found
...@@ -629,6 +629,7 @@ void Reveal::testDelete() { ...@@ -629,6 +629,7 @@ void Reveal::testDelete() {
} }
m_listenersDeleteVec.clear(); m_listenersDeleteVec.clear();
if(m_modulesDeleteVec.size()>0) { if(m_modulesDeleteVec.size()>0) {
MainWindow::getInstance()->refreshModules(true, erasedListeners); MainWindow::getInstance()->refreshModules(true, erasedListeners);
} }
......
...@@ -87,6 +87,12 @@ RevealedPathModule::RevealedPathModule(): RevealedModule() { ...@@ -87,6 +87,12 @@ RevealedPathModule::RevealedPathModule(): RevealedModule() {
RevealedPathModule::~RevealedPathModule() { RevealedPathModule::~RevealedPathModule() {
Reveal::getInstance()->unregisterGeom(m_pathGeom); Reveal::getInstance()->unregisterGeom(m_pathGeom);
Reveal::getInstance()->removeModuleListObserver(this);
}
void RevealedPathModule::deleteModule() {
RevealedModule::deleteModule();
Reveal::getInstance()->removeModuleListObserver(this);
} }
void RevealedPathModule::load(xmlNodePtr node) { void RevealedPathModule::load(xmlNodePtr node) {
......
...@@ -34,6 +34,8 @@ class RevealedPathModule : public RevealedModule, public ModuleListObserver { ...@@ -34,6 +34,8 @@ class RevealedPathModule : public RevealedModule, public ModuleListObserver {
RevealedPathModule(); RevealedPathModule();
virtual ~RevealedPathModule(); virtual ~RevealedPathModule();
virtual void deleteModule();
virtual void load(xmlNodePtr node); virtual void load(xmlNodePtr node);
virtual xmlNodePtr save(xmlNodePtr parentNode); virtual xmlNodePtr save(xmlNodePtr parentNode);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment