解决办法是在整个页面配置文件中,在LinearLayout布局外加入
< ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical" android:layout_width="fill_parent"
android:layout_height="fill_parent" android:background="@drawable/backgroundshape">
这样在系统自动调用虚拟键盘时,整个页面布局会发生变化,分为两个部分,一个是虚拟键盘显示的部分,一个是你自己的页面。
本文介绍了一种解决虚拟键盘遮挡输入框的方法,通过在布局文件中使用 ScrollView,实现键盘弹出时页面内容自动上移,确保输入区域始终可见。
4130

被折叠的 条评论
为什么被折叠?



