Updated the Switch, Sequence and Group classes so that they all used a
similar style removeChild() mechansim. Made the old style osg::Switch::setValue() method deprecated.
This commit is contained in:
@@ -36,9 +36,11 @@ class SG_EXPORT Geode : public Node
|
||||
/** Remove Drawable from Geode.
|
||||
* Equivalent to setDrawabke(getDrawableIndex(orignChild),node),
|
||||
* see docs for setNode for futher details on implementation.*/
|
||||
|
||||
virtual bool removeDrawable( Drawable *drawable );
|
||||
|
||||
/** Remove drawable(s) from the specified position in Geode's drawable list.*/
|
||||
virtual bool removeDrawable(unsigned int i,unsigned int numDrawablesToRemove=1);
|
||||
|
||||
/** Replace specified Drawable with another Drawable.
|
||||
* Equivalent to setDrawable(getDrawableIndex(orignChild),node),
|
||||
* see docs for setDrawable for futher details on implementation.*/
|
||||
@@ -77,36 +79,6 @@ class SG_EXPORT Geode : public Node
|
||||
return false;
|
||||
}
|
||||
|
||||
/** return the iterator position for specified Drawable.
|
||||
* return _drawables.end() if gset not is contained in Geode.
|
||||
*/
|
||||
inline DrawableList::iterator findDrawable(const Drawable* gset)
|
||||
{
|
||||
|
||||
for (DrawableList::iterator itr=_drawables.begin();
|
||||
itr!=_drawables.end();
|
||||
++itr)
|
||||
{
|
||||
if (itr->get()==gset) return itr;
|
||||
}
|
||||
return _drawables.end();
|
||||
}
|
||||
|
||||
/** return the const_iterator position for specified Drawable.
|
||||
* return _drawables.end() if gset not is contained in Geode.
|
||||
*/
|
||||
inline DrawableList::const_iterator findDrawable(const Drawable* gset) const
|
||||
{
|
||||
|
||||
for (DrawableList::const_iterator itr=_drawables.begin();
|
||||
itr!=_drawables.end();
|
||||
++itr)
|
||||
{
|
||||
if (itr->get()==gset) return itr;
|
||||
}
|
||||
return _drawables.end();
|
||||
}
|
||||
|
||||
/** Get the index number of drawable, return a value between
|
||||
* 0 and _drawables.size()-1 if found, if not found then
|
||||
* return _drawables.size().*/
|
||||
|
||||
Reference in New Issue
Block a user