Reputation: 11
I have a ListView with an edittext and a button at the bottom of my screen. When the soft keyboard appears it squeezes my image. I tried a few stuff:
1)android:windowSoftInputMode="adjustPan" The image doesn't get squashed, nice. But the ListView items cannot be scrolled anymore.
2)android:windowSoftInputMode="adjustResize" Does nothing.
Any ideas anyone?
Upvotes: 1
Views: 4137
Reputation: 936
Use android:windowSoftInputMode="adjustResize"
and simply wrap your background to a ImageView in a ScrollView.
<ScrollView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:scrollbars="none"
android:overScrollMode="never">
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"/>
</ScrollView>
Upvotes: 1
Reputation: 31
Use getWindow().setBackgroundDrawable() in your activity to set the background.
Upvotes: 3