我想在我的布局中显示两个具有相同数量项目的ListView(并行垂直),但问题是它们的高度不同步。 所以我想使他们的高度等于...具有相同行高的两个垂直Listviews
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/parent_lf"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:background="@color/aya_1"
android:baselineAligned="false"
android:orientation="horizontal" >
<ListView
android:id="@+id/index"
android:layout_width="0dp"
android:layout_height="fill_parent"
android:layout_weight="0.15"
android:choiceMode="singleChoice"
android:divider="@android:color/transparent"
android:dividerHeight="0sp"
android:fastScrollEnabled="true" />
<ListView
android:id="@+id/content"
android:layout_width="0dp"
android:layout_height="fill_parent"
android:layout_weight="0.85"
android:choiceMode="singleChoice"
android:divider="@android:color/darker_gray"
android:dividerHeight="0.2sp"
android:fastScrollEnabled="true" />
有任何想法请!
感谢所有
穆罕默德
您的分频器的高度不等于让你列表视图不SYNCD一样。 – Dhina 2014-11-04 12:30:42
您在列表视图中添加的单个项目是否具有相同的高度? – Rohit5k2 2014-11-04 12:35:22
我加了分隔线,但是得到了同样的结果... – Mohamed 2014-11-04 12:37:46