J'utilise mise en page du coordinateur, vue recycleur et bouton flottant. D'une certaine manière, le bouton fab ne reste pas au bas de la mise en page. Je voudrais que le bouton reste en bas même en faisant défiler. Ce que je sais, c'est que le bouton Fab prend la dernière position du dernier élément dans la vue recycleur.Comment puis-je faire en sorte que le bouton Flottant reste au bas de la mise en page?
liste-activity.xml
<?xml version="1.0" encoding="utf-8"?>
<android.support.design.widget.CoordinatorLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<android.support.v7.widget.RecyclerView
tools:listitem="@layout/activity_sample_05borangb_parent"
android:id="@+id/recyclerView2"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:scrollbars="vertical"/>
</RelativeLayout>
<android.support.design.widget.FloatingActionButton
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:foregroundGravity="bottom"
android:layout_gravity="bottom|end"/>
</android.support.design.widget.CoordinatorLayout>
Supprimer 'android: scrollbars' ou' Android: foregroundGravity' et un essai. – KeLiuyue
@KeLiuyue je l'ai essayé ... mais le bouton planait toujours au milieu de la mise en page – xxmilcutexx