From 1d1e203d40870c693240ef613332933259dded51 Mon Sep 17 00:00:00 2001 From: Danny Baumann Date: Mon, 29 Jul 2024 14:05:47 +0200 Subject: [PATCH] Fix icon placement for section switches The way View.createSkeleton() works doesn't play nicely with ConstraintLayout as it causes constraints to be lost, thus insert a wrapper view to keep the constraints intact. Fixes #3773 Signed-off-by: Danny Baumann --- .../layout/widgetlist_sectionswitchitem.xml | 21 ++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/mobile/src/main/res/layout/widgetlist_sectionswitchitem.xml b/mobile/src/main/res/layout/widgetlist_sectionswitchitem.xml index dd60715b3f..8e8116c960 100644 --- a/mobile/src/main/res/layout/widgetlist_sectionswitchitem.xml +++ b/mobile/src/main/res/layout/widgetlist_sectionswitchitem.xml @@ -6,16 +6,23 @@ android:layout_width="match_parent" android:layout_height="wrap_content"> - + app:layout_constraintBottom_toBottomOf="parent"> + + + + @@ -59,7 +66,7 @@ android:layout_marginStart="16dp" android:layout_marginTop="4dp" app:layout_constraintEnd_toEndOf="parent" - app:layout_constraintStart_toEndOf="@id/widgeticon" + app:layout_constraintStart_toEndOf="@id/widgeticon_container" app:layout_constraintTop_toBottomOf="@id/labelbarrier" app:singleSelection="true">