안녕하세요
현재 Google Material에서 제공하는 BottomSheetBehavior을 이용하여 한 화면을 구현하는 중 RecyclerView Scroll에 문제가 생겨서 질문 드립니다.
제가 원하는 기능은, BottomSheetBehavior안에 recyclerview scroll이 BottomSheet Dragging과 따로 동작해야하는 사양입니다. 현재 동작은 BottomSheetBehavior의 State가 Expanded, 즉 완전히 펼쳐진 상태에서만 Recyclerview 스크롤이 동작합니다. 저는 해당 상태가 STATE_HALF_EXPANDED에서도 recyclerview 스크롤이 동작해야하는 상황인데 도통 서칭을 해도 잘 나오지 않아서 답답한 마음에 질문 드립니다.
현재 개발중인 xml은 밑과 비슷한 형식으로 구성되어있습니다.
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context="view.activity.MyActivity">
<!--my activity views-->
<include layout="@layout/bottom_sheet_view" />
</androidx.coordinatorlayout.widget.CoordinatorLayout>
bottom_sheet_view.xml
<Constraint xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/bottom_sheet_searches"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fitsSystemWindows="true"
android:orientation="vertical"
app:behavior_hideable="false"
app:behavior_peekHeight="56dp"
app:layout_behavior="com.google.android.material.bottomsheet.BottomSheetBehavior">
<Constarint
android:layout_width="match_parent"
android:layout_height="56dp">
<!--view-->
</Constraint>
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/my_list"
android:layout_width="match_parent"
android:layout_height="0dp"
/>
</Constarint>
위와 같이 ConstraintLayout 안에 View에서는 BottomSheet Drag가 동작해도 상관없으며, RecyclerView를 클릭할때는 BottomSheet Drag 동작이 아닌 Recyclerview scroll 이 동작되는 기능이 필요합니다....