FSPageContentView和系统侧滑返回手势冲突解决
2023-11-20 本文已影响0人
漫步云端_91cd
1.将pageContentView的collectionView属性生成放在.h里面,可以对外调用
2.手势判断滑动到屏幕边缘时,把pageContentView.collectionView的手势禁掉。代码如下
for (UIGestureRecognizer *gesture in self.navigationController.view.gestureRecognizers) {
if ([gesture isKindOfClass:[UIScreenEdgePanGestureRecognizer class]]){
[self.pageContentView.collectionView.panGestureRecognizer requireGestureRecognizerToFail:gesture];
}
}