cymcsg / UltimateRecyclerView

A RecyclerView(advanced and flexible version of ListView in Android) with refreshing,loading more,animation and many other features.
Apache License 2.0
7.22k stars 1.43k forks source link

OnLoadMoreListener gets called several times #27

Closed pkliang closed 8 years ago

pkliang commented 9 years ago

Hi, according to my test, the OnLoadMoreListener gets called several times when you scroll up and down the recyclerView several times.

cymcsg commented 9 years ago

If you scroll up and down to the last item again and again the recyclerview will call OnLoadMoreListener for many times. In fact I think it should be adjusted by the custom method, but maybe I'll add a method to judge it.

pkliang commented 9 years ago

FYI: https://gist.github.com/ssinss/e06f12ef66c51252563e, a clean solution

mahdihijazi commented 9 years ago

@pkliang @cymcsg please check updated solution https://github.com/cymcsg/UltimateRecyclerView/pull/31

cymcsg commented 9 years ago

@mahdihijazi Thank you very much for the useful solution. @pkliang Please check if the method runs well.The method is on the latest dev branch.

jjhesk commented 8 years ago

276 this should be done for the load more issue. @mahdihijazi @pkliang