Skip to content
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

fast scrolling? (enhancement) #40

Open
gloparco opened this issue Jun 15, 2018 · 1 comment
Open

fast scrolling? (enhancement) #40

gloparco opened this issue Jun 15, 2018 · 1 comment

Comments

@gloparco
Copy link

Where would I alter the code to allow fast scrolling? By fast scrolling, I am referring to the fact that the current animations allow "one cell at a time" scrolling, rather than the typical UIScrollView scrolling.

In particular, what I think would be useful would be to allow for fast scrolling and then upon stopping (either manually, or once the animation finishes), snapping to the closest cell.

I know the author of this is busy, but if someone could point me in the right direction, perhaps I can create a pull request and work on it myself.

@KelvinJin
Copy link
Owner

Hi! The 'pagingEnabled' property of the UICollectionView is true by recommendation, but you can definitely turn it off so you have the normal behaviour. For snapping, you can definitely override the AnimatrdCollectionViewLayout and implement the targetContentOffset method. You can find some examples on GitHub too. Overriding might not be possible, but feel free to copy the code or submit a PR!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants