summaryrefslogtreecommitdiffstats
path: root/Project/Shunt.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Project/Shunt.cpp')
-rw-r--r--Project/Shunt.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/Project/Shunt.cpp b/Project/Shunt.cpp
index 0cd5736..cbd424e 100644
--- a/Project/Shunt.cpp
+++ b/Project/Shunt.cpp
@@ -57,6 +57,7 @@ void Shunt::StartMove(wxPoint2DDouble position)
void Shunt::RemoveParent(Element* parent)
{
if(parent == m_parentList[0]) {
+ m_parentList[0]->RemoveChild(this);
m_parentList[0] = NULL;
m_online = false;
UpdateSwitchesPosition();