当我门使用一个布局里面有recyclerView时,首次打开页面-加载数据-展示列表。这时当你的数据长度到达某个阶段后recyclerView会自动往下滑一段,知道某一个item完整展示在屏幕中。这个是因为recyclerview获取到了焦点。在recyclerview增加android:descendantFocusability="blocksDescendants"即可解决
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:descendantFocusability="blocksDescendants">
<android.support.v7.widget.RecyclerView
android:id="@+id/recycler_view"
android:layout_width="match_parent"
android:layout_height="wrap_content"/>
</RelativeLayout>