-
-
Notifications
You must be signed in to change notification settings - Fork 312
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
[tvOS][Bug] Fixes season selector only showing a single season. #950
Conversation
Upon initial view load, only the first season is loaded into `menuSections` when the episode list is resolved. This change stores the list of all seasons, which contain their display name. When changing the series selector, `menuSections` is updated with season details. Also when changing seasons in the picker, the containing scroll view scrolled to the top of the page. This was jarring. This change also removes that behavior.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I seem to have broken this in: https://github.com/jellyfin/Swiftfin/pull/883/files#diff-1462c1160e5edfcfdbf96fa2622aeaead21bbc319987b8bfb6ace9cd32e66382L145
We shouldn't create a new variable to hold what seasons are there, that's what keys for the menuSections
dictionary are. For now, what we should do is mimic the work that was done before where we instead set an empty array to each season before we get the episodes for the first season and when a season is selected and if it is empty, get the episodes for the season.
I have done work in #905 that lays the foundation for an eventual refactor of this entire view model so that episodes can be lazily loaded, mainly for the case of large seasons (eg: FMAB is one season with ~60 episodes).
Thanks for the review! PTAL. |
Done. PTAL. |
Thanks! Updated. PTAL. |
Upon initial view load, only the first season is loaded into
menuSections
when the episode list is resolved.This change stores the list of all seasons, which contain their display name. When changing the series selector,
menuSections
is updated with season details.Also when changing seasons in the picker, the containing scroll view scrolled to the top of the page. This was jarring. This change also removes that behavior.