Open abhinavsingh89 opened 10 years ago
Just an addition to this, If I do the above process slowly, i.e. by applying breakpoints, it is correct, but without breakpoints, it is showing one image at two places.
You seem to be setting cell.appIcon.imageURL twice for each cell - is that deliberate?
In any case, try calling this before setting the URL:
[[AsyncImageLoader sharedLoader] cancelLoadingImagesForTarget:cell.appIcon];
Please note this issue is happening only on iOS 8.0+
I have a collection view controller located in one tab(single page only right now, so cells are not actually reused). When I first go to this tab the first icon loads exact image, but as soon as it loads the 5th icon, it replaces 1st icon image with this first image, when I come back to this tab again(which is again refreshing), it sets it right. This issue is happening only with iOS 8.
(UICollectionViewCell )collectionView:(UICollectionView )collectionView cellForItemAtIndexPath:(NSIndexPath )indexPath { KBGameCell cell = [collectionView dequeueReusableCellWithReuseIdentifier:@"GameCell" forIndexPath:indexPath];
EBOXAppInfo content = (EBOXAppInfo )_gAppData.platformApps[indexPath.item];
NSURL *iurl; iurl = content.urlIconImage; NSLog(@"URL for app : %@ : %@ ",content.name, iurl);
cell.appIcon.image = nil; [cell.appIcon setShowActivityIndicator:YES]; cell.appIcon.imageURL = iurl; [cell.appName setText: content.name];
NSString *categoriesText = [_gAppData localizedCategoriesForAppInfo:content];
[cell.tagsLabl setText:categoriesText]; cell.appIcon.imageURL = content.urlIconImage;
return cell; }