0

For my app I have a collectionview with cells that can be up and downvoted. I use the long press gesture recognizer to account for users hold+dragging up and down to upvote or downvote.

A problem crops up however, when the user's finger slides over either the navigation controller, or outside of any cells at the bottom of the collection view's content.

The gesture is not "canceling" nor "ending" when this happens. The gesture recognizer just holds.

I'm wondering if there's a way to get around this?

Ideally my user's finger should be able to go anywhere on the screen after the initiating the long press, and ending anywhere on the screen (even outside of the collectionview) and still finish calling the function.

Any help?

user3488148
  • 59
  • 1
  • 8
  • Does your collectionView extend under the bars? –  Jan 24 '16 at 01:45
  • Sorry, how would I check that? – user3488148 Jan 24 '16 at 02:44
  • `automaticallyAdjustsScrollViewInsets` or Adjust Scroll View Insets in Storyboard –  Jan 24 '16 at 02:46
  • Okay I unchecked Adjust Scroll View Insets. It now works when the long press goes over the navigation bar. But the entire collection view moves up under the nav bar now. Any idea how to prevent that? And what about the empty white space underneath the collectionview? – user3488148 Jan 24 '16 at 03:56

0 Answers0