قالب وردپرس درنا توس
Home / IOS Development / Swift more than one behavior in the same UICollectionView

Swift more than one behavior in the same UICollectionView



I add a custom collectionViewLayout to CollectionView . I have 6 cells and I send the next item with standard animation style. But when I pass the last cell, I will create an animation like PageAnimation (custom). I add collectionViewLayout to viewDidLoad but it affects all cells.

  la layout = AnimatedCollectionViewLayout ()
layout.animator = PageAttributesAnimator ()
layout.scrollDirection =. horizontal
collectionView.collectionViewLayout = layout

How can I use 2 different layout types in a CollectionView ?

Thanks in advance.


Source link