PageLayoutDemo icon indicating copy to clipboard operation
PageLayoutDemo copied to clipboard

recyclerview外边嵌套NestedScrollView的时候,只要替换recyclerview这部分,替换后布局高度不对

Open ghost opened this issue 7 years ago • 1 comments

<android.support.v4.widget.NestedScrollView xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent">

<LinearLayout
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:descendantFocusability="blocksDescendants"
    android:orientation="vertical">

    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:orientation="horizontal">

        <Button
            android:id="@+id/btn_load_success"
            android:layout_width="0dp"
            android:layout_height="wrap_content"
            android:layout_weight="1"
            android:text="加载正常" />

        <Button
            android:id="@+id/btn_load_empty"
            android:layout_width="0dp"
            android:layout_height="wrap_content"
            android:layout_weight="1"
            android:text="加载为空" />

        <Button
            android:id="@+id/btn_load_error"
            android:layout_width="0dp"
            android:layout_height="wrap_content"
            android:layout_weight="1"
            android:text="加载错误" />

    </LinearLayout>

    <android.support.v7.widget.RecyclerView
        android:id="@+id/recycler_view"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:nestedScrollingEnabled="false" />

</LinearLayout>

</android.support.v4.widget.NestedScrollView>

ghost avatar Dec 24 '18 06:12 ghost

你initPage()传入的是recycler_view么?

Hankkin avatar Jan 03 '19 15:01 Hankkin