美文网首页
iOS开发 StoryBoard使用FDFullscreenPo

iOS开发 StoryBoard使用FDFullscreenPo

作者: LearningCoding | 来源:发表于2017-10-27 11:32 被阅读47次

在使用纯代码时:
隐藏 NavigationBar 的界面
navigationController.fd_fullscreenPopGestureRecognizer.enabled = NO;
viewController.fd_interactivePopDisabled = YES;
使用 SB 时:
隐藏 NavigationBar


image.png
image.png

fd_prefersNavigationBarHidden
fd_interactivePopMaxAllowedInitialDistanceToLeftEdge

使用ScrollView,在 .m 代码里加入

- (BOOL)gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer shouldRecognizeSimultaneouslyWithGestureRecognizer:(UIGestureRecognizer *)otherGestureRecognizer {
    if (self.contentOffset.x <= 0) {
        if ([otherGestureRecognizer.delegate isKindOfClass:NSClassFromString(@"_FDFullscreenPopGestureRecognizerDelegate")]) {
            return YES;
        }
    }
    return NO;
}

相关文章

网友评论

      本文标题:iOS开发 StoryBoard使用FDFullscreenPo

      本文链接:https://www.haomeiwen.com/subject/wzhcpxtx.html