I have a collectionview
with custom collectionviewcell
. I want to make a gallery that only one image display on the screen at any time. What i have to do ?
Here is my code :
[myCollectionView registerClass:[myCustomCollectionViewCell class] forCellWithReuseIdentifier:"myIdentifier"];
-(UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath
{
myCustomCollectionViewCell *cell = (myCustomCollectionViewCell *)[collectionView dequeueReusableCellWithReuseIdentifier:@"myIdentifier" forIndexPath:indexPath];
cell.layer.masksToBounds=NO;
cell.imageView.image = [UIImage imageNamed:@"image"];
return cell;
}