El diseño se ensucia cuando se abre el cuadro de diálogo

Estoy enfrentando un error muy extraño con uno de diseño cuyo padre es ConstraintLayout. Cuando alguna vez un diaog está abierto el diseño detrás de iniciar automáticamente constracting y movimiento. Por favor refiérase al gif adjunto para una idea sobre el error. Por favor, compruebe mi código y ver si estoy haciendo algo mal.

Aquí está mi diseño.

<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" android:background="@color/picker_bg" android:padding="@dimen/_8dp"> <!-- Pick details layout starts --> <android.support.v7.widget.CardView android:id="@+id/load_details_card" android:layout_width="wrap_content" android:layout_height="wrap_content" app:cardCornerRadius="@dimen/_1dp" app:cardElevation="@dimen/_2dp" app:layout_constraintEnd_toStartOf="@+id/load_status_card" app:layout_constraintStart_toStartOf="parent"> <android.support.constraint.ConstraintLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:paddingBottom="@dimen/_8dp" android:paddingEnd="@dimen/_12dp" android:paddingStart="@dimen/_12dp" android:paddingTop="@dimen/_8dp"> <TextView android:id="@+id/load_id" android:layout_width="wrap_content" android:layout_height="wrap_content" android:gravity="center_horizontal" android:text="@string/load_id" android:textSize="@dimen/_16sp" app:layout_constraintEnd_toStartOf="@+id/stops" app:layout_constraintHorizontal_chainStyle="packed" app:layout_constraintLeft_toLeftOf="parent" app:layout_constraintStart_toStartOf="parent" /> <TextView android:id="@+id/load_id_value" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginTop="@dimen/_6dp" android:gravity="center_horizontal" android:text="900" android:textSize="@dimen/_16sp" app:layout_constraintEnd_toEndOf="@+id/load_id" app:layout_constraintStart_toStartOf="@+id/load_id" app:layout_constraintTop_toBottomOf="@+id/load_id" /> <TextView android:id="@+id/stops" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="@dimen/_12dp" android:gravity="center_horizontal" android:text="@string/stops" android:textSize="@dimen/_16sp" app:layout_constraintEnd_toStartOf="@+id/truck" app:layout_constraintStart_toEndOf="@+id/load_id" /> <TextView android:id="@+id/stops_value" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginTop="@dimen/_6dp" android:gravity="center_horizontal" android:text="3" android:textSize="@dimen/_16sp" app:layout_constraintEnd_toEndOf="@+id/stops" app:layout_constraintStart_toStartOf="@+id/stops" app:layout_constraintTop_toBottomOf="@+id/stops" /> <TextView android:id="@+id/truck" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="@dimen/_12dp" android:gravity="center_horizontal" android:text="@string/truck" android:textSize="@dimen/_16sp" app:layout_constraintEnd_toStartOf="@+id/trailer" app:layout_constraintStart_toEndOf="@+id/stops" /> <TextView android:id="@+id/truck_value" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginTop="@dimen/_6dp" android:gravity="center_horizontal" android:text="100" android:textSize="@dimen/_16sp" app:layout_constraintEnd_toEndOf="@+id/truck" app:layout_constraintStart_toStartOf="@+id/truck" app:layout_constraintTop_toBottomOf="@+id/truck" /> <TextView android:id="@+id/trailer" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="@dimen/_12dp" android:gravity="center_horizontal" android:text="@string/trailer" android:textSize="@dimen/_16sp" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toEndOf="@+id/truck" /> <TextView android:id="@+id/trailer_value" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginTop="@dimen/_6dp" android:gravity="center_horizontal" android:text="300" android:textSize="@dimen/_16sp" app:layout_constraintEnd_toEndOf="@+id/trailer" app:layout_constraintStart_toStartOf="@+id/trailer" app:layout_constraintTop_toBottomOf="@+id/trailer" /> </android.support.constraint.ConstraintLayout> </android.support.v7.widget.CardView> <!-- Pick details layout end --> <!-- Pick status layout starts --> <android.support.v7.widget.CardView android:id="@+id/load_status_card" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="@dimen/_8dp" app:cardCornerRadius="@dimen/_1dp" app:cardElevation="@dimen/_2dp" app:layout_constraintEnd_toStartOf="@+id/bt_move_items_to_stage" app:layout_constraintStart_toEndOf="@+id/load_details_card"> <android.support.constraint.ConstraintLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:paddingBottom="@dimen/_8dp" android:paddingEnd="@dimen/_12dp" android:paddingStart="@dimen/_12dp" android:paddingTop="@dimen/_8dp"> <TextView android:id="@+id/status" android:layout_width="wrap_content" android:layout_height="wrap_content" android:gravity="center_horizontal" android:text="Status" android:textSize="@dimen/_16sp" app:layout_constraintEnd_toStartOf="@+id/start_time" app:layout_constraintHorizontal_chainStyle="packed" app:layout_constraintStart_toStartOf="parent" /> <TextView android:id="@+id/status_value" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginTop="@dimen/_6dp" android:gravity="center_horizontal" android:text="Start" android:textSize="@dimen/_16sp" app:layout_constraintEnd_toEndOf="@+id/status" app:layout_constraintStart_toStartOf="@+id/status" app:layout_constraintTop_toBottomOf="@+id/status" /> <TextView android:id="@+id/start_time" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="@dimen/_12dp" android:gravity="center_horizontal" android:text="Start Time" android:textSize="@dimen/_16sp" app:layout_constraintEnd_toStartOf="@+id/break_time" app:layout_constraintStart_toEndOf="@+id/status" /> <TextView android:id="@+id/start_time_value" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginTop="@dimen/_6dp" android:gravity="center_horizontal" android:text="472423" android:textSize="@dimen/_16sp" app:layout_constraintEnd_toEndOf="@+id/start_time" app:layout_constraintStart_toStartOf="@+id/start_time" app:layout_constraintTop_toBottomOf="@+id/start_time" tools:layout_editor_absoluteX="355dp" /> <TextView android:id="@+id/break_time" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="@dimen/_12dp" android:gravity="center_horizontal" android:text="Break Time" android:textSize="@dimen/_16sp" app:layout_constraintEnd_toStartOf="@+id/total_breaks" app:layout_constraintStart_toEndOf="@+id/start_time" /> <TextView android:id="@+id/break_time_value" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginTop="@dimen/_6dp" android:gravity="center_horizontal" android:text="00:00:00" android:textSize="@dimen/_16sp" app:layout_constraintEnd_toEndOf="@+id/break_time" app:layout_constraintStart_toStartOf="@+id/break_time" app:layout_constraintTop_toBottomOf="@+id/break_time" tools:layout_editor_absoluteX="1154dp" /> <TextView android:id="@+id/total_breaks" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="@dimen/_12dp" android:gravity="center_horizontal" android:text="Total Breaks" android:textSize="@dimen/_16sp" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toEndOf="@+id/break_time" /> <TextView android:id="@+id/total_breaks_value" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginTop="@dimen/_6dp" android:gravity="center_horizontal" android:text="0" android:textSize="@dimen/_16sp" app:layout_constraintEnd_toEndOf="@+id/total_breaks" app:layout_constraintStart_toStartOf="@+id/total_breaks" app:layout_constraintTop_toBottomOf="@+id/total_breaks" /> </android.support.constraint.ConstraintLayout> </android.support.v7.widget.CardView> <!-- Pick status layout end --> <!-- Button move items to stage --> <Button android:id="@+id/bt_unload_items" android:layout_width="0dp" android:layout_height="0dp" android:layout_marginStart="@dimen/_8dp" android:backgroundTint="@color/colorPrimary" android:drawableStart="@drawable/ic_archive_black_24dp" android:drawablePadding="@dimen/_4dp" android:drawableTint="@color/white" android:tag="picking" android:text="@string/unload_items" android:textColor="@color/white" android:textSize="@dimen/_13sp" app:layout_constraintBottom_toBottomOf="@+id/load_status_card" app:layout_constraintEnd_toStartOf="@+id/bt_finish_loading" app:layout_constraintHorizontal_chainStyle="spread" app:layout_constraintHorizontal_weight="1" app:layout_constraintStart_toEndOf="@+id/load_status_card" app:layout_constraintTop_toTopOf="@+id/load_status_card" app:layout_constraintVertical_bias="1.0" /> <!-- Button finish picking --> <Button android:id="@+id/bt_finish_loading" android:layout_width="0dp" android:layout_height="0dp" android:drawablePadding="@dimen/_4dp" android:layout_marginStart="@dimen/_8dp" android:backgroundTint="@color/colorAccent" android:drawableStart="@drawable/ic_done_black_24dp" android:drawableTint="@color/white" android:text="Finish Loading" android:textColor="@color/white" android:textSize="@dimen/_13sp" app:layout_constraintBottom_toBottomOf="@+id/bt_unload_items" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintHorizontal_weight="1" app:layout_constraintStart_toEndOf="@+id/bt_unload_items" app:layout_constraintTop_toTopOf="@+id/bt_unload_items" app:layout_constraintVertical_bias="0.0" /> <!-- Button instructions --> <Button android:id="@+id/bt_instructions" android:layout_width="0dp" android:layout_height="wrap_content" android:minHeight="@dimen/_53dp" android:drawablePadding="@dimen/_4dp" android:layout_marginLeft="@dimen/_2dp" android:layout_marginTop="@dimen/_8dp" android:backgroundTint="@color/colorPrimary" android:drawableStart="@drawable/ic_info_outline_black_24dp" android:drawableTint="@color/white" android:text="Instructions" android:textColor="@color/white" android:textSize="@dimen/_13sp" app:layout_constraintEnd_toStartOf="@+id/layout_progress" app:layout_constraintHorizontal_weight="1" app:layout_constraintLeft_toLeftOf="parent" app:layout_constraintTop_toBottomOf="@+id/load_details_card" /> <!-- Picking progress layout--> <include android:id="@+id/layout_progress" layout="@layout/layout_progress_horizontal_percentage" android:layout_width="0dp" android:layout_height="0dp" android:layout_marginStart="@dimen/_8dp" app:layout_constraintBottom_toBottomOf="@+id/bt_instructions" app:layout_constraintEnd_toStartOf="@+id/bt_suspend" app:layout_constraintHorizontal_weight="3.4" app:layout_constraintStart_toEndOf="@+id/bt_instructions" app:layout_constraintTop_toTopOf="@+id/bt_instructions" /> <!-- Button suspend --> <Button android:id="@+id/bt_suspend" android:layout_width="0dp" android:layout_height="0dp" android:drawablePadding="@dimen/_4dp" android:layout_marginStart="@dimen/_8dp" android:backgroundTint="@color/colorPrimary" android:drawableStart="@drawable/ic_stop_black_24dp" android:drawableTint="@color/white" android:text="Suspend" android:textColor="@color/white" android:textSize="@dimen/_13sp" app:layout_constraintBottom_toBottomOf="@+id/layout_progress" app:layout_constraintEnd_toStartOf="@+id/bt_pause" app:layout_constraintHorizontal_weight="1" app:layout_constraintStart_toEndOf="@+id/layout_progress" app:layout_constraintTop_toTopOf="@+id/layout_progress" app:layout_constraintVertical_bias="0.0" tools:layout_editor_absoluteX="654dp" /> <!-- Button pause --> <Button android:id="@+id/bt_pause" android:layout_width="0dp" android:layout_height="0dp" android:layout_marginStart="@dimen/_8dp" android:drawablePadding="@dimen/_4dp" android:backgroundTint="@color/colorPrimary" android:drawableStart="@drawable/ic_pause_black_24dp" android:drawableTint="@color/white" android:padding="@dimen/_8dp" android:text="Pause" android:textColor="@color/white" android:textSize="@dimen/_13sp" app:layout_constraintBottom_toBottomOf="@+id/bt_suspend" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintHorizontal_weight="1" app:layout_constraintStart_toEndOf="@+id/bt_suspend" app:layout_constraintTop_toTopOf="@+id/bt_suspend" tools:layout_editor_absoluteX="1089dp" /> <!-- Building selection layout starts --> <!-- Building selection layout ends --> <!-- Fragment Container --> <!-- app:layout_constraintTop_toTopOf="@+id/layout_building" --> <ScrollView android:id="@+id/scrollview_nested_fragment_container" android:layout_width="0dp" android:layout_height="0dp" android:layout_marginStart="12dp" android:layout_marginTop="12dp" app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintHorizontal_weight="5" app:layout_constraintStart_toEndOf="@+id/layout_stop" app:layout_constraintTop_toBottomOf="@+id/bt_instructions"> <FrameLayout android:id="@+id/nested_fragment_container" android:layout_width="match_parent" android:layout_height="wrap_content" /> </ScrollView> <android.support.v7.widget.CardView android:id="@+id/layout_stop" android:layout_width="0dp" android:layout_height="wrap_content" android:layout_marginTop="@dimen/_8dp" app:layout_constraintEnd_toStartOf="@+id/scrollview_nested_fragment_container" app:layout_constraintHorizontal_weight="1" app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toBottomOf="@+id/bt_instructions" tools:layout_editor_absoluteX="16dp"> <LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="vertical"> <LinearLayout android:id="@+id/all_stops" android:layout_width="match_parent" android:layout_height="wrap_content" android:background="@color/selector_building_bg" android:gravity="center_vertical" android:orientation="horizontal" android:padding="@dimen/_4dp" android:tag="0"> <TextView android:layout_width="0dp" android:layout_height="wrap_content" android:layout_weight="1" android:text="All" android:textColor="@color/selector_building_text" /> <TextView android:id="@+id/all_stops_pick_count" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="@dimen/_15dp" android:text="10" android:textColor="@color/selector_building_text" /> <ImageView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="@dimen/_15dp" android:src="@drawable/ic_keyboard_arrow_right_black_24dp" android:tint="@color/selector_building_arrow" /> </LinearLayout> <LinearLayout android:id="@+id/stop_1" android:layout_width="match_parent" android:layout_height="wrap_content" android:background="@color/selector_building_bg" android:gravity="center_vertical" android:orientation="horizontal" android:padding="@dimen/_4dp" android:tag="1"> <TextView android:id="@+id/textView8" android:layout_width="0dp" android:layout_height="wrap_content" android:layout_weight="1" android:text="Stop 1" android:textColor="@color/selector_building_text" /> <TextView android:id="@+id/stop_1_pick_count" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="@dimen/_15dp" android:text="3" android:textColor="@color/selector_building_text" /> <ImageView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="@dimen/_15dp" android:src="@drawable/ic_keyboard_arrow_right_black_24dp" android:tint="@color/selector_building_arrow" /> </LinearLayout> <LinearLayout android:id="@+id/stop_2" android:layout_width="match_parent" android:layout_height="wrap_content" android:background="@color/selector_building_bg" android:gravity="center_vertical" android:orientation="horizontal" android:padding="@dimen/_4dp" android:tag="2"> <TextView android:layout_width="0dp" android:layout_height="wrap_content" android:layout_weight="1" android:text="Stop 2" android:textColor="@color/selector_building_text" /> <TextView android:id="@+id/stop_2_pick_count" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="@dimen/_15dp" android:text="2" android:textColor="@color/selector_building_text" /> <ImageView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="@dimen/_15dp" android:src="@drawable/ic_keyboard_arrow_right_black_24dp" android:tint="@color/selector_building_arrow" /> </LinearLayout> <LinearLayout android:id="@+id/stop_3" android:layout_width="match_parent" android:layout_height="wrap_content" android:background="@color/selector_building_bg" android:gravity="center_vertical" android:orientation="horizontal" android:padding="@dimen/_4dp" android:tag="3"> <TextView android:id="@+id/textView6" android:layout_width="0dp" android:layout_height="wrap_content" android:layout_weight="1" android:text="Stop 3" android:textColor="@color/selector_building_text" /> <TextView android:id="@+id/stop_3_pick_count" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="@dimen/_15dp" android:text="5" android:textColor="@color/selector_building_text" /> <ImageView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="@dimen/_15dp" android:src="@drawable/ic_keyboard_arrow_right_black_24dp" android:tint="@color/selector_building_arrow" /> </LinearLayout> </LinearLayout> </android.support.v7.widget.CardView> <!-- Table layout --> <!-- <android.support.v7.widget.CardView android:id="@+id/table" android:layout_width="0dp" android:layout_height="0dp" android:layout_marginStart="12dp" app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintHorizontal_weight="5" app:layout_constraintStart_toEndOf="@+id/layout_building" app:layout_constraintTop_toBottomOf="@+id/bt_instructions" app:layout_constraintTop_toTopOf="@+id/layout_building"> <include layout="@layout/layout_picking_table" /> </android.support.v7.widget.CardView>--> </android.support.constraint.ConstraintLayout> 

Aquí está el gif Introduzca aquí la descripción de la imagen

FlipAndroid es un fan de Google para Android, Todo sobre Android Phones, Android Wear, Android Dev y Aplicaciones para Android Aplicaciones.