Commit 29f6ca00 authored by cutealien's avatar cutealien

In IGUITreeView "clearChilds" and "hasChilds" deprecated for "clearChildren"...

In IGUITreeView "clearChilds" and "hasChilds" deprecated for "clearChildren" and "hasChildren" (thx @Greenya for noticing)
Same childs => children in a few places in documenatation and variables.
Removed a compile warning in CCubeSceneNode.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@3330 dfc29bdd-3216-0410-991c-e03cc46cb475
parent c00c459b
- In IGUITreeView "clearChilds" and "hasChilds" deprecated for "clearChildren" and "hasChildren" (thx @Greenya for noticing)
- add dimension2d::operator-
- add CGUIEditBox::getOverrideColor and CGUIEditBox::isOverrideColorEnabled
- Add logging level ELL_DEBUG - Add logging level ELL_DEBUG
- Add parameter DisplayAdapter to creation params to allow selecting the card when more than one card is in the system. - Add parameter DisplayAdapter to creation params to allow selecting the card when more than one card is in the system.
......
...@@ -805,7 +805,7 @@ void CQuake3EventHandler::CreateGUI() ...@@ -805,7 +805,7 @@ void CQuake3EventHandler::CreateGUI()
gui.SceneTree = env->addTreeView( rect<s32>( dim.Width - 400, dim.Height - 380, dim.Width - 5, dim.Height - 40 ), gui.SceneTree = env->addTreeView( rect<s32>( dim.Width - 400, dim.Height - 380, dim.Width - 5, dim.Height - 40 ),
gui.Window, -1, true, true, false ); gui.Window, -1, true, true, false );
gui.SceneTree->setToolTipText ( L"Show the current Scenegraph" ); gui.SceneTree->setToolTipText ( L"Show the current Scenegraph" );
gui.SceneTree->getRoot()->clearChilds(); gui.SceneTree->getRoot()->clearChildren();
addSceneTreeItem ( Game->Device->getSceneManager()->getRootSceneNode(), gui.SceneTree->getRoot() ); addSceneTreeItem ( Game->Device->getSceneManager()->getRootSceneNode(), gui.SceneTree->getRoot() );
...@@ -1288,7 +1288,7 @@ void CQuake3EventHandler::SetGUIActive( s32 command) ...@@ -1288,7 +1288,7 @@ void CQuake3EventHandler::SetGUIActive( s32 command)
gui.SceneTree && Game->Device->getGUIEnvironment()->getFocus() != gui.SceneTree gui.SceneTree && Game->Device->getGUIEnvironment()->getFocus() != gui.SceneTree
) )
{ {
gui.SceneTree->getRoot()->clearChilds(); gui.SceneTree->getRoot()->clearChildren();
addSceneTreeItem ( Game->Device->getSceneManager()->getRootSceneNode(), gui.SceneTree->getRoot() ); addSceneTreeItem ( Game->Device->getSceneManager()->getRootSceneNode(), gui.SceneTree->getRoot() );
} }
......
...@@ -66,11 +66,25 @@ namespace gui ...@@ -66,11 +66,25 @@ namespace gui
//! returns the child item count //! returns the child item count
virtual u32 getChildCount() const = 0; virtual u32 getChildCount() const = 0;
//! removes all childs (recursive) from this node //! removes all children (recursive) from this node
virtual void clearChilds() = 0; virtual void clearChildren() = 0;
//! removes all children (recursive) from this node
/** \deprecated Deprecated in 1.8, use clearChildren() instead. */
_IRR_DEPRECATED_ void clearChilds()
{
return clearChildren();
}
//! returns true if this node has child nodes //! returns true if this node has child nodes
virtual bool hasChilds() const = 0; virtual bool hasChildren() const = 0;
//! returns true if this node has child nodes
/** \deprecated Deprecated in 1.8, use hasChildren() instead. */
_IRR_DEPRECATED_ bool hasChilds() const
{
return hasChildren();
}
//! Adds a new node behind the last child node. //! Adds a new node behind the last child node.
/** \param text text of the new node /** \param text text of the new node
...@@ -135,11 +149,11 @@ namespace gui ...@@ -135,11 +149,11 @@ namespace gui
void* data=0, IReferenceCounted* data2=0) = 0; void* data=0, IReferenceCounted* data2=0) = 0;
//! Return the first child node from this node. //! Return the first child node from this node.
/** \return The first child node or 0 if this node has no childs. */ /** \return The first child node or 0 if this node has no children. */
virtual IGUITreeViewNode* getFirstChild() const = 0; virtual IGUITreeViewNode* getFirstChild() const = 0;
//! Return the last child node from this node. //! Return the last child node from this node.
/** \return The last child node or 0 if this node has no childs. */ /** \return The last child node or 0 if this node has no children. */
virtual IGUITreeViewNode* getLastChild() const = 0; virtual IGUITreeViewNode* getLastChild() const = 0;
//! Returns the previous sibling node from this node. //! Returns the previous sibling node from this node.
...@@ -171,7 +185,7 @@ namespace gui ...@@ -171,7 +185,7 @@ namespace gui
/** \return True if the node was found as achild node and was not already the last child. */ /** \return True if the node was found as achild node and was not already the last child. */
virtual bool moveChildDown( IGUITreeViewNode* child ) = 0; virtual bool moveChildDown( IGUITreeViewNode* child ) = 0;
//! Returns true if the node is expanded (childs are visible). //! Returns true if the node is expanded (children are visible).
virtual bool getExpanded() const = 0; virtual bool getExpanded() const = 0;
//! Sets if the node is expanded. //! Sets if the node is expanded.
...@@ -187,7 +201,7 @@ namespace gui ...@@ -187,7 +201,7 @@ namespace gui
virtual bool isRoot() const = 0; virtual bool isRoot() const = 0;
//! Returns the level of this node. //! Returns the level of this node.
/** The root node has level 0. Direct childs of the root has level 1 ... */ /** The root node has level 0. Direct children of the root has level 1 ... */
virtual s32 getLevel() const = 0; virtual s32 getLevel() const = 0;
//! Returns true if this node is visible (all parents are expanded). //! Returns true if this node is visible (all parents are expanded).
......
...@@ -260,7 +260,7 @@ namespace ...@@ -260,7 +260,7 @@ namespace
//! prefab for a container scene node //! prefab for a container scene node
//! Collects other prefabs and instantiates them upon instantiation //! Collects other prefabs and instantiates them upon instantiation
//! Uses a dummy scene node to return the childs as one scene node //! Uses a dummy scene node to return the children as one scene node
class CScenePrefab : public CPrefab class CScenePrefab : public CPrefab
{ {
public: public:
...@@ -279,7 +279,7 @@ namespace ...@@ -279,7 +279,7 @@ namespace
os::Printer::log("COLLADA: Constructing scene instance", Id.c_str()); os::Printer::log("COLLADA: Constructing scene instance", Id.c_str());
#endif #endif
if (Childs.size()==0) if (Children.size()==0)
return 0; return 0;
scene::IDummyTransformationSceneNode* s = mgr->addDummyTransformationSceneNode(parent); scene::IDummyTransformationSceneNode* s = mgr->addDummyTransformationSceneNode(parent);
...@@ -295,14 +295,14 @@ namespace ...@@ -295,14 +295,14 @@ namespace
} }
os::Printer::log("COLLADA: Transformation", t.c_str()); os::Printer::log("COLLADA: Transformation", t.c_str());
for (u32 i=0; i<Childs.size(); ++i) for (u32 i=0; i<Children.size(); ++i)
Childs[i]->addInstance(s, mgr); Children[i]->addInstance(s, mgr);
} }
return s; return s;
} }
core::array<IColladaPrefab*> Childs; core::array<IColladaPrefab*> Children;
core::matrix4 Transformation; core::matrix4 Transformation;
}; };
...@@ -737,7 +737,7 @@ void CColladaFileLoader::readNodeSection(io::IXMLReaderUTF8* reader, scene::ISce ...@@ -737,7 +737,7 @@ void CColladaFileLoader::readNodeSection(io::IXMLReaderUTF8* reader, scene::ISce
if (p) if (p)
{ {
nodeprefab = new CScenePrefab(readId(reader)); nodeprefab = new CScenePrefab(readId(reader));
p->Childs.push_back(nodeprefab); p->Children.push_back(nodeprefab);
Prefabs.push_back(nodeprefab); // in order to delete them later on Prefabs.push_back(nodeprefab); // in order to delete them later on
} }
...@@ -1132,7 +1132,7 @@ void CColladaFileLoader::instantiateNode(scene::ISceneNode* parent, ...@@ -1132,7 +1132,7 @@ void CColladaFileLoader::instantiateNode(scene::ISceneNode* parent,
if (url == "" || url == Prefabs[i]->getId()) if (url == "" || url == Prefabs[i]->getId())
{ {
if (p) if (p)
p->Childs.push_back(Prefabs[i]); p->Children.push_back(Prefabs[i]);
else else
if (CreateInstances) if (CreateInstances)
{ {
...@@ -1153,7 +1153,7 @@ void CColladaFileLoader::instantiateNode(scene::ISceneNode* parent, ...@@ -1153,7 +1153,7 @@ void CColladaFileLoader::instantiateNode(scene::ISceneNode* parent,
if (instanceGeometryName==type) if (instanceGeometryName==type)
{ {
Prefabs.push_back(new CGeometryPrefab(url)); Prefabs.push_back(new CGeometryPrefab(url));
p->Childs.push_back(Prefabs.getLast()); p->Children.push_back(Prefabs.getLast());
} }
} }
} }
...@@ -1661,7 +1661,7 @@ void CColladaFileLoader::readGeometry(io::IXMLReaderUTF8* reader) ...@@ -1661,7 +1661,7 @@ void CColladaFileLoader::readGeometry(io::IXMLReaderUTF8* reader)
core::array<SSource> sources; core::array<SSource> sources;
bool okToReadArray = false; bool okToReadArray = false;
// handles geometry node and the mesh childs in this loop // handles geometry node and the mesh children in this loop
// read sources with arrays and accessor for each mesh // read sources with arrays and accessor for each mesh
if (!reader->isEmptyElement()) if (!reader->isEmptyElement())
while(reader->read()) while(reader->read())
......
...@@ -214,7 +214,7 @@ private: ...@@ -214,7 +214,7 @@ private:
void readAssetSection(io::IXMLReaderUTF8* reader); void readAssetSection(io::IXMLReaderUTF8* reader);
//! reads a <node> section and its content //! reads a <node> section and its content
//! if a prefab pointer is passed the nodes are created as scene prefabs childs of that prefab //! if a prefab pointer is passed the nodes are created as scene prefabs children of that prefab
void readNodeSection(io::IXMLReaderUTF8* reader, scene::ISceneNode* parent, CScenePrefab* p=0); void readNodeSection(io::IXMLReaderUTF8* reader, scene::ISceneNode* parent, CScenePrefab* p=0);
//! reads a <lookat> element and its content and creates a matrix from it //! reads a <lookat> element and its content and creates a matrix from it
......
...@@ -64,7 +64,6 @@ void CCubeSceneNode::render() ...@@ -64,7 +64,6 @@ void CCubeSceneNode::render()
driver->setTransform(video::ETS_WORLD, AbsoluteTransformation); driver->setTransform(video::ETS_WORLD, AbsoluteTransformation);
// for debug purposes only: // for debug purposes only:
bool renderMeshes = true;
video::SMaterial mat = Mesh->getMeshBuffer(0)->getMaterial(); video::SMaterial mat = Mesh->getMeshBuffer(0)->getMaterial();
// overwrite half transparency // overwrite half transparency
......
...@@ -32,9 +32,9 @@ CGUIModalScreen::CGUIModalScreen(IGUIEnvironment* environment, IGUIElement* pare ...@@ -32,9 +32,9 @@ CGUIModalScreen::CGUIModalScreen(IGUIEnvironment* environment, IGUIElement* pare
bool CGUIModalScreen::canTakeFocus(IGUIElement* target) const bool CGUIModalScreen::canTakeFocus(IGUIElement* target) const
{ {
return (target && ((const IGUIElement*)target == this // this element can take it return (target && ((const IGUIElement*)target == this // this element can take it
|| isMyChild(target) // own childs also || isMyChild(target) // own children also
|| (target->getType() == EGUIET_MODAL_SCREEN )// other modals also fine || (target->getType() == EGUIET_MODAL_SCREEN )// other modals also fine
|| (target->getParent() && target->getParent()->getType() == EGUIET_MODAL_SCREEN ))) // childs of other modals will do || (target->getParent() && target->getParent()->getType() == EGUIET_MODAL_SCREEN ))) // children of other modals will do
; ;
} }
......
...@@ -34,7 +34,7 @@ CGUITreeViewNode::~CGUITreeViewNode() ...@@ -34,7 +34,7 @@ CGUITreeViewNode::~CGUITreeViewNode()
setSelected( false ); setSelected( false );
} }
clearChilds(); clearChildren();
if( Data2 ) if( Data2 )
{ {
...@@ -62,15 +62,15 @@ void CGUITreeViewNode::setIcon( const wchar_t* icon ) ...@@ -62,15 +62,15 @@ void CGUITreeViewNode::setIcon( const wchar_t* icon )
Icon = icon; Icon = icon;
} }
void CGUITreeViewNode::clearChilds() void CGUITreeViewNode::clearChildren()
{ {
core::list<CGUITreeViewNode*>::Iterator it; core::list<CGUITreeViewNode*>::Iterator it;
for( it = Childs.begin(); it != Childs.end(); it++ ) for( it = Children.begin(); it != Children.end(); it++ )
{ {
( *it )->drop(); ( *it )->drop();
} }
Childs.clear(); Children.clear();
} }
IGUITreeViewNode* CGUITreeViewNode::addChildBack( IGUITreeViewNode* CGUITreeViewNode::addChildBack(
...@@ -83,7 +83,7 @@ IGUITreeViewNode* CGUITreeViewNode::addChildBack( ...@@ -83,7 +83,7 @@ IGUITreeViewNode* CGUITreeViewNode::addChildBack(
{ {
CGUITreeViewNode* newChild = new CGUITreeViewNode( Owner, this ); CGUITreeViewNode* newChild = new CGUITreeViewNode( Owner, this );
Childs.push_back( newChild ); Children.push_back( newChild );
newChild->Text = text; newChild->Text = text;
newChild->Icon = icon; newChild->Icon = icon;
newChild->ImageIndex = imageIndex; newChild->ImageIndex = imageIndex;
...@@ -107,7 +107,7 @@ IGUITreeViewNode* CGUITreeViewNode::addChildFront( ...@@ -107,7 +107,7 @@ IGUITreeViewNode* CGUITreeViewNode::addChildFront(
{ {
CGUITreeViewNode* newChild = new CGUITreeViewNode( Owner, this ); CGUITreeViewNode* newChild = new CGUITreeViewNode( Owner, this );
Childs.push_front( newChild ); Children.push_front( newChild );
newChild->Text = text; newChild->Text = text;
newChild->Icon = icon; newChild->Icon = icon;
newChild->ImageIndex = imageIndex; newChild->ImageIndex = imageIndex;
...@@ -133,7 +133,7 @@ IGUITreeViewNode* CGUITreeViewNode::insertChildAfter( ...@@ -133,7 +133,7 @@ IGUITreeViewNode* CGUITreeViewNode::insertChildAfter(
core::list<CGUITreeViewNode*>::Iterator itOther; core::list<CGUITreeViewNode*>::Iterator itOther;
CGUITreeViewNode* newChild = 0; CGUITreeViewNode* newChild = 0;
for( itOther = Childs.begin(); itOther != Childs.end(); itOther++ ) for( itOther = Children.begin(); itOther != Children.end(); itOther++ )
{ {
if( other == *itOther ) if( other == *itOther )
{ {
...@@ -148,7 +148,7 @@ IGUITreeViewNode* CGUITreeViewNode::insertChildAfter( ...@@ -148,7 +148,7 @@ IGUITreeViewNode* CGUITreeViewNode::insertChildAfter(
{ {
data2->grab(); data2->grab();
} }
Childs.insert_after( itOther, newChild ); Children.insert_after( itOther, newChild );
break; break;
} }
} }
...@@ -167,7 +167,7 @@ IGUITreeViewNode* CGUITreeViewNode::insertChildBefore( ...@@ -167,7 +167,7 @@ IGUITreeViewNode* CGUITreeViewNode::insertChildBefore(
core::list<CGUITreeViewNode*>::Iterator itOther; core::list<CGUITreeViewNode*>::Iterator itOther;
CGUITreeViewNode* newChild = 0; CGUITreeViewNode* newChild = 0;
for( itOther = Childs.begin(); itOther != Childs.end(); itOther++ ) for( itOther = Children.begin(); itOther != Children.end(); itOther++ )
{ {
if( other == *itOther ) if( other == *itOther )
{ {
...@@ -182,7 +182,7 @@ IGUITreeViewNode* CGUITreeViewNode::insertChildBefore( ...@@ -182,7 +182,7 @@ IGUITreeViewNode* CGUITreeViewNode::insertChildBefore(
{ {
data2->grab(); data2->grab();
} }
Childs.insert_before( itOther, newChild ); Children.insert_before( itOther, newChild );
break; break;
} }
} }
...@@ -191,25 +191,25 @@ IGUITreeViewNode* CGUITreeViewNode::insertChildBefore( ...@@ -191,25 +191,25 @@ IGUITreeViewNode* CGUITreeViewNode::insertChildBefore(
IGUITreeViewNode* CGUITreeViewNode::getFirstChild() const IGUITreeViewNode* CGUITreeViewNode::getFirstChild() const
{ {
if( Childs.empty() ) if( Children.empty() )
{ {
return 0; return 0;
} }
else else
{ {
return *( Childs.begin() ); return *( Children.begin() );
} }
} }
IGUITreeViewNode* CGUITreeViewNode::getLastChild() const IGUITreeViewNode* CGUITreeViewNode::getLastChild() const
{ {
if( Childs.empty() ) if( Children.empty() )
{ {
return 0; return 0;
} }
else else
{ {
return *( Childs.getLast() ); return *( Children.getLast() );
} }
} }
...@@ -221,11 +221,11 @@ IGUITreeViewNode* CGUITreeViewNode::getPrevSibling() const ...@@ -221,11 +221,11 @@ IGUITreeViewNode* CGUITreeViewNode::getPrevSibling() const
if( Parent ) if( Parent )
{ {
for( itThis = Parent->Childs.begin(); itThis != Parent->Childs.end(); itThis++ ) for( itThis = Parent->Children.begin(); itThis != Parent->Children.end(); itThis++ )
{ {
if( this == *itThis ) if( this == *itThis )
{ {
if( itThis != Parent->Childs.begin() ) if( itThis != Parent->Children.begin() )
{ {
other = *itOther; other = *itOther;
} }
...@@ -244,11 +244,11 @@ IGUITreeViewNode* CGUITreeViewNode::getNextSibling() const ...@@ -244,11 +244,11 @@ IGUITreeViewNode* CGUITreeViewNode::getNextSibling() const
if( Parent ) if( Parent )
{ {
for( itThis = Parent->Childs.begin(); itThis != Parent->Childs.end(); itThis++ ) for( itThis = Parent->Children.begin(); itThis != Parent->Children.end(); itThis++ )
{ {
if( this == *itThis ) if( this == *itThis )
{ {
if( itThis != Parent->Childs.getLast() ) if( itThis != Parent->Children.getLast() )
{ {
other = *( ++itThis ); other = *( ++itThis );
} }
...@@ -266,7 +266,7 @@ IGUITreeViewNode* CGUITreeViewNode::getNextVisible() const ...@@ -266,7 +266,7 @@ IGUITreeViewNode* CGUITreeViewNode::getNextVisible() const
node = const_cast<CGUITreeViewNode*>( this ); node = const_cast<CGUITreeViewNode*>( this );
if( node->getExpanded() && node->hasChilds() ) if( node->getExpanded() && node->hasChildren() )
{ {
next = node->getFirstChild(); next = node->getFirstChild();
} }
...@@ -291,12 +291,12 @@ bool CGUITreeViewNode::deleteChild( IGUITreeViewNode* child ) ...@@ -291,12 +291,12 @@ bool CGUITreeViewNode::deleteChild( IGUITreeViewNode* child )
core::list<CGUITreeViewNode*>::Iterator itChild; core::list<CGUITreeViewNode*>::Iterator itChild;
bool deleted = false; bool deleted = false;
for( itChild = Childs.begin(); itChild != Childs.end(); itChild++ ) for( itChild = Children.begin(); itChild != Children.end(); itChild++ )
{ {
if( child == *itChild ) if( child == *itChild )
{ {
child->drop(); child->drop();
Childs.erase( itChild ); Children.erase( itChild );
deleted = true; deleted = true;
break; break;
} }
...@@ -311,11 +311,11 @@ bool CGUITreeViewNode::moveChildUp( IGUITreeViewNode* child ) ...@@ -311,11 +311,11 @@ bool CGUITreeViewNode::moveChildUp( IGUITreeViewNode* child )
CGUITreeViewNode* nodeTmp; CGUITreeViewNode* nodeTmp;
bool moved = false; bool moved = false;
for( itChild = Childs.begin(); itChild != Childs.end(); itChild++ ) for( itChild = Children.begin(); itChild != Children.end(); itChild++ )
{ {
if( child == *itChild ) if( child == *itChild )
{ {
if( itChild != Childs.begin() ) if( itChild != Children.begin() )
{ {
nodeTmp = *itChild; nodeTmp = *itChild;
*itChild = *itOther; *itChild = *itOther;
...@@ -336,11 +336,11 @@ bool CGUITreeViewNode::moveChildDown( IGUITreeViewNode* child ) ...@@ -336,11 +336,11 @@ bool CGUITreeViewNode::moveChildDown( IGUITreeViewNode* child )
CGUITreeViewNode* nodeTmp; CGUITreeViewNode* nodeTmp;
bool moved = false; bool moved = false;
for( itChild = Childs.begin(); itChild != Childs.end(); itChild++ ) for( itChild = Children.begin(); itChild != Children.end(); itChild++ )
{ {
if( child == *itChild ) if( child == *itChild )
{ {
if( itChild != Childs.getLast() ) if( itChild != Children.getLast() )
{ {
itOther = itChild; itOther = itChild;
++itOther; ++itOther;
...@@ -731,7 +731,7 @@ void CGUITreeView::mouseAction( s32 xpos, s32 ypos, bool onlyHover /*= false*/ ) ...@@ -731,7 +731,7 @@ void CGUITreeView::mouseAction( s32 xpos, s32 ypos, bool onlyHover /*= false*/ )
if( hitNode && !onlyHover if( hitNode && !onlyHover
&& xpos < hitNode->getLevel() * IndentWidth && xpos < hitNode->getLevel() * IndentWidth
&& xpos > ( hitNode->getLevel() - 1 ) * IndentWidth && xpos > ( hitNode->getLevel() - 1 ) * IndentWidth
&& hitNode->hasChilds() ) && hitNode->hasChildren() )
{ {
hitNode->setExpanded( !hitNode->getExpanded() ); hitNode->setExpanded( !hitNode->getExpanded() );
...@@ -873,7 +873,7 @@ void CGUITreeView::draw() ...@@ -873,7 +873,7 @@ void CGUITreeView::draw()
driver->draw2DRectangle( skin->getColor( EGDC_HIGH_LIGHT ), frameRect, &clientClip ); driver->draw2DRectangle( skin->getColor( EGDC_HIGH_LIGHT ), frameRect, &clientClip );
} }
if( node->hasChilds() ) if( node->hasChildren() )
{ {
core::rect<s32> rc; core::rect<s32> rc;
core::rect<s32> expanderRect; core::rect<s32> expanderRect;
...@@ -984,7 +984,7 @@ void CGUITreeView::draw() ...@@ -984,7 +984,7 @@ void CGUITreeView::draw()
// horizontal line // horizontal line
rc.UpperLeftCorner.X = frameRect.UpperLeftCorner.X - IndentWidth - ( IndentWidth >> 1 ) - 1; rc.UpperLeftCorner.X = frameRect.UpperLeftCorner.X - IndentWidth - ( IndentWidth >> 1 ) - 1;
rc.UpperLeftCorner.Y = frameRect.UpperLeftCorner.Y + ( ( frameRect.getHeight() ) >> 1 ); rc.UpperLeftCorner.Y = frameRect.UpperLeftCorner.Y + ( ( frameRect.getHeight() ) >> 1 );
if( node->hasChilds() ) if( node->hasChildren() )
{ {
rc.LowerRightCorner.X = frameRect.UpperLeftCorner.X - IndentWidth; rc.LowerRightCorner.X = frameRect.UpperLeftCorner.X - IndentWidth;
} }
......
...@@ -93,14 +93,14 @@ namespace gui ...@@ -93,14 +93,14 @@ namespace gui
//! returns the child item count //! returns the child item count
virtual u32 getChildCount() const virtual u32 getChildCount() const
{ return Childs.getSize(); } { return Children.getSize(); }
//! removes all childs (recursive) from this node //! removes all children (recursive) from this node
virtual void clearChilds(); virtual void clearChildren();
//! returns true if this node has child nodes //! returns true if this node has child nodes
virtual bool hasChilds() const virtual bool hasChildren() const
{ return !Childs.empty(); } { return !Children.empty(); }
//! Adds a new node behind the last child node. //! Adds a new node behind the last child node.
//! \param text text of the new node //! \param text text of the new node
...@@ -198,7 +198,7 @@ namespace gui ...@@ -198,7 +198,7 @@ namespace gui
//! Moves a child node one position down. //! Moves a child node one position down.
virtual bool moveChildDown( IGUITreeViewNode* child ); virtual bool moveChildDown( IGUITreeViewNode* child );
//! Returns true if the node is expanded (childs are visible). //! Returns true if the node is expanded (children are visible).
virtual bool getExpanded() const virtual bool getExpanded() const
{ return Expanded; } { return Expanded; }
...@@ -231,7 +231,7 @@ namespace gui ...@@ -231,7 +231,7 @@ namespace gui
void* Data; void* Data;
IReferenceCounted* Data2; IReferenceCounted* Data2;
bool Expanded; bool Expanded;
core::list<CGUITreeViewNode*> Childs; core::list<CGUITreeViewNode*> Children;
}; };
......
...@@ -329,7 +329,7 @@ private: ...@@ -329,7 +329,7 @@ private:
return; return;
#if defined (OCTREE_PARENTTEST ) #if defined (OCTREE_PARENTTEST )
if ( r == core::ISREL3D_CLIPPED ) if ( r == core::ISREL3D_CLIPPED )
parentTest = 1; // must still check childs parentTest = 1; // must still check children
#endif #endif
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment