Skip to content

Firebase UI version 3: calling startListening() inside onStart() reloads the whole list. #1233

@svidata

Description

@svidata

Hello all and thanks for this great library, I am using version 3 of firebase ui in my android app. Now as suggested in the library documentation

I call start listening in onStart() method, like this:

mAdapter.startListening();

I call stop in onStop() method, like this:

mAdapter.stopListening();

These work perfectly they start and they stop no issue with that, but the problem comes when I resume my activity (in other words: when I revisit my activity by pressing back button) then the whole recyclerview restarts and scrolls back to the top. So it doesnt make sense to press item F and go to its detail activity and return to see that you are now on item A due to reload of the list.

If I try to start and stop using onCreate and onDestroy then I cant guarantee that onDestroy will be always called.

I thought startListening() means to attach listener not to reload the whole list.

What should I do to solve this?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions