Reputation: 8526
Ok. I have made a custom cell for my table, and it contains a text view. When I have multiple lines in the text view, I can scroll up and down, but in doing this the table also scrolls. How can I stop this behaviour? If anyone needs parts of my code or further details, please just ask. I am more than willing.
Thank you for your help
Upvotes: 1
Views: 2413
Reputation: 53669
When the text view has focus, set scrollEnabled=NO
on the table view. You may have to manually remove focus from the text view and restore scrolling when a touch occurs outside the text view.
Upvotes: 0
Reputation: 15706
Did you try setting canCancelContentTouches
to NO? It's a property of UIScrollView, from which UITableView inherits.
Upvotes: 2
Reputation: 17189
Your custom cell seems to pass on touch events to its container class as well as utilizing them itself. Did you implement any - touchesBegan:
, - touchesMoved:
or - touchesEnded:
?
If you make use of a touch events, you should not pass them on in the responder chain.
Upvotes: 0
Reputation: 2012
I suggest you to move text edit (write) behavior to another view controller. If you need read-only functionality from it then just increase cell and textView height.
Upvotes: 2