Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

UICollectionViewCell will be displayed/ was displayed?

pretty simple question.

Is there a notification or delegate-type method to tell when a UICollectionViewCell object is displayed?

like image 955
W Dyson Avatar asked Oct 01 '12 21:10

W Dyson


1 Answers

For iOS 8 and higher you can use willDisplayCell of UICollectionViewDelegate

- (void)collectionView:(UICollectionView *)collectionView willDisplayCell:(UICollectionViewCell *)cell forItemAtIndexPath:(NSIndexPath *)indexPath

like image 131
Anton Gaenko Avatar answered Nov 14 '22 16:11

Anton Gaenko