0

我如何在滚动视图中通过lazyimageloading显示图像任何人都可以建议答案


xview = 21;//30
yview = 21;
yscroll = 150;//200
h=1;
NSLog(@"arr count %d",[filelistarr count]);

for(int s=0;s<[filelistarr count];s++)
{
    obj=[filelistarr objectAtIndex:s];
    scrollview.contentSize=CGSizeMake(320, yscroll);
    if(h%4 == 0)
    {
        xview=21;
        h=1;
        yview=yview+120;
        //yscroll=yscroll+20;
    }

    imgbtn = [UIButton buttonWithType:UIButtonTypeCustom];
    imgbtn.frame = CGRectMake(xview, yview, 80, 80);
    imgbtn.layer.borderWidth = 0;
    imgbtn.layer.borderColor = [[UIColor blackColor] CGColor];
    imgbtn.tag=(s+1);

}
  • 图像设置按钮正确但是如何设置延迟图像加载请帮助我....
4

1 回答 1

0

看到这个http://lazyloadinginuiscrollviewiniphone.blogspot.in/2011/12/iphone-uiscrollview-lazy-image-loading.html我希望它能满足你的所有要求。还有类似类型的问题,请参见以下链接,

1)uiscrollview 懒加载

2)多滚动视图和动态图像的延迟加载

3) iOS UIScrollView 延迟加载

于 2013-03-22T07:22:57.573 回答