我已在我的应用中配置MMDrawController
,UITabBarController
为initialviewcontroller
。
self.drawerController = [[MMDrawerController alloc] initWithCenterViewController:self.rootTabBarController leftDrawerViewController:leftSideNavigationController];
self.drawerController.openDrawerGestureModeMask = MMOpenDrawerGestureModePanningCenterView;
self.drawerController.closeDrawerGestureModeMask = MMCloseDrawerGestureModePanningCenterView;
[self.drawerController setGestureShouldRecognizeTouchBlock:^BOOL(MMDrawerController *drawerController, UIGestureRecognizer *gesture, UITouch *touch) {
if ([gesture isKindOfClass:[UITapGestureRecognizer class]]) {
return FALSE;
}
return !([touch.view isKindOfClass:[UISlider class]]) && !([touch.view isKindOfClass:[UIScrollView class]]) && !([touch.view isKindOfClass:[ADNetworkFeedDropdownView class]]) && [gesture isKindOfClass:[UIPanGestureRecognizer class]];
}];
然而,其中一个视图控制器具有无限滚动视图,当我在该特定视图控制器的无限滚动视图上滑动时,我想禁用MMDrawViewController
的平移。目前,如果我在滚动视图上滑动,左侧平移将打开。我试过了becomeFirstresponder
,它没有用。