so basically i do something like this…
private var loader:Loader;
private var pointer:uint = 0;
private var urls:Array;
function loadSomething(url:string){
loader = new Loader();
loader.contentLoaderInfo.addEventListener(Event.COMPLETE , handleLoadComplete);
loader.load(new urlRequest(urls[pointer]);
}
function handleLoadComplete(e:Event){
loader.contentLoaderInfo.removeEventListener(Event.COMPLETE , handleLoadComplete);
trace("load complete: " + pointer);
pointer++;
if(pointer != urls.length){
loadSomething();
}
}
and loading stops after 1. load it also shows no progress if i add and remove progressEvent listener , can som1 tell me if it is a bug and why it acts like that?
It works fine if i dont removeEventListener … but as far as i know i am adding listener to instance of variable, and when i create new instance of that variable what happend before should have no effect.