This is my code
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="match_parent" >
<ImageView
android:id="@+id/bgImage"
android:layout_width="fill_parent"
android:layout_height="match_parent"
android:layout_alignParentTop="true"
android:contentDescription="@string/todo"
android:scaleType="fitXY"
android:src="@drawable/default_wallpaper" />
<LinearLayout
android:id="@+id/mainLayout"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_below="@+id/title"
android:orientation="vertical" >
<ListView
android:id="@+id/in"
android:layout_width="fill_parent"
android:layout_height="0dp"
android:layout_weight="1"
android:background="@android:color/transparent"
android:cacheColorHint="@android:color/transparent"
android:divider="@android:color/transparent"
android:stackFromBottom="true"
android:transcriptMode="alwaysScroll" />
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="50dp"
android:orientation="horizontal" >
<EditText
android:id="@+id/edit_text_out"
android:layout_width="0dp"
android:layout_height="fill_parent"
android:layout_gravity="bottom"
android:layout_weight="1"
android:inputType="none" />
<Button
android:id="@+id/button_send"
android:layout_width="70dp"
android:layout_height="fill_parent"
android:text="@string/send"
android:textSize="15sp"
android:textStyle="bold" />
</LinearLayout>
</LinearLayout>
</RelativeLayout>
In this when I tap on EditText
soft keyboard opens but my ImageView
is shrinking.
I used android:windowSoftInputMode="adjustPan"
in manifest file but by using this it will push up whole activity upper side but I want ImageView as it is and when keyboard is open ImageView is cut from bottom not from top as in WhatsApp
application.
Any help will appreciate. Thank you ..