0

I have an UIWebview where i'm loading multiple URL's using SwipeGesture i'm swiping to next page. I have used this code to do this,

UISwipeGestureRecognizer* swipeUpGestureRecognizer = [[UISwipeGestureRecognizer alloc] initWithTarget:self action:@selector(handleSwipeUpFrom:)];
swipeUpGestureRecognizer.direction = UISwipeGestureRecognizerDirectionUp;

in handleSwipeUpFrom method i'm loading next URL in my webview. Everything works PERFECTLY. But the swipe is works so fastly. I want to make some delay to it, any ideas....

4

1 回答 1

1

它可能有点混乱,但如果没有人有更清洁的解决方案,试试这个:

- (void)handleSwipeUpFrom:(id)sender
{
    [self performSelector:@selector(anotherMethod:) withObject:object afterDelay:1.0];
}
于 2013-04-03T17:34:16.510 回答