0

When I have my telephone in vertical, perfect I have one cell under other under other (....) but when I put my telephone in horizontal I have this problem:

image

So, how can I put a cell per one row when I put my telephone in horizontal?.

Termininja
  • 6,620
  • 12
  • 48
  • 49
Rachel
  • 1
  • Maybe you have fixed width for cells and so they are behaving differently. If you want same behavior assign width & constraints to cells according to screen bounds and reload them on transitions for portrait and landscape. – Muhammad Ali Mar 24 '16 at 09:59
  • Do you know how can I put CGSize with the size the screen ( like auto layaut) ? – Rachel Mar 24 '16 at 10:27
  • `func collectionView(collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, sizeForItemAtIndexPath indexPath: NSIndexPath) -> CGSize { return CGSizeMake(UIScreen.mainscreen.bounds.width, 350) }` – Muhammad Ali Mar 24 '16 at 10:33

0 Answers0