RemoveChild(); and loader.unload();

I am loading external .swfs into a main .swf. Only one of the .swfs will be added to the stage and the main .swf will be removed using RemoveChild();.

Is it necessary to loader.unload all loaded external .swfs or does simply removing the child containing the loader do the work so everything that was loaded gets garbage collected?

What unload does is removes the content from the loader. If you remove the loader from its parent, assuming you have no other references to the loader whatsoever, then its pretty much doing the same thing. It wouldn’t hurt to use unload to be on the safe side.

Thanks! That’s what I was thinking. Just wanted a second opinion.