- (void)viewWillAppear:(BOOL)animated
{
[super viewWillAppear:animated];
self.navigationController.interactivePopGestureRecognizer.delegate = self;
}
- (BOOL)gestureRecognizerShouldBegin:(UIGestureRecognizer *)gestureRecognizer{
DLog(@"%ld子VC",self.navigationController.childViewControllers.count);
return self.navigationController.childViewControllers.count > 1;//是不是rootvc
}
// self.navigationController.navigationBarHidden = NO;
盡量用下邊這個來隱藏顯示.不解釋,都是坑
[self.navigationController setNavigationBarHidden:NO animated:YES];
注:FDFullscreenPopGesture 這個很6,可以搜一下,一句代碼都不需要就可以實(shí)現(xiàn)