开发者

Displaying images in UIScrollView programmatically

I am displaying 200 t开发者_Python百科humb nail images of size 4kb to 12kb in UIScrollView programmatically by adding UIButton when i am debugging in device it takes time to load the view.. can there is some method to load quickly the thumb mages are store in disk.


Use lazy loading by only loading the ones you show at once in any given moment - or use a background thread to perform the loading while keeping the interface responsive.


If your layout allows, use a table view and a custom cell that holds several thumbnails. That way you can use the tableview controller's built in methods to manage the lazy loading. I'm pretty sure that is how Apple does the thumbnails in the photo library.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜