我有两个子布局ConstraintLayout
(一个在另一个之上)。它在除 Android 8.1 (Android O) 之外的所有 Android 版本中首先显示第二个布局,其中第二个布局隐藏在第一个布局后面。
<android.support.constraint.ConstraintLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
xmlns:app="http://schemas.android.com/apk/res-auto">
<RelativeLayout android:id="@+id/subscriberViewContainer"
android:layout_marginBottom="50dp"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintBottom_toBottomOf="parent"
android:background="@color/colorAccent"/>
<RelativeLayout
android:id="@+id/publisherViewContainer"
android:layout_alignParentBottom="true"
android:layout_marginLeft="5dp"
android:layout_marginBottom="5dp"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintBottom_toBottomOf="parent"
android:layout_width="120dp"
android:layout_height="90dp"
android:elevation="20dp"
android:background="@color/colorPrimary"/>
</android.support.constraint.ConstraintLayout>
是否需要在 Android O 中进行任何更改才能获得与其他响应相同的响应?