1

我一直在开发一个必须实现聊天的 android 应用程序,为此我正在使用 Master-Detail 流进行实际聊天,就像任何聊天应用程序一样,我一直在使用 AndroidSlidingPaneLayout。

我遇到的问题是它看起来像谷歌环聊应用程序,右窗格略微暴露,我不想要,我希望左窗格覆盖整个屏幕宽度。我尝试了很多不同的东西,但到目前为止没有任何帮助。

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

<LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="@dimen/conversations_overview_width"
    android:layout_height="match_parent"
    android:background="@color/grey"
    android:orientation="vertical" >

    <ListView
        android:id="@+id/list"
        android:layout_width="fill_parent"
        android:layout_height="wrap_content"
        android:background="@color/white"
        android:divider="@color/black12"
        android:dividerHeight="1dp" />
</LinearLayout>

<LinearLayout
    android:id="@+id/selected"
    android:layout_width="fill_parent"
    android:layout_height="match_parent"
    android:layout_weight="1"
    android:orientation="vertical" >
</LinearLayout>

我不想在右图中将宿醉标记为红色,左窗格应跨越全宽

在此处输入图像描述

4

0 回答 0