I'm working on a project which has a lot of images displayed on several ImageViews inside Views which are in a ScrollableView component. So I have pages with a lot of ImageViews. I start loading the images when the user is approaching the page the image is on. When I'm at page 15 or something and I scroll back, the iPad (1) crashes because it runs out of memory.
All the images are 1024*768 (but displayed smaller). How do I (in an elegant way) unload the ImageViews which are not visible to the user and be able to load them again when the user is able to see it.
Thanks for tips :)
You can remove image view from view which have no longer use in this way:
Yes, I know that. But then I have to add/remove/add/remove it again when the user should see it. And that feels very slow on the iPad 1. Allready tried this, but maybe it is the best solution...
I ended up with a custom wrapper component which has a view and the imageview. I gave the component a custom blur/focus function which adds/removes the image from the parent view. Works pretty well I think.
Think you can help? Login to answer this question!