Closed yly6518 closed 3 months ago
当遵循JXPagingViewListViewDelegate协议返回的view是collectionview,并且设置了isPagingEnabled = true,会导致上划cell,在header吸顶之后,collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath) 代理方法无法响应第一次点击事件。同时,只要header一直处于吸附状态,上划collectionview,所有出现的cell都无法响应第一次点击事件。
isPagingEnabled = true
collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath)
不设置isPagingEnabled = true 则正常。 Demo工程中已复现,将PagingListBaseView中的tableview替换成collectionview,并设置了isPagingEnabled = true,必定复现。
PagingListBaseView
tableview
图1,header未吸顶,点击item0,触发didSelectItemAt代理 图2,上划collectionview, header吸顶,点击item0,没有触发didSelectItemAt代理,再次点击,触发。 图3,继续上划collectionview,header处于吸顶状态,点击item1,没有触发didSelectItemAt代理,再次点击,触发。
当遵循JXPagingViewListViewDelegate协议返回的view是collectionview,并且设置了
isPagingEnabled = true
,会导致上划cell,在header吸顶之后,collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath)
代理方法无法响应第一次点击事件。同时,只要header一直处于吸附状态,上划collectionview,所有出现的cell都无法响应第一次点击事件。不设置
isPagingEnabled = true
则正常。 Demo工程中已复现,将PagingListBaseView
中的tableview
替换成collectionview,并设置了isPagingEnabled = true
,必定复现。