cachapa / ExpandableLayout

An expandable layout container for Android
Apache License 2.0
2.34k stars 273 forks source link

Scrolling to item position is not working #97

Open EliYakubov77 opened 1 year ago

EliYakubov77 commented 1 year ago

I try to use scrollTo function. expandableLayout.scrollTo(0, myViewItem.top). I get the item with the position I wanted, but all the items that appeared before are gone.

` <net.cachapa.expandablelayout.ExpandableLayout android:id="@+id/levelsEL" android:layout_width="0dp" android:layout_height="wrap_content" app:layout_constraintStart_toStartOf="parent" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintTop_toBottomOf="@id/buildingOrProcessesTV" style="@style/CardItemExpandableLayout" >

    <androidx.recyclerview.widget.RecyclerView
        android:id="@+id/levelsRV"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_marginTop="5dp" />

</net.cachapa.expandablelayout.ExpandableLayout>

`