In a CollectionView
, some cells should have an additional subview or layer. The CollectionView
can be told to resize it\'s cells, thus all content
I had the same problem. Switching between two layouts did not resize the Pictures (UIImage) inside my cells. My Cells where build without a xib. And I used two different cell classes for each CollectionViewCustomLayout.
I fixed this programatically with this:
self.autoresizesSubviews = YES;
in my UICollectionViewCell subclasses.
But this only worked for me by adding the Picture as a cells backgroundpicture like this:
cell.backgroundView[[UIImageView alloc] initWithImage: SumDummyImage ];