2014-07-25 3 views

답변

0

ECSlidingViewController를 사용할 때 좀 더 테스트하고 읽은 후 사용자 정의 제스처를 이해할 수있었습니다.

실제로 매우 간단합니다!

사용자 정의 제스처 만들기 :

- (UITapGestureRecognizer *)localTapGesture { 
    if (_localTapGesture) return _localTapGesture; 

    _localTapGesture = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(customResetTopView)]; 

    return _localTapGesture; 
} 

당신의 slidingViewController를 인스턴스화, 사용자 지정 제스처를 사용하도록 topViewAnchoredGesture 설정을 :

self.slidingViewController.topViewAnchoredGesture = ECSlidingViewControllerAnchoredGestureCustom; 

그럼 그냥 당신이 customAnchoredGestures 중 하나로 만든 제스처 인식기를 추가 :

self.slidingViewController.customAnchoredGestures = @[self.localTapGesture];