开发者

android I’m trying to have an embedded web site with a button

I’m trying to have an embedded web site with a button. When I add the button, the web view disappears. I tried to put the button on the top in a separate container, but nothing worked. Please Help.

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="fill_parent"
    android:layout开发者_运维问答_height="fill_parent">
    <WebView
        android:id="@+id/webcast"
        android:layout_width="fill_parent"
        android:layout_height="fill_parent"
        android:layout_weight="1.0"
    />
    <ImageButton 
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:src="@drawable/video"
        android:layout_gravity="top"
    />
</LinearLayout>


Just use FrameLayout in place of LinearLayout. Through this you will have button over webview.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜