Reputation: 353
I have been struggling with this problem for last 5 days and unable to make any significant breakthrough.
Background: I have a UICollectionView with a custom layout. the UICollectionView has a textView for users to edit the cells content.
Issue: I want to invoke the sizeForItemAtIndexPath but I am unable to do so. I have even extended the UICollectionViewDelegateFlowLayout protocol but still not able to get it working. Strange thing is that it works fine for a flowlayout
I would appreciate if you'll can help me to get further insights or point out where i am going wrong.
Thanks
Upvotes: 1
Views: 318
Reputation: 353
To confirm, I changed the layout from custom to flow and the method is invoked. Looks like sizeForItemAtIndexPath method is invoked only for flowlayout and not custom layout.
Upvotes: 1