I have a custom listView the xml code of each row is:
<TextView
android:layout_width="match_parent"
android:layout_height="150dp"
android:text="New Text"
android:textColor="#000000"
android:id="@+id/headerTextView"
android:textAlignment="center"
android:textSize="30sp"
android:textStyle="bold"
/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:id="@+id/dynamicLL">
<TextView
android:layout_width="match_parent"
android:id="@+id/fadeText"
android:layout_height="200dp"
android:textAlignment="center"
android:textSize="18sp"
android:gravity="center"
android:text="No Event registered!!"/>
</LinearLayout>
in my LinearLayout("@+id/dynamicLL") after textView dynamically addview in getView of myAdapter I have no problem with this listView but I have a toolbar that can hide and show even by click on button or drag with finger in my another pages this toolbar smoothly close and open but on this listview (specially when I have a lot dynamically added row in my LinearLayout) toolbar show and hide with stuck . I want to know what can I do for this problem.I want that toolbar show and hide without any stuck .toolbar hide and show in another fragment without any stuck but beside this listview it stuck
I finally found the answer , the point is when we have listview beside another view and we want another view collapse or expand smoothly we should give listview define height forexample android:layout_height="800dp"
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical" android:layout_width="match_parent"
android:layout_height="match_parent"
>
<ListView
android:layout_width="match_parent"
android:layout_height="800dp"
android:id="@+id/lv"
/>
</LinearLayout>