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

Sticky item is invisible after replacing items below it #383

Closed
zoki- opened this issue Jun 7, 2017 · 5 comments
Closed

Sticky item is invisible after replacing items below it #383

zoki- opened this issue Jun 7, 2017 · 5 comments
Labels

Comments

@zoki-
Copy link

zoki- commented Jun 7, 2017

The setup is as follows:

  • there is a sticky item with a spinner for selecting
  • the sticky item is sticked for the user to filter items using the spinner when scrolling down and browsing those items, that are positioned below the sticky item
  • the user has scrolled down in the list, so the sticky view is sticked.

The action:

  • when user selects something from spinner, I do the following:
adapter.removeItemsOfType(R.layout.my_layout);
    to remove the items below the sticky view in the list.
    This is then immediately followed by
    adapter.onLoadMoreComplete(newItems);
    to add the new items user wants to see.

The result is:

  • list is scrolled to the top
  • sticky item is invisible, but still takes the space
  • new items are visible below the invisible sticky view
  • when scrolling a bit for the view to stick again to the top, the view becomes visible again

Expected result:

  • the sticky view should be visible when list is scrolled to the top
@davideas
Copy link
Owner

davideas commented Jun 7, 2017

@zoki- which version are you using?
I've fixed some bugs described in #320 and #347 and those fix are available in the Snapshot version and soon also in RC2.
Does that behaviour still occurs in the Snapshot version?

@zoki-
Copy link
Author

zoki- commented Jun 7, 2017

I'm using the 5.0.0-SNAPSHOT version.
The behavior occurs with this version.

@davideas
Copy link
Owner

davideas commented Jun 7, 2017

@zoki- well Ok, can you provide me the logs and parts of code?
If you can share the project even better.

@davideas
Copy link
Owner

@zoki-, without logs I can't be precise. I can only suspect that the layout manager didn't finish its work after the layout of removing and sticky header is not cleared, or is cleared but not scrolled to the top. Can you add the new items in post, delayed?
Separate the process: first delete and see if the header is still there without items, then, optionally you scroll to it, finally you add new items and see what happens.

@davideas
Copy link
Owner

Closing this issue: not reproducible.

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

No branches or pull requests

2 participants