0
下の相対レイアウト(rlItemsList)をlistviewに追加したものとして展開したいのですが、リストビューのスクロール表示を希望しません。以下は私のXMLソースです。実行時の相対レイアウトを拡大して親ScrollViewを調整
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:fadeScrollbars="false"
android:fillViewport="true"
android:scrollbars="vertical">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<RelativeLayout
android:id="@+id/rlParent"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<RelativeLayout
android:id="@+id/rlParentChild"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_margin="5dp">
<LinearLayout
android:id="@+id/llToAndFromOperation"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="5dp"
android:orientation="vertical">
<RelativeLayout
android:id="@+id/rlFrom"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_margin="5dp">
<TextView
android:id="@+id/tvFrom"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerHorizontal="false"
android:layout_marginTop="5dp"
android:text="@string/from" />
<SearchableSpinner
android:id="@+id/spinnerFrom"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/tvFrom"
android:layout_centerHorizontal="false"
android:hint="@string/karachi"
android:textColor="@color/black" />
</RelativeLayout>
<RelativeLayout
android:id="@+id/rlTo"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_below="@+id/rlFrom"
android:layout_margin="5dp">
<TextView
android:id="@+id/tvTo"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerHorizontal="false"
android:layout_marginTop="5dp"
android:text="@string/to" />
<SearchableSpinner
android:id="@+id/spinnerTo"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/tvTo"
android:hint="@string/lahore"
android:textColor="@color/black"
/>
</RelativeLayout>
</LinearLayout>
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/llToAndFromOperation"
android:layout_marginTop="10dp">
<TextView
android:id="@+id/tvDescrption"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="5dp"
android:text="@string/description" />
<EditText
android:id="@+id/etDescription"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/tvDescrption"
android:hint="@string/writeText"
android:maxLines="3"
android:textColor="@android:color/black"
/>
<TextView
android:id="@+id/tvHomeDeleivery"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@+id/etDescription"
android:layout_marginLeft="5dp"
android:layout_marginTop="10dp"
android:text="@string/homeDeleivery"
android:textAllCaps="true"
/>
<RadioGroup
android:id="@+id/radioHomeDeleivery"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/tvHomeDeleivery"
android:layout_marginLeft="20dp"
android:orientation="horizontal">
<RadioButton
android:id="@+id/radioYes"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/yes"
/>
<RadioButton
android:id="@+id/radioNo"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:checked="true"
android:text="@string/no"
/>
</RadioGroup>
</RelativeLayout>
</RelativeLayout>
<!--</ScrollView>-->
<RelativeLayout
android:id="@+id/rlAddItems"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/rlParentChild"
android:layout_margin="3dp"
android:background="@color/lightgray"
android:padding="10dp"
>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/addItmes"
android:textColor="@color/black"
/>
</RelativeLayout>
<RelativeLayout
android:id="@+id/rlItemsList"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_below="@+id/rlAddItems"
android:layout_margin="5dp"
android:layout_marginBottom="10dp"
android:paddingBottom="10dp"
android:visibility="visible">
<ListView
android:id="@+id/lvItems"
android:layout_width="match_parent"
android:layout_height="wrap_content">
</ListView>
</RelativeLayout>
</RelativeLayout>
<!--</ScrollView>-->
</LinearLayout>
現在の問題は、リストビューに追加された項目、相対的なレイアウトは同じ幅と高さを持っているように、私の単一の項目がリストビューに示されていると私は底部内の他の項目を表示するためにスクロールしなければならないということですので、リストビューで追加されたアイテムと親スクロールビューでは画面全体を調整する必要があるため、相対レイアウトを拡張したいと考えていました。事前のおかげでどんな助けでも感謝します。