2

我有滑动面板布局,它向右滑动。

我想按如下方式减小顶部布局的大小

在此处输入图像描述

<android.support.v4.widget.SlidingPaneLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/SlidingPanel"
android:layout_width="match_parent"
android:layout_height="match_parent" >

<LinearLayout
    android:layout_width="300dp"
    android:layout_height="match_parent"
    android:layout_gravity="left" >

    <ListView
        android:id="@+id/MenuList"
        android:layout_width="wrap_content"
        android:layout_height="match_parent" >
    </ListView>
</LinearLayout>

<LinearLayout
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:layout_gravity="right"
    android:orientation="vertical" >
<ListView
            android:id="@+id/listView1"
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:layout_alignParentBottom="true"
            android:layout_alignParentTop="true"
            android:divider="@null"
            android:dividerHeight="0dp" >
        </ListView>

</LinearLayout>
</android.support.v4.widget.SlidingPaneLayout>

给我一个想法,以减少每次菜单点击时顶部布局的大小

4

0 回答 0