私はスピナーコントロールを複製しようとしています(理由を聞かないでください)私は仕切りで苦労しています。偽のスピナーは、イメージビューの左側に仕切りを追加するまでうまく見えます。ディバイダを追加すると、画面の残りの部分が高さになります。誰かがこれを説明できますか?私は、分周器を追加すると、アンドロイド:子ビューのfill_parentが画面を塗りつぶす
:
次のxml:
.......
<Spinner
android:id="@+id/equipment_spinner"
android:layout_width="fill_parent"
android:layout_height="wrap_content"/>
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<Button
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"/>
<ImageView
android:id="@+id/spinner_arrow"
android:layout_width="45sp"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:layout_centerVertical="true"
android:src="@drawable/spinner_arrow"/>
</RelativeLayout>
</LinearLayout>
</ScrollView>
は、次の画面を生成しxmlは次のようになります。
次の画面生成 <Spinner
android:id="@+id/equipment_spinner"
android:layout_width="fill_parent"
android:layout_height="wrap_content"/>
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<Button
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"/>
<ImageView
android:id="@+id/spinner_arrow"
android:layout_width="45sp"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:layout_centerVertical="true"
android:src="@drawable/spinner_arrow"/>
<View
android:background="#e7ebe7"
android:layout_width="1dip"
android:layout_height="fill_parent"
android:layout_toLeftOf="@id/spinner_arrow"/>
</RelativeLayout>
</LinearLayout>
</ScrollView>
:
を誰も私が間違ってここにやって見つけることができます...
私はあなたの質問に投票しました。誰かが同じことをした場合、画像を投稿するのに十分な担当者がいるでしょう。 – Squonk
投票してください、画像を投稿してください – Rob