1

i would like to know if is possible open/show a new view swiping down ( or up ) from the navigation bar, just like the notification center view in iOS 5 ( it appear from status bar, and i think this isn't possible for normal apps, right? ). Thanks :)

Andrea Mario Lufino
  • 7,921
  • 12
  • 47
  • 78

1 Answers1

2

You have to use UISwipeGestureRecognizer. Here's the code :

UISwipeGestureRecognizer *swipeUp=[[UISwipeGestureRecognizer alloc] initWithTarget:self action:@selector(youSelector:)];
[swipeUp setNumberOfTouchesRequired:2];
[swipeUp setDirection:UISwipeGestureRecognizerDirectionUp];
[yourView addGestureRecognizer:swipeUp];
Andrea Mario Lufino
  • 7,921
  • 12
  • 47
  • 78