Closed antons81 closed 6 years ago
Hi, You have to call section(from:) from collectionView.infiniteLatout, not directly from collectionView
Hi, thanks for the quick answer. But these methods are different.
public func section(from infiniteSection: Int) -> Int {
return InfiniteDataSources.section(from: infiniteSection, numberOfSections: delegateNumberOfSections)
}
public func indexPath(from infiniteIndexPath: IndexPath) -> IndexPath {
return InfiniteDataSources.indexPath(from: infiniteIndexPath,
numberOfSections: delegateNumberOfSections,
numberOfItems: delegateNumberOfItems(in: infiniteIndexPath.section))
}`
Ok solved it. I added layout files manually to the project and added to extension and class @objc/@objcMembers. Then called NSIndexPath *index = [self.selectedItemsCollection indexPathFrom:indexPath];
It solved my issue
Hi, I am gettin wrong
indexPath
, while inserting item to array and reloading collection view. How to call this method from obj-c?func section(from infiniteSection: Int) -> Int