我用webview,但是现在有个问题是我里面的文字输入框,点击打开键盘时候,会跑到屏幕上面去现在想把整个webview上推,但是我在webview外面套一层scrollview后,,进页面是黑屏幕的,请问如何解决?
<?xml version="1.0" encoding="utf-8"?>
<ScrollView android:layout_width="fill_parent"
android:layout_height="fill_parent" android:scrollbars="vertical">
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical" android:layout_width="fill_parent"
android:layout_height="fill_parent"> <WebView android:id="@+id/webview" android:layout_width="fill_parent"
android:layout_height="wrap_content" android:layout_weight="1" /> </LinearLayout>
</ScrollView> 以及<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical" android:layout_width="fill_parent"
android:layout_height="fill_parent">
<ScrollView android:layout_width="fill_parent"
android:layout_height="fill_parent" android:scrollbars="vertical">
<WebView android:id="@+id/webview" android:layout_width="fill_parent"
android:layout_height="wrap_content" android:layout_weight="1" />
</ScrollView>
</LinearLayout>
还有去掉linearlayout,都不行呢。。请问有谁知道么?
<?xml version="1.0" encoding="utf-8"?>
<ScrollView android:layout_width="fill_parent"
android:layout_height="fill_parent" android:scrollbars="vertical">
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical" android:layout_width="fill_parent"
android:layout_height="fill_parent"> <WebView android:id="@+id/webview" android:layout_width="fill_parent"
android:layout_height="wrap_content" android:layout_weight="1" /> </LinearLayout>
</ScrollView> 以及<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical" android:layout_width="fill_parent"
android:layout_height="fill_parent">
<ScrollView android:layout_width="fill_parent"
android:layout_height="fill_parent" android:scrollbars="vertical">
<WebView android:id="@+id/webview" android:layout_width="fill_parent"
android:layout_height="wrap_content" android:layout_weight="1" />
</ScrollView>
</LinearLayout>
还有去掉linearlayout,都不行呢。。请问有谁知道么?
解决方案 »
- 求大牛指教,Android调用照相机拍照然后截图的时候,总出现无法剪切图片,帮忙看下代码有什么问题,谢谢了!!!
- 求救!如何将百度地图上面的静态marker,设置为动画图片,一闪一闪的?
- 在Android上开发音频软件的一些想法,求助。
- 安卓2.1怎么在线看视频啊,不要客户端的那种
- 游戏中人物的运动轨迹,高分搜集。。。
- android ImageView问题
- 帮忙介绍一下学android的书吧
- Android 从服务器下载文件excel、pdf下载不了,求帮忙解决
- 想做一个CSDN博客阅读的APP,不过不知道如何下手
- 【求助】夜神模拟器打不开蓝牙
- 用android的模拟器下载的东西存在哪里
- surface里面的Orientation这个词怎么翻译阿?
<?xml version="1.0" encoding="utf-8"?>
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical" android:layout_width="fill_parent"
android:layout_height="fill_parent">
<WebView android:id="@+id/webview" android:layout_width="fill_parent"
android:layout_height="wrap_content" android:layout_weight="1" />
</ScrollView >
个人博客:www.girlcoding.com