I have a fragment,in which I have a calendar, text view and a listview. All these views are inside the scroll view. I need two things in that layout.
- I want to disable the scrolling of the list view.
How scroll to invoke scroll view when I swipe up, I want to hide calendar and text view. And on swipe down. It shows the whole layout.
<RelativeLayout 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" xmlns:app="http://schemas.android.com/apk/res-auto" android:animateLayoutChanges="true" > <ScrollView android:layout_width="match_parent" android:layout_height="match_parent" android:fillViewport="true" android:layout_below="@+id/rel" android:id="@+id/scroll" > <LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="vertical"> <LinearLayout android:id="@+id/compactcalendar_view_container" android:layout_below="@+id/rel" android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="vertical"> <TextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="New Text" android:textColor="#e1dcdc" android:background="#011627" android:id="@+id/date_picker_text_view" android:textAlignment="center" /> <com.github.sundeepk.compactcalendarview.CompactCalendarView android:id="@+id/cvCalendar" xmlns:app="http://schemas.android.com/apk/res-auto" android:layout_width="match_parent" android:layout_height="250dp" app:compactCalendarTargetHeight="250dp" android:layout_below="@+id/textView14" app:compactCalendarBackgroundColor="#011627" app:compactCalendarCurrentDayBackgroundColor="#FFC107" app:compactCalendarCurrentSelectedDayBackgroundColor="#939393" app:compactCalendarTextColor="#e1dcdc" app:compactCalendarTextSize="12sp" /> </LinearLayout> <ListView android:id="@+id/lvList" android:layout_width="match_parent" android:layout_height="match_parent" android:divider="#e9e9e9" android:dividerHeight="10dp" android:clickable="false" android:focusable="false" android:focusableInTouchMode="false" android:scrollbars="none" android:background="#eee" android:layout_below="@+id/scroll" android:layout_centerHorizontal="true" /> </LinearLayout> </ScrollView> </RelativeLayout>