Re: [Flashcoders] Is this error prone? [loading multiple images]

2009-07-09 Thread Ktu
I think I see a problem with this. I don't know how often GarbageCollection runs, but if the loader you create has no references to it, and the only event listener to it is set to have a weakReference, then the loader could get discarded before it finishes, unless the act of loading doesn't allow

Re: [Flashcoders] Is this error prone? [loading multiple images]

2009-07-09 Thread Joel Stransky
That's good thinking. I'll have to look into it some more. This one is just hard to test since removeEventListener fails silently if the listener isn't on the targets listener list. On Thu, Jul 9, 2009 at 12:53 PM, Ktu ktu_fl...@cataclysmicrewind.comwrote: I think I see a problem with this. I

[Flashcoders] Is this error prone? [loading multiple images]

2009-07-07 Thread Joel Stransky
I'm wondering if I can use a for loop to create local Loader objects, assign listeners to their LoaderInfo objects without overwriting any of them and still be able to clean up after. Say I have the following inside a function body var img:Loader = new Loader();