在drawerlayout中添加Scrollview

时间:2016-03-04 09:27:49

标签: android navigation-drawer drawerlayout

无法在导航抽屉xml中添加scrollview,请帮我在下面的XML中添加ScrollView

<android.support.v4.widget.DrawerLayout 
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    android:id="@+id/drawer_layout"
    android:layout_width="match_parent"
    android:layout_height="match_parent" >
    <LinearLayout
        android:id="@+id/frame_container"
        android:layout_width="wrap_content"
        android:layout_height="match_parent"
        android:background="@drawable/pattern_bg"
        android:focusable="false"
        android:focusableInTouchMode="false"
        android:orientation="vertical"
        android:weightSum="100" >
        <include
            android:id="@+id/top_header"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_gravity="top"
            layout="@layout/top_header" />
        <FrameLayout
            android:id="@+id/screen_container"
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:background="@drawable/pattern_bg"
            android:paddingBottom="25dp" >
        </FrameLayout>
    </LinearLayout>
    <LinearLayout
        android:id="@+id/userguide_container"
        android:layout_width="wrap_content"
        android:layout_height="match_parent"
        android:orientation="vertical"
        android:weightSum="100" >
        <android.support.v4.view.ViewPager
            android:id="@+id/userguidepager"
            android:layout_width="match_parent"
            android:layout_height="match_parent" />
    </LinearLayout>
    <FrameLayout
        android:id="@+id/frame_container1"
        android:layout_width="wrap_content"
        android:layout_height="match_parent" >
        <com.myself.mpty.Utils.CustomSlidingDrawer
            android:id="@+id/SlidingDrawer"
            android:layout_width="fill_parent"
            android:layout_height="wrap_content"
            android:layout_gravity="bottom"
            android:content="@+id/contentLayout"
            android:handle="@+id/footerLayout" >            
            <LinearLayout
                android:id="@+id/footerLayout"
                android:layout_width="fill_parent"
                android:layout_height="25dp"
                android:gravity="center_horizontal" >
                <Button
                    android:id="@+id/slideHandleButton"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:background="@drawable/ftr_up" >
                </Button>
            </LinearLayout>
            <LinearLayout
                android:id="@+id/contentLayout"
                android:layout_width="fill_parent"
                android:layout_height="500dp"
                android:background="@android:color/white"
                android:orientation="vertical"
                android:weightSum="100" >
                <FrameLayout
                    android:id="@+id/tabContentFragment"
                    android:layout_width="fill_parent"
                    android:layout_height="0dp"
                    android:layout_weight="80" >
                </FrameLayout>
                <include
                    android:id="@+id/apply_footer"
                    android:layout_width="fill_parent"
                    android:layout_height="0dp"
                    android:layout_weight="20"
                    layout="@layout/apply_footer"
                    android:visibility="gone" />
            </LinearLayout>          
        </com.myself.mpty.Utils.CustomSlidingDrawer>
    </FrameLayout>
<LinearLayout
    android:layout_width="240dp"
    android:layout_height="match_parent"
    android:orientation="vertical" >
    <ListView
        android:id="@+id/list_slidermenu"
        android:layout_width="240dp"
        android:layout_height="match_parent"
        android:background="#191919"
        android:cacheColorHint="@android:color/transparent"
        android:paddingLeft="8dp"
        android:paddingRight="8dp" />
    <FrameLayout
        android:id="@+id/sliderLayout"
        android:layout_width="fill_parent"
        android:layout_height="fill_parent" />
</LinearLayout>
       <ListView
        android:id="@+id/list_slidermenu"
        android:layout_width="240dp"
        android:layout_height="match_parent"
        android:layout_gravity="start"
        android:background="@color/list_background"
        android:choiceMode="singleChoice"
        android:dividerHeight="1dp" />
    <FrameLayout
        android:id="@+id/sliderLayout"
        android:layout_width="240dp"
        android:layout_height="match_parent" />
</android.support.v4.widget.DrawerLayout>

0 个答案:

没有答案