I'm trying to use the MotionLayout View to get a collapsing toolbar behavior. My approach is similar to the example here: https://blog.stylingandroid.com/motionlayout-collapsing-toolbar-part-1/
This works fine, but the transition also starts on swipe, even if the recyclerview is empty or has fewer entries than would fit on the screen.
Is there any way to only enable the MotionLayout transition, if the recycler is actually able to scroll?
My OnSwipe description:
<OnSwipe
app:dragDirection="dragUp"
app:maxAcceleration="40"
app:moveWhenScrollAtTop="true"
app:touchAnchorId="@id/recycler"
app:touchAnchorSide="top" />