2
我的幻燈片菜單很完美,但是當我想在幻燈片菜單中滾動時,我不能。我有足夠的項目在列表視圖中滾動。如何在DrawerLayout中滾動? 滾動條顯示,但我不能做任何事情。我應該以編程方式添加它嗎?在DrawerLayout中滾動
<android.support.v4.widget.DrawerLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/drawer_layout"
android:layout_width="match_parent"
android:layout_height="match_parent">
<ScrollView
android:layout_width="wrap_content"
android:layout_height="wrap_content">
<!-- Framelayout to display Fragments -->
<FrameLayout
android:id="@+id/frame_container"
android:layout_width="match_parent"
android:layout_height="match_parent" />
</ScrollView>
<!-- Listview to display slider menu -->
<ListView
android:id="@+id/list_slidermenu"
android:layout_width="240dp"
android:layout_height="match_parent"
android:layout_gravity="start"
android:choiceMode="singleChoice"
android:divider="@color/list_divider"
android:dividerHeight="1dp"
android:listSelector="@drawable/list_selector"
android:background="@color/list_background"
/>
<RelativeLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content">
<Button
android:id="@+id/btn_pick"
android:layout_width="90dp"
android:layout_height="55dp"
android:layout_alignParentBottom="true"
android:text="pick" />
<Button
android:id="@+id/sticker"
android:layout_width="90dp"
android:layout_height="55dp"
android:text="add sticker"
android:layout_below="@+id/paint_view"
android:layout_alignParentRight="true"
android:layout_alignParentEnd="true" />
<Button
android:id="@+id/save"
android:layout_width="90dp"
android:layout_height="55dp"
android:text="save"
android:layout_alignParentBottom="true"
android:layout_centerHorizontal="true" />
<in.wptrafficanalyzer.graphicspickimageviewcanvas.PaintView
android:id="@+id/paint_view"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_above="@id/btn_pick" />
</RelativeLayout>
</android.support.v4.widget.DrawerLayout>
先刪除滾動視圖,第二你[R回事歧途找到例如抽屜佈局首先理解然後嘗試自己 – 2015-04-03 11:50:22
這裏滾動視圖的目的是什麼? – 2015-04-03 11:54:51
滾動視圖內的列表視圖? – Harry 2015-04-03 12:10:09