いくつかのビューを含むレイアウトがあり、そのうちの1つはEditTextです。レイアウトは1ページに簡単に収まりますが、ソフトキーボードがない場合、レイアウトはスクロールしません。これが私のレイアウトの要約です:
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/background" >
<ScrollView
android:id="@+id/ScrollView1"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignParentTop="true" >
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical" >
<CheckBox/>
<TextView/>
<LinearLayout>
<EditText>
<requestFocus />
</EditText>
</LinearLayout>
<TextView/>
<LinearLayout>
<Spinner/>
</LinearLayout>
</LinearLayout>
</ScrollView>
<Button
android:layout_alignParentBottom="true" />
</RelativeLayout>
そして私のマニフェストで私は属性を宣言しました:
android:windowSoftInputMode="adjustResize|stateHidden"
なぜそれが機能しないのか、そしてそれが機能することを確認する方法を誰かが知っていますか?
前もって感謝します!