2

I need to know when user initiated scroll has finished, but have no clue, how to access this info. ViewTreeObserver.OnScrollChangedListener() has only one abstract method onScrollChanged, but has no public void onScrollStateChanged(RecyclerView recyclerView, int newState) sort of abstract method with state argument.

horizontalScrollView.getViewTreeObserver().addOnScrollChangedListener(new ViewTreeObserver.OnScrollChangedListener() {

        @Override
        public void onScrollChanged() {

        }
    });
János
  • 32,867
  • 38
  • 193
  • 353
  • This class is written for you I must say. :) http://stackoverflow.com/a/38684097/6547129 – Myo Ko Jul 31 '16 at 13:05
  • 1
    I think there is no way you can do it with `ViewTreeObserver`. See this question for solutions: http://stackoverflow.com/questions/8181828/android-detect-when-scrollview-stops-scrolling – Alexander Mironov Jul 31 '16 at 20:14

0 Answers0