Open kobenguyent opened 6 years ago
u should move the code " currentPageIndex = updatedPageIndex thumbnailCollectionController?.currentPageIndex = currentPageIndex" on the func scrollViewDidScroll to the other place, like this: public func collectionView(_ collectionView: UICollectionView, willDisplay cell: UICollectionViewCell, forItemAt indexPath: IndexPath) { currentPageIndex = indexPath.row self.title = String(format: "%d/%d",currentPageIndex,self.document.pageCount) thumbnailCollectionController?.currentPageIndex = currentPageIndex }
I tried to pass the startPageIndex as 10 but the pdf is not loaded as page 11
Could you please advise?