【问题标题】:Async Images Download in a UITableView using Storyboard & ios5使用 Storyboard 和 ios5 在 UITableView 中下载异步图像
【发布时间】:2012-02-18 02:41:30
【问题描述】:

我有一个 UITableView,我想异步下载图像。 如何使用 ios5 和故事板?

提前致谢

【问题讨论】:

    标签: iphone uitableview asynchronous uiimageview storyboard


    【解决方案1】:

    我遇到了同样的问题,我所做的是从https://github.com/rs/SDWebImage 获取 SDWebImage,自行打开项目,然后手动将其升级到 Objective C ARC(重构 --> 转换为 Objective C ARC) .

    当它完成转换后,我将它添加到我的项目中,它就像一个魅力。我只是

    #import "UIImageView+WebCache.h"
    

    然后在我的 - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath 方法中,它看起来像这样:

    [cell.videoImageView setImageWithURL:[NSURL URLWithString:thumbnailURLString]];
    

    简单!

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2012-02-27
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多