ジェスチャー認識機能を使用すると、タッチ処理が処理されます。ほとんどの場合、ジェスチャーが認識される最小の指数を指定できます。お使いの場合には、例えば:
// -viewDidLoad
UISwipeGestureRecognizer *swipeRecognizer = [[UISwipeGestureRecognizer alloc] initWithTarget:self action:@selector(swiped:)];
swipeRecognizer.direction = UISwipeGestureRecognizerDirectionDown;
swipeRecognizer.numberOfTouchesRequired = 3;
[self.view addGestureRecognizer:swipeRecognizer];
[swipeRecognizer release];
...
- (void)swiped:(UISwipeGestureRecognizer *)recognizer
{
if(recognizer.state == UIGestureRecognizerStateRecognized)
{
// got a three-finger swipe
}
}
本当にありがとうございました!私はそれが必要な財産を逃したとは思っていません。あなたのために+1とチェックマーク! – CodaFi