안녕하세요.
혼자 보다가 도저히 이해가 안가서 여쭙니다.
먼저 만들려고 하는것은 검색창에 검색어를 입력하면 리스트뷰에 데이터를 뿌리고
리스트뷰 맨 하단에 로딩중이라는 메세지를 미리 만들어놓고 그 메세지가 화면에 보일 때
추가 리스트를 불러오는걸 만들어보려 합니다.
한마디로 구글마켓의 인터페이스입니다.
먼저 메인 레이아웃은
-------------
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent" android:layout_height="fill_parent"
android:orientation="vertical">
<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent" android:layout_height="fill_parent"
android:stretchColumns="0">
<TableRow>
<EditText android:layout_width="wrap_content"
android:layout_height="wrap_content" android:id="@+id/keyword"
android:lines="1"></EditText>
<Button android:layout_width="wrap_content"
android:layout_height="wrap_content" android:id="@+id/GoSearch"
android:text="검색"></Button>
</TableRow>
<TableRow>
<ListView xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/list" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:orientation="vertical" />
</TableRow>
<TableRow>
<ProgressBar android:id="@+id/moreResult"
android:layout_width="wrap_content" android:layout_height="wrap_content"
android:visibility="visible" />
<TextView android:text="로딩중" android:layout_width="wrap_content" android:layout_height="wrap_content"/>
</TableRow>
</TableLayout>
</LinearLayout>
-------------------
이렇구요. 저 부분 중 @+id/list 가 동적 리스트입니다.
동적 리스트의 레이아웃은
-------------------
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent" android:layout_height="40px">
<ImageView android:layout_width="wrap_content"
android:layout_height="wrap_content" android:id="@+id/img"
android:layout_alignParentLeft="true"
android:src="@drawable/noimage"
android:minWidth="60px"
/>
<TextView android:layout_width="wrap_content"
android:layout_height="wrap_content" android:id="@+id/text"
android:textColor="#00ff00" android:textSize="13pt"
android:layout_toRightOf="@id/img" />
<Button android:layout_width="wrap_content"
android:layout_height="wrap_content" android:id="@+id/btn"
android:layout_alignParentRight="true" android:text="상세" />
</RelativeLayout>
-----------------------
위와 같구요..
문제는 저걸 실행해서 목록의 끝에 도달해보면 프로그래스바가 보여야 하는데 안보인다는 겁니다.
제가 뭘 잘못알아도 한참 잘못알고 있는것 같네요. 한참 이리저리 해봐도 당최 알수 없습니다. ㅠㅠ
부디 답변 부탁드립니다.