Skip to content

HorizontalSelector bug#19

Open
kostyabakay wants to merge 1 commit intorealwear:masterfrom
kostyabakay:horizontal-selector-bug
Open

HorizontalSelector bug#19
kostyabakay wants to merge 1 commit intorealwear:masterfrom
kostyabakay:horizontal-selector-bug

Conversation

@kostyabakay
Copy link
Copy Markdown

HorizontalSelector has a bug with showing items when an adapter is updated from the LiveData observer. Sometimes it works fine, sometimes layout for items is not fully loaded and it shows only Command and State. HorizontalSelectorExampleActivity has LiveData implementation and the bug reproduces. FragmentHorizontalSelectorExample doesn't have LiveData implementation and the bug doesn't reproduce. I think the problem is inside of notifyDataSetChanged().

The real use-case scenario: Inject an adapter into Activity using Hilt. Observe changes with LiveData from the network or database and update an adapter when new data come.

See this video to understand what it looks like:
https://www.youtube.com/watch?v=S_ZIjq9NKVs

UXLibrary version: 1.5.0.493
Device: Navigator 500

This PR doesn't fix the bug! I don't have access to library code, so I reproduce the state where this bug appears and you can try it. Please, open the Issues page for this repository!

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

Successfully merging this pull request may close these issues.

1 participant