Toolbar in AppBarLayout is scrollable although RecyclerView has not enough content to scroll

前端 未结 9 744
挽巷
挽巷 2020-12-12 15:34

Is it really intended that the Toolbar in a AppBarLayout is scrollable although the main container with the "appbar_scrolling_view_behavior" has not enough content

9条回答
  •  天命终不由人
    2020-12-12 16:25

    It is not a bug, all the events in a viewGroup are handled this way. Because your recyclerview is a child of coordinatorLayout so whenever the event is generated, it is first checked for parent and if parent is not interested only then it is passed down to child. See google documentation

提交回复
热议问题