如上图,【好的,我知道了】按钮需要基于白色框框底部居中,可以这样实现:
1.两个控件是在ConstraintLayout下的同层级对象。 A,B控件
2.【好的,我知道了】B控件的
layout_constraintBottom_toBottomOf 以及 layout_constraintTop_toBottomOf
都设置成A对象,即可实现。
既 【好的,我知道了】B控件都Top和Bottom都相对A控件底部对齐
重点:【好的,我知道了】需要指定控件高度或者最小高度
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_margin="10dp">
android:id="@+id/guardian_share_complete_layout"
android:layout_width="match_parent"
android:layout_height="300dp"
android:layout_marginTop="135dp"
android:backgro