How can I detect if my interactivePopGestureRecognizer is completed and will back (pop) to previous view controller or shift is not enough. Then current view controller will back to his normal position.
my code:
if ([self respondsToSelector:@selector(interactivePopGestureRecognizer)]) {
[self.interactivePopGestureRecognizer addTarget:self action:@selector(defaultGestureAction:)];
}
- (void)defaultGestureAction:(UIGestureRecognizer *)sender {
if (sender.state == UIGestureRecognizerStateBegan || sender.state == UIGestureRecognizerStateChanged) {
} else {
//this code is fired when I touch up
//is there any way to check this action (pop or stay)?
}
}