我有一个 ExpandableListView
和一个 Button
。当我打开列表中的某些项目时,我无法访问该按钮,因为列表已展开。
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_height="wrap_content"
android:layout_width="match_parent"
>
<ExpandableListView
android:layout_height="wrap_content"
android:layout_width="match_parent"
android:id="@+id/expEnt"
/>
<Button
android:layout_height="wrap_content"
android:layout_width="100dp"
android:text="Plot"
android:layout_below="@id/expEnt"
android:layout_alignParentRight="true"/>
</RelativeLayout>
有什么办法可以解决吗?
最佳答案
试试这个。这可能会对您有所帮助:
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_height="wrap_content"
android:layout_width="match_parent"
>
<ExpandableListView
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:id="@+id/expEnt"
/>
<Button
android:layout_height="wrap_content"
android:layout_width="100dp"
android:text="Plot"
android:layout_alignParentBottom="true"
android:layout_alignParentRight="true"/>
</RelativeLayout>
关于android - ExpandableListView 和滚动,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19244536/