設置我的Android Studio中的ListView這樣的:的ListView上的程序擴展開始
<ListView
android:layout_width="match_parent"
android:layout_height="200dp"
android:layout_alignParentBottom="true"
android:layout_alignParentLeft="true"
android:id="@+id/listView" />
,並貼在屏幕的底部。但是,如果我運行該應用程序,ListView將擴展並填充整個屏幕。
完全地把你的佈局XML –
後整個活動佈局 – MikeKeepsOnShine
檢查此鏈接中的第二個答案http://stackoverflow.com/questions/11295080/android-wrap-content-is-not-working-with- listview –