diff options
| author | Simon Robertshaw <simon@hardwired.org.uk> | 2012-01-15 19:35:40 (GMT) |
|---|---|---|
| committer | Simon Robertshaw <simon@hardwired.org.uk> | 2012-01-15 19:35:40 (GMT) |
| commit | 2511afec8bfaa0582928406b37e8b579fa267e4f (patch) | |
| tree | aae1674f5f076db275ec1c6b32271a69cff1489a /src/interface/Component.cpp | |
| parent | 2c9295007a287dc01ff63fcf7b3da141f7474e37 (diff) | |
| download | powder-2511afec8bfaa0582928406b37e8b579fa267e4f.zip powder-2511afec8bfaa0582928406b37e8b579fa267e4f.tar.gz | |
More stuff, better events and starting on interface
Diffstat (limited to 'src/interface/Component.cpp')
| -rw-r--r-- | src/interface/Component.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/interface/Component.cpp b/src/interface/Component.cpp index ac66f92..49ff7f8 100644 --- a/src/interface/Component.cpp +++ b/src/interface/Component.cpp @@ -76,7 +76,8 @@ void Component::SetParent(Panel* new_parent) else { // remove from parent state (if in parent state) and place in new parent - GetParentState()->RemoveComponent(this); + if(GetParentState()) + GetParentState()->RemoveComponent(this); new_parent->children.push_back(this); } this->_parent = new_parent; |
