// // FKNavigationController.m // FirstLink // // Created by ascii on 15/9/2. // Copyright (c) 2015年 FirstLink. All rights reserved. // #import "FKNavigationController.h" @interface FKNavigationController () @end @implementation FKNavigationController - (void)viewDidLoad { [super viewDidLoad]; // Do any additional setup after loading the view. // WeakSelf(weakSelf); // if ([self respondsToSelector:@selector(interactivePopGestureRecognizer)]) { // self.interactivePopGestureRecognizer.delegate = weakSelf; // self.delegate = weakSelf; // } } - (void)didReceiveMemoryWarning { [super didReceiveMemoryWarning]; // Dispose of any resources that can be recreated. } /* #pragma mark - Navigation // In a storyboard-based application, you will often want to do a little preparation before navigation - (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender { // Get the new view controller using [segue destinationViewController]. // Pass the selected object to the new view controller. } */ //- (void)pushViewController:(UIViewController *)viewController animated:(BOOL)animated { // if ( [self respondsToSelector:@selector(interactivePopGestureRecognizer)] && animated == YES ) { // self.interactivePopGestureRecognizer.enabled = NO; // } // [super pushViewController:viewController animated:animated]; //} // //- (NSArray *)popToRootViewControllerAnimated:(BOOL)animated { // if ( [self respondsToSelector:@selector(interactivePopGestureRecognizer)] && animated == YES ) { // self.interactivePopGestureRecognizer.enabled = NO; // } // return [super popToRootViewControllerAnimated:animated]; // //} // //- (NSArray *)popToViewController:(UIViewController *)viewController animated:(BOOL)animated { // if( [self respondsToSelector:@selector(interactivePopGestureRecognizer)] ) { // self.interactivePopGestureRecognizer.enabled = NO; // } // return [super popToViewController:viewController animated:animated]; //} #pragma mark UINavigationControllerDelegate //- (void)navigationController:(UINavigationController *)navigationController // didShowViewController:(UIViewController *)viewController // animated:(BOOL)animate { // if ([self respondsToSelector:@selector(interactivePopGestureRecognizer)]) { // self.interactivePopGestureRecognizer.enabled = YES; // } //} // // //-(BOOL)gestureRecognizerShouldBegin:(UIGestureRecognizer *)gestureRecognizer { // if ( gestureRecognizer == self.interactivePopGestureRecognizer ) { // if ( self.viewControllers.count < 2 // || self.visibleViewController == [self.viewControllers objectAtIndex:0] ) { // return NO; // } // } // return YES; //} @end