Клавиатура Android Soft плавает только определенной раскладки
У меня есть макет, код ниже
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
xmlns:app="http://schemas.android.com/apk/res-auto">
<!--some stuff here-->
<LinearLayout
android:id="@+id/layout1"
android:layout_alignParentBottom="true"
android:layout_above="@+id/layout2"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<EditText
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="5"
/>
<ImageButton
android:layout_width="50dp"
android:layout_height="50dp"
android:scaleType="fitStart"
android:layout_marginLeft="5dp"
style="@style/Base.Widget.AppCompat.Button.Borderless"
android:src="@drawable/ic_menu_send"/>
</LinearLayout>
<LinearLayout
android:id="@+id/layout2"
android:layout_alignParentBottom="true"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<!--some stuff here-->
</LinearLayout>
</RelativeLayout>
В приведенном выше коде, когда клавиатура показывает, я хочуlayout2
остаться вbottom
а такжеlayout1
вgo up with keyboard
, если я добавлюandroid:windowSoftInputMode="adjustPan|adjustResize"
оба макета остаются в нижней части. пожалуйста помоги