Changeset 5397 in orxonox.OLD for trunk/src/lib/graphics/render2D/element_2d.cc
- Timestamp:
- Oct 18, 2005, 5:33:11 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/lib/graphics/render2D/element_2d.cc
r5396 r5397 35 35 { 36 36 this->init(); 37 Render2D::getInstance()->registerElement2D(this); 37 38 this->setParent2D(NullElement2D::getInstance()); 38 39 } … … 48 49 { 49 50 this->init(); 51 Render2D::getInstance()->registerElement2D(this); 50 52 51 53 // check Parenting, and if ok parent the stuff … … 124 126 this->toDirection = NULL; 125 127 this->setSize2D(1,1); 126 127 Render2D::getInstance()->registerElement2D(this);128 128 } 129 129 … … 471 471 child->parentMode = parentingMode; 472 472 child->parent = this; 473 this->children->add(child); 473 if (likely(this != NULL)) 474 this->children->add(child); 474 475 child->parentCoorChanged(); 475 476 } … … 667 668 668 669 669 if ( this->alignment == E2D_ALIGN_SCREEN_CENTER && this->bRelCoorChanged)670 if (unlikely(this->alignment & E2D_ALIGN_SCREEN_CENTER && this->bRelCoorChanged)) 670 671 { 671 672 this->prevRelCoordinate = this->relCoordinate; … … 674 675 this->absCoordinate.z = 0.0; 675 676 } 676 else if ( this->bindNode)677 else if (unlikely(this->bindNode != NULL)) 677 678 { 678 679 GLdouble projectPos[3];
Note: See TracChangeset
for help on using the changeset viewer.