I have a collectionView and each cell contains an image. Now I want to highlight the image to become highlighted like the iPhone app icon when you select it.
I had try this code but it doesn't work,it just highlighted the background.
- (BOOL)collectionView:(UICollectionView *)collectionView shouldHighlightItemAtIndexPath:(NSIndexPath *)indexPath
{ Cell* cell = (Cell*)[collectionView cellForItemAtIndexPath:indexPath];
cell.img.tintColor = [UIColor colorWithWhite:0 alpha:0.5 ];
return YES;
}