Hi,
First thank You for great classes and sorry for any mistakes in my english.
I have a little problem with newer SWFLoader versions (probably from 1.766).
My external SWF contain this:
(...)
if(stage == null) {
addEventListener(Event.ADDED_TO_STAGE, added, false, 0, true);
}
else {
added();
}
function added(event:Event = null):void
{
removeEventListener(Event.ADDED_TO_STAGE, added);
addEventListener(Event.REMOVED_FROM_STAGE, unloadThis);
(...)
}
(...)
function unloadThis(e:Event):void
{
trace("ok");
(...)
}
When I load this SWF, first it dispatch REMOVED_FROM_STAGE event so error occur, then go rest of the code. But when I unload this SWF, it don't dispatch REMOVED_FROM_STAGE event again.
In earlier versions of SWFLoader everything works correct: load SWF without errors and when unload, it dispatch REMOVED_FROM_STAGE event.
Maybe something has change or I do it wrong so please correct me.