Fix margin issue when second text is not displayed

This commit is contained in:
Benoit Marty 2019-06-17 18:13:34 +02:00
parent 7e9275831b
commit 8c8a4dcbd1
2 changed files with 18 additions and 6 deletions

View File

@ -49,9 +49,9 @@
style="@style/Widget.AppCompat.ProgressBar.Horizontal" style="@style/Widget.AppCompat.ProgressBar.Horizontal"
android:layout_width="0dp" android:layout_width="0dp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:background="?riotx_header_panel_background"
android:indeterminate="true" android:indeterminate="true"
android:visibility="gone" android:visibility="gone"
android:background="?riotx_header_panel_background"
app:layout_constraintEnd_toEndOf="parent" app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent" app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/groupToolbar" app:layout_constraintTop_toBottomOf="@id/groupToolbar"

View File

@ -20,21 +20,27 @@
app:layout_constraintStart_toStartOf="parent" app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" /> app:layout_constraintTop_toTopOf="parent" />


<Space
android:id="@+id/view_keys_backup_banner_space1"
android:layout_width="wrap_content"
android:layout_height="8dp"
app:layout_constraintBottom_toTopOf="@+id/view_keys_backup_banner_text_1"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_chainStyle="packed" />

<TextView <TextView
android:id="@+id/view_keys_backup_banner_text_1" android:id="@+id/view_keys_backup_banner_text_1"
android:layout_width="0dp" android:layout_width="0dp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginStart="27dp" android:layout_marginStart="27dp"
android:layout_marginLeft="27dp" android:layout_marginLeft="27dp"
android:layout_marginTop="8dp"
android:text="@string/keys_backup_banner_setup_line1" android:text="@string/keys_backup_banner_setup_line1"
android:textColor="?riotx_text_primary" android:textColor="?riotx_text_primary"
android:textSize="15sp" android:textSize="15sp"
app:layout_constraintBottom_toTopOf="@id/view_keys_backup_banner_text_2" app:layout_constraintBottom_toTopOf="@id/view_keys_backup_banner_text_2"
app:layout_constraintEnd_toStartOf="@id/view_keys_backup_banner_barrier" app:layout_constraintEnd_toStartOf="@id/view_keys_backup_banner_barrier"
app:layout_constraintStart_toEndOf="@id/view_keys_backup_banner_picto" app:layout_constraintStart_toEndOf="@id/view_keys_backup_banner_picto"
app:layout_constraintTop_toTopOf="parent" app:layout_constraintTop_toBottomOf="@+id/view_keys_backup_banner_space1" />
app:layout_constraintVertical_chainStyle="packed" />


<TextView <TextView
android:id="@+id/view_keys_backup_banner_text_2" android:id="@+id/view_keys_backup_banner_text_2"
@ -42,17 +48,23 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginStart="27dp" android:layout_marginStart="27dp"
android:layout_marginLeft="27dp" android:layout_marginLeft="27dp"
android:layout_marginBottom="8dp"
android:text="@string/keys_backup_banner_setup_line2" android:text="@string/keys_backup_banner_setup_line2"
android:textColor="?colorAccent" android:textColor="?colorAccent"
android:textSize="15sp" android:textSize="15sp"
android:visibility="gone" android:visibility="gone"
app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintBottom_toTopOf="@+id/view_keys_backup_banner_space2"
app:layout_constraintEnd_toStartOf="@id/view_keys_backup_banner_barrier" app:layout_constraintEnd_toStartOf="@id/view_keys_backup_banner_barrier"
app:layout_constraintStart_toEndOf="@id/view_keys_backup_banner_picto" app:layout_constraintStart_toEndOf="@id/view_keys_backup_banner_picto"
app:layout_constraintTop_toBottomOf="@id/view_keys_backup_banner_text_1" app:layout_constraintTop_toBottomOf="@id/view_keys_backup_banner_text_1"
tools:visibility="visible" /> tools:visibility="visible" />


<Space
android:id="@+id/view_keys_backup_banner_space2"
android:layout_width="wrap_content"
android:layout_height="8dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintTop_toBottomOf="@+id/view_keys_backup_banner_text_2" />

<androidx.constraintlayout.widget.Barrier <androidx.constraintlayout.widget.Barrier
android:id="@+id/view_keys_backup_banner_barrier" android:id="@+id/view_keys_backup_banner_barrier"
android:layout_width="wrap_content" android:layout_width="wrap_content"