recyclerview

时间:2015-04-22 14:42:50

标签: android

我正在创建一个包含不同类型视图的列表。 就像facebook在移动应用程序中显示其提要一样。 示例有时滚动视图或某些时候列在列表中。

要做到这一点,这将是一个不错的选择。 如果我在recyclerview的每个项目中添加一个片段,该怎么办?像

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
>

<fragment
    android:layout_width="match_parent"
    android:name="com.profile.EditProfileFragment"
    android:layout_height="wrap_content"/>

并将其添加为Reclycleview中的项目,并在其中保留不同的逻辑。

任何人都可以建议我如何解决这个问题。

0 个答案:

没有答案