summaryrefslogtreecommitdiffstats
path: root/Project/Machines.cpp
diff options
context:
space:
mode:
authorThales1330 <thaleslima.ufu@gmail.com>2017-01-03 19:03:12 -0200
committerThales1330 <thaleslima.ufu@gmail.com>2017-01-03 19:03:12 -0200
commita1932eec23589ed67d824873b37de3e83a09cd24 (patch)
treedb2bed8e7a9c87ad6115a1b8a6a347cad6753b06 /Project/Machines.cpp
parent2c0b51586b3b2243ae0fdcd653139818e4b4e23e (diff)
downloadPSP.git-a1932eec23589ed67d824873b37de3e83a09cd24.tar.gz
PSP.git-a1932eec23589ed67d824873b37de3e83a09cd24.tar.xz
PSP.git-a1932eec23589ed67d824873b37de3e83a09cd24.zip
Text element optimizated, but buggy
Element/parent search buggy
Diffstat (limited to 'Project/Machines.cpp')
-rw-r--r--Project/Machines.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/Project/Machines.cpp b/Project/Machines.cpp
index 6377f08..cde5933 100644
--- a/Project/Machines.cpp
+++ b/Project/Machines.cpp
@@ -142,7 +142,9 @@ void Machines::RotateNode(Element* parent, bool clockwise)
void Machines::RemoveParent(Element* parent)
{
if(parent == m_parentList[0]) {
+ m_parentList[0]->RemoveChild(this);
m_parentList[0] = NULL;
+ m_online = false;
UpdateSwitchesPosition();
UpdatePowerFlowArrowsPosition();
}