mutualmobile / MMDrawerController

A lightweight, easy to use, Side Drawer Navigation Controller
MIT License
6.76k stars 1.38k forks source link

[panGesture setEnabled:NO]被禁用时,动画结束后,未设置 [panGesture setEnabled:NO],致使panGesture不可用 #503

Open 2103677649 opened 6 years ago

2103677649 commented 6 years ago

-(void)setAnimatingDrawer:(BOOL)animatingDrawer{

_animatingDrawer = animatingDrawer;
[self.view setUserInteractionEnabled:!animatingDrawer];

//panGesture == self.mPanGesture if (_animatingDrawer == NO) { if (self.mPanGesture && self.mPanGesture.enabled == NO) self.mPanGesture.enabled = YES; } }

-(void)panGestureCallback:(UIPanGestureRecognizer *)panGesture{

switch (panGesture.state) {

    case UIGestureRecognizerStateBegan:{

        if(self.animatingDrawer){

            [panGesture setEnabled:NO];

            break;

        }