21

enter image description here

I have screens like this photo. HomeViewController will push to maintabbar, and a tabbar item will push to detailScreen. Why swipe back not working. I think it is default in IOS. Please help me

p/s: If i use SwipeBack in cocoapods, it working. But i don't want use it

Nguyen Hoan
  • 1,583
  • 1
  • 11
  • 18

3 Answers3

62

Try setting the interactive pop gesture recognizer delegate to nil:

self.navigationController.interactivePopGestureRecognizer.delegate = nil;
davidethell
  • 11,708
  • 6
  • 43
  • 63
0

I got the same issue which was fixed after this

self.navigationController?.interactivePopGestureRecognizer?.isEnabled = true
self.navigationController?.interactivePopGestureRecognizer?.delegate = self
user16217248
  • 3,119
  • 19
  • 19
  • 37
-3

I have similar problem & got fixed using method from this answer

Simply, did you call

[super viewWillAppear:animated];

when overriding

- (void)viewWillAppear:(BOOL)animated {
    [super viewWillAppear:animated];
    // your other codes goes on
}
Stephen Kennedy
  • 20,585
  • 22
  • 95
  • 108
clichedmoog
  • 305
  • 2
  • 7