Open GoogleCodeExporter opened 9 years ago
I had the same issue with spark BorderContainer
public function addChild(container:Object, child:Object):void
{
if( container is Group )
{
(container as Group).addElement( child as IVisualElement );
}
if( container is SkinnableContainer)
{
(container as SkinnableContainer).addElement( child as IVisualElement );
}
else if( container is Container )
{
(container as Container).rawChildren.addChild(child as DisplayObject);
}
else
{
container.addChild( child as DisplayObject);
}
}
public function removeChild(container:Object, child:Object):void
{
if( container is Group )
{
(container as Group).removeElement( child as IVisualElement );
}
if( container is SkinnableContainer)
{
(container as SkinnableContainer).removeElement( child as IVisualElement );
}
else if( container is Container )
{
(container as Container).rawChildren.removeChild(child as DisplayObject);
}
else
{
container.removeChild( child as DisplayObject);
}
}
Original comment by moya.t...@gmail.com
on 25 Jul 2011 at 6:39
Original issue reported on code.google.com by
burd...@gmail.com
on 26 Apr 2010 at 12:25