ios - UITableview with images scroll very slowly -
After
I downloaded a I noticed that the table scrolls very slowly You are loading the image file on the main thread and this operation will take your scroll Is slowing down Use the UITableView its
UITableViewCell which is a Images. Server
- (UITableViewCell *) tableView:. (UITableView *) tableView cellForRowAtIndexPath: (NSIndexPath *) indexPath {static NSString * Cell identifier = @ "Pendulum cell"; JBParallaxCell * cell = [tableView dequeueReusableCellWithIdentifier: CellIdentifier]; NSURL * imageUrl = [NSURL URLWithString: [[News objectAtIndex: indexPath.row] objectForKey: @ "Resim"]]; NSDTA * ImageData = [NSDTATA DATAVITY content of the: imageURL]; UIImage * imageLoad = [[UIImage alloc] initWithData: imageData]; cell.titleLabel.text = [[News objectAtIndex: indexPath.row] objectForKey: @ "Eddie"]; cell.subtitleLabel.text = [[News objectAtIndex: indexPath.row] objectForKey: @ "Resim"]; Cell. Pattern image. Image = image load; cell.selectionStyle = UITableViewCellSelectionStyleNone; Return cell; }
UIImageView + AFNetworking.h from F-Networking to speed up your application via Async image loading. Link
Comments
Post a Comment