RecyclerView

<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent">

<Button
android:id="@+id/removeButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="9dp"
android:layout_weight="1"
android:text="删除"
app:layout_constraintBottom_toTopOf="@+id/recycleview"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toEndOf="@+id/addButton"
app:layout_constraintTop_toTopOf="parent" />

<Button
android:id="@+id/addButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="9dp"
android:layout_marginEnd="17dp"
android:layout_marginStart="9dp"
android:layout_weight="1"
android:text="添加"
app:layout_constraintBottom_toTopOf="@+id/recycleview"
app:layout_constraintEnd_toStartOf="@+id/removeButton"
app:layout_constraintHorizontal_chainStyle="packed"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />

<android.support.v7.widget.RecyclerView
android:id="@+id/recycleview"
android:layout_width="0dp"
android:layout_height="0dp"
android:layout_marginBottom="12dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/removeButton" />
</android.support.constraint.ConstraintLayout>

posted @ 2019-08-18 17:33  水至清明  阅读(115)  评论(0编辑  收藏  举报