Update: I have solved this problem just by listen to the scroll change event of the NestedScrollView and do the appropriate handling there.
I'm following this tutorial to animate showing and hiding of my FloatingActionButton
. But it doesn't really work for my layout. My layout is like this picture:
It has a NestedScrollView and a number of RecyclerView inside. When I scroll by touching the area of NestedScrollView, the FloatingActionButton
is animated as expected. But when I scroll by touching the area of one of the RecyclerViews
, the FloatingActionButton
don't animate at all. When I try debug my code, I realize that the onNestedScroll
method doesn't gets called when I scroll by touching on the area of RecyclerView
.