mirror of
https://github.com/clangen/musikcube.git
synced 2025-01-04 08:42:07 +00:00
Fixed small mistake of accessing shared_ptr::px instead of shared_ptr::get()
This commit is contained in:
parent
f9de0cf101
commit
83024bb1a4
@ -56,7 +56,7 @@ Node::~Node(void){
|
|||||||
if(this->parent){
|
if(this->parent){
|
||||||
// Erase in parents childnodes
|
// Erase in parents childnodes
|
||||||
for(ChildNodes::iterator node=this->parent->childNodes.begin();node!=this->parent->childNodes.end();){
|
for(ChildNodes::iterator node=this->parent->childNodes.begin();node!=this->parent->childNodes.end();){
|
||||||
if( node->px==this ){
|
if( node->get()==this ){
|
||||||
node = this->parent->childNodes.erase(node);
|
node = this->parent->childNodes.erase(node);
|
||||||
}else{
|
}else{
|
||||||
++node;
|
++node;
|
||||||
@ -90,7 +90,7 @@ int Node::NodeLevel(){
|
|||||||
void Node::RemoveFromParent(){
|
void Node::RemoveFromParent(){
|
||||||
if(this->parent){
|
if(this->parent){
|
||||||
for(Node::ChildNodes::iterator node=this->parent->childNodes.begin();node!=this->parent->childNodes.end();){
|
for(Node::ChildNodes::iterator node=this->parent->childNodes.begin();node!=this->parent->childNodes.end();){
|
||||||
if( this == node->px ){
|
if( node->get()==this ){
|
||||||
node = this->parent->childNodes.erase(node);
|
node = this->parent->childNodes.erase(node);
|
||||||
}else{
|
}else{
|
||||||
++node;
|
++node;
|
||||||
|
Loading…
Reference in New Issue
Block a user