I'm creating a simple listview with an endless scroll effect. While I'm downloading new data I want to display an indeterminate progressbar at the bottom of the listview (like gmail app).
There is 2 solutions
- Add the progressbar as a an item of my listview, but I don't like this solution
- Add the progressbar at the bottom of my listview and show/hide it
It would give something like that
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<ListView
android:id="@+id/List_list"
android:layout_width="fill_parent"
android:layout_height="wrap_content" />
<ProgressBar
android:id="@+id/trobber"
android:layout_below="@+id/List_list"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:indeterminate="true" >
</ProgressBar>
</RelativeLayout>
But the progressbar is not displayed when my list is longuer than the size of my screen (in other words when I have to scoll).