Android WebView涵盖的滑动抽屉内容

Android WebView涵盖的滑动抽屉内容,android,xamarin.android,android-webview,slidingdrawer,Android,Xamarin.android,Android Webview,Slidingdrawer,我有一个WebView和一个滑动抽屉,当openend在WebView上打开时,至少是这样。滑动抽屉手柄和内容显示在WebView的上方和下方,但不在WebView的顶部,这意味着WebView的内容是可见的,而不是滑动抽屉的内容 <RelativeLayout xmlns:d1p1="http://schemas.android.com/apk/res/android" d1p1:minWidth="25px" d1p1:minHeight="25px" d1p1

我有一个WebView和一个滑动抽屉,当openend在WebView上打开时,至少是这样。滑动抽屉手柄和内容显示在WebView的上方和下方,但不在WebView的顶部,这意味着WebView的内容是可见的,而不是滑动抽屉的内容

<RelativeLayout xmlns:d1p1="http://schemas.android.com/apk/res/android"
    d1p1:minWidth="25px"
    d1p1:minHeight="25px"
    d1p1:layout_width="fill_parent"
    d1p1:layout_height="fill_parent"
    d1p1:id="@+id/relativeLayout2"
    d1p1:paddingTop="10dp"
    d1p1:paddingRight="10dp"
    d1p1:paddingLeft="10dp">
    <RelativeLayout
        d1p1:minWidth="25px"
        d1p1:minHeight="25px"
        d1p1:id="@+id/relativeLayout1"
        d1p1:layout_width="wrap_content"
        d1p1:layout_height="wrap_content"
        d1p1:layout_alignParentTop="true">
        <LinearLayout
            d1p1:orientation="vertical"
            d1p1:minWidth="25px"
            d1p1:minHeight="25px"
            d1p1:layout_width="wrap_content"
            d1p1:layout_height="wrap_content"
            d1p1:id="@+id/linearLayout1"
            d1p1:layout_alignParentRight="true">
            <TextView
                d1p1:text="Time Remaining"
                d1p1:textAppearance="?android:attr/textAppearanceSmall"
                d1p1:id="@+id/studentQuestionZoneQuestionContent_textView_timeRemainingLabel"
                d1p1:typeface="normal"
                d1p1:textSize="22sp"
                d1p1:textColor="#ff000000"
                d1p1:layout_width="fill_parent"
                d1p1:layout_height="wrap_content" />
            <LinearLayout
                d1p1:orientation="horizontal"
                d1p1:minWidth="25px"
                d1p1:minHeight="25px"
                d1p1:layout_width="fill_parent"
                d1p1:layout_height="wrap_content"
                d1p1:id="@+id/linearLayout2"
                d1p1:gravity="center_horizontal">
                <TextView
                    d1p1:text="XXX"
                    d1p1:textAppearance="?android:attr/textAppearanceSmall"
                    d1p1:id="@+id/studentQuestionZoneQuestionContent_textView_timeValue"
                    d1p1:typeface="normal"
                    d1p1:textSize="25sp"
                    d1p1:textColor="#ff000000"
                    d1p1:layout_width="wrap_content"
                    d1p1:layout_height="fill_parent"
                    d1p1:gravity="bottom" />
                <TextView
                    d1p1:text="Seconds"
                    d1p1:textAppearance="?android:attr/textAppearanceSmall"
                    d1p1:id="@+id/studentQuestionZoneQuestionContent_textView_timeValueUnits"
                    d1p1:layout_width="wrap_content"
                    d1p1:layout_height="fill_parent"
                    d1p1:typeface="normal"
                    d1p1:textSize="19sp"
                    d1p1:textColor="#ff000000"
                    d1p1:gravity="bottom"
                    d1p1:paddingLeft="10dp" />
            </LinearLayout>
        </LinearLayout>
        <TextView
            d1p1:text="Question Description"
            d1p1:textAppearance="?android:attr/textAppearanceLarge"
            d1p1:layout_width="wrap_content"
            d1p1:layout_height="wrap_content"
            d1p1:id="@+id/studentQuestionZoneQuestionContent_textView_questionDescription"
            d1p1:layout_centerInParent="true"
            d1p1:typeface="normal"
            d1p1:textSize="25sp"
            d1p1:textColor="#ff000000" />
    </RelativeLayout>
    <SlidingDrawer
        d1p1:content="@+id/content"
        d1p1:handle="@+id/handle"
        d1p1:minWidth="25px"
        d1p1:minHeight="25px"
        d1p1:layout_width="fill_parent"
        d1p1:layout_height="fill_parent"
        d1p1:id="@+id/slidingDrawer1"
        d1p1:layout_alignParentBottom="true"
        d1p1:layout_centerHorizontal="true"
        d1p1:background="#00000000">
        <Button
            d1p1:id="@+id/handle"
            d1p1:layout_width="wrap_content"
            d1p1:layout_height="wrap_content"
            d1p1:text="Scratchpad"
            d1p1:background="@drawable/button_question_zone_scratch_pad_without_annotation" />
        <LinearLayout
            d1p1:id="@+id/content"
            d1p1:layout_width="match_parent"
            d1p1:layout_height="match_parent"
            d1p1:minWidth="25px"
            d1p1:minHeight="25px">
            <SurfaceView
                d1p1:layout_width="fill_parent"
                d1p1:layout_height="fill_parent"
                d1p1:id="@+id/surfaceView1"
                d1p1:background="#ffffffff" />
        </LinearLayout>
    </SlidingDrawer>
    <Button
        d1p1:text="Scratchpad"
        d1p1:id="@+id/studentQuestionZoneQuestionContent_button_scratchpad"
        d1p1:background="@drawable/button_question_zone_scratch_pad_without_annotation"
        d1p1:typeface="normal"
        d1p1:textSize="22sp"
        d1p1:textStyle="bold"
        d1p1:textColor="#ff666666"
        d1p1:layout_width="wrap_content"
        d1p1:layout_height="wrap_content"
        d1p1:layout_alignParentBottom="true"
        d1p1:layout_centerHorizontal="true"
        d1p1:paddingLeft="50dp"
        d1p1:paddingRight="10dp"
        d1p1:visibility="invisible" />
    <WebView
        d1p1:id="@+id/studentQuestionZoneQuestionContent_webView_content"
        d1p1:layout_below="@id/relativeLayout1"
        d1p1:layout_above="@id/studentQuestionZoneQuestionContent_button_scratchpad"
        d1p1:layout_width="fill_parent"
        d1p1:layout_height="fill_parent" />
    <ProgressBar
        style="@android:style/Widget.Holo.ProgressBar.Large"
        d1p1:layout_width="wrap_content"
        d1p1:layout_height="wrap_content"
        d1p1:id="@+id/studentQuestionZoneQuestionContent_progress_loadingContent"
        d1p1:layout_below="@id/relativeLayout1"
        d1p1:layout_above="@id/studentQuestionZoneQuestionContent_button_scratchpad"
        d1p1:layout_centerHorizontal="true" />
</RelativeLayout>

重新排列布局文件,使
滑动抽屉
代码显示在
网络视图
代码下方。小部件的z索引由其在文件中的位置决定。文件下方的小部件具有更高的z索引

您还可以使用
View.bringToFront()