Hey Folks,
I am using multiple xhr clients to fetch images. I Don't have any idea on how to deallocate xhr objects from memory. I am declaring xhr objects in a loop. Will asigning xhr to null in the end of xhr.onload do the trick? do i also need to remove the event listeners -> xhr.onload and ->xhr.onerror on each object? using Android 2.3.3 with ti sdk 2.0.1GA2
Thanks
1 Answer
Sounds like a bad idea. Why don't you just get your application server to generate a single JSON file with pointers to all those images? In this way you can loop over a single xhr client and get everything. (of course this depends on what exactly you are doing).
but roughly speaking, going through a loop of xhr's ... sounds nasty :-)
Just share your code to get a feeling of what you are doing and see how to improve this.
G.
Your Answer
Think you can help? Login to answer this question!