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

[Android] Fix CarouselView behavior with device orientation changes #21635

Closed
wants to merge 5 commits into from

Conversation

jsuarezruiz
Copy link
Contributor

@jsuarezruiz jsuarezruiz commented Apr 4, 2024

Description of Change

Fix CarouselView behavior with device orientation changes.

Currently, by changing the orientation we are:

  • Trigger the scroll event.
  • We update position.

Actually, when changing the orientation, none of the above is necessary besides being left with an incorrect Layout, usually between two elements.

For example, the CurrentItem is 3 and rotating the device:
bug-21609

With the changes we avoid to update position etc rotating the device, and check if need to center the current item. If necessary, scroll adjustment is made.
fix-21609

Issues Fixed

Fixes #21609
Fixes #21401

@jsuarezruiz jsuarezruiz added t/bug Something isn't working platform/android 🤖 area-controls-collectionview CollectionView, CarouselView, IndicatorView labels Apr 4, 2024
@jsuarezruiz jsuarezruiz requested a review from a team as a code owner April 4, 2024 10:40
@PureWeen PureWeen marked this pull request as draft April 4, 2024 17:40
@jsuarezruiz
Copy link
Contributor Author

@PureWeen Should we close in favor of #21662?

@github-actions github-actions bot locked and limited conversation to collaborators May 11, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-controls-collectionview CollectionView, CarouselView, IndicatorView platform/android 🤖 t/bug Something isn't working
Projects
None yet
1 participant