wsl2ls/WSLWaterFlowLayout

scrollToItemAtIndexPath不能移动

Closed this issue · 1 comments

[collectionView scrollToItemAtIndexPath:[NSIndexPath indexPathForRow:2 inSection:3] atScrollPosition:UICollectionViewScrollPositionCenteredHorizontally animated:YES],调用之后collectionview不移动是怎么回事?

[collectionView scrollToItemAtIndexPath:[NSIndexPath indexPathForRow:2 inSection:3] atScrollPosition:UICollectionViewScrollPositionCenteredHorizontally animated:YES],调用之后collectionview不移动是怎么回事?

我这儿看了,没问题呀,你是否参数弄错了,UICollectionViewScrollPositionCenteredHorizontally 水平方向的中心
UICollectionViewScrollPositionCenteredVertically 垂直方向的中心