-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Specify end position for -scrollToObject #139
Comments
Absolutely. I've had this request internally too. We'll have to decide on whether or not this is a breaking change or not. Also we should get all the tests from #23 in place before doing this. |
@rnystrom This may be a silly question. But why we need to calculate the cell position manually inside |
@zhubofei in the case that you have a supplementary view at the beginning/end of your section and you want to scroll to the top of it. This happens in Instagram when we want to scroll to an item but align the top offset at the beginning of the supplementary view. We could probably simplify a lot of this API though, or maybe split it out into other parts. |
Still need unit test case for horizontal scrolling. |
The current implementation of -scrollToObject doesn't allow you to specify where you would like the section to be positioned at the end of the scroll. With Apple's implementation of -scrollToItem for a collectionView, they have a parameter called scrollPosition. This allows a user to specify whether the item should be positioned at the top, bottom, center etc. of the view.
It would be great if this feature could be implemented. For example, I want to be able to scroll to the very last cell, with the cell positioned at the bottom, when the keyboard is presented.
Thanks!
The text was updated successfully, but these errors were encountered: