Replace include of fragment_recycler_view with RecyclerView child due to different padding requirements

This commit is contained in:
Phillip Hsu 2016-08-30 02:54:32 -07:00
parent 43805076eb
commit 02fc6f2bdd
2 changed files with 18 additions and 9 deletions

View File

@ -26,11 +26,15 @@
android:textSize="@dimen/text_size_display_3"
style="@style/TextAppearance.AppCompat.Inverse"/>
<include layout="@layout/fragment_recycler_view"
android:layout_width="0dp"
android:layout_weight="1"
android:layout_height="match_parent"
android:layout_marginTop="8dp"/>
<!-- Unfortunately, we can't reuse fragment_recycler_view
- due to different padding requirements here. -->
<android.support.v7.widget.RecyclerView
android:id="@+id/list"
android:layout_width="0dp"
android:layout_weight="1"
android:layout_height="match_parent"
android:scrollbars="vertical"
android:paddingTop="8dp"/>
</LinearLayout>

View File

@ -18,11 +18,16 @@
android:background="@color/colorPrimary"
android:gravity="center_horizontal"
android:textSize="@dimen/text_size_display_3"
style="@style/TextAppearance.AppCompat.Inverse"
android:layout_marginBottom="8dp"/>
style="@style/TextAppearance.AppCompat.Inverse"/>
<!-- RecyclerView -->
<include layout="@layout/fragment_recycler_view"/>
<!-- Unfortunately, we can't reuse fragment_recycler_view
- due to different padding requirements here. -->
<android.support.v7.widget.RecyclerView
android:id="@+id/list"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scrollbars="vertical"
android:paddingTop="8dp"/>
</LinearLayout>