init(collectionViewLayout:)
Initializes a dynamic animator with a specified collection view layout.
Declaration
convenience init(collectionViewLayout layout: UICollectionViewLayout)Parameters
- layout:
The collection view layout for the dynamic animator, serving as the reference view for a dynamic animator in collection-view mode.
Return Value
The initialized dynamic animator, or nil if there was a problem initializing the object.
Discussion
When you initialize a dynamic animator with this method, the behaviors (and their dynamic items) that you add to the animator employ the collection view layout’s coordinate system.