UINavigationController Interactive Pop Gesture Not Working?

前端 未结 10 1471
你的背包
你的背包 2020-12-13 10:02

So I have a navigation controller in my built for iOS 7 app. The titleView is visible, as well as the back button and navigation bar its self. For some reason, the interac

10条回答
  •  余生分开走
    2020-12-13 10:33

    The more worked out answer was both Aaron and lojals

    First Customise the Navigation controller and then put this code in the class

    In ViewDidload put this line:

    self.navigationController.interactivePopGestureRecognizer.delegate = (id)self;
    

    And in class write this function

    -(BOOL)gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer shouldRecognizeSimultaneouslyWithGestureRecognizer:(UIGestureRecognizer *)otherGestureRecognizer { return YES;}
    

提交回复
热议问题