https://github.com/tjerkw/Android-SlideExpandableListView
したがって、上記のライブラリを使用して、次の場所に別のテキストビューを追加しました。
<?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="wrap_content"
android:orientation="vertical">
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<TextView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:id="@+id/textA"
android:text="Hello World"/>
<TextView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:id="@+id/textB"
android:text="Hello World"/>
<!-- this is the button that will trigger sliding of the expandable view -->
<Button
android:id="@+id/expandable_toggle_button"
android:text="More"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignBottom="@+id/text"
android:layout_alignParentRight="true"
android:layout_alignTop="@id/text"/>
</RelativeLayout>
<!-- this is the expandable view that is initially hidden and will slide out when the more button is pressed -->
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="horizontal"
android:id="@+id/expandable"
android:background="#000000">
<!-- put whatever you want in the expandable view -->
<Button
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="0.5"
android:text="Action A" />
<Button
android:id="@+id/details"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="0.5"
android:text="Action B"/>
</LinearLayout>
</LinearLayout>
リストアダプターの設定では、R.id.TextA を 1 つだけ指定できます。2 つの textViews の 2 つの項目リストをどのように指定できますか。