From 70476b912f017a13561381646caa263b17550fff Mon Sep 17 00:00:00 2001 From: Valere Date: Wed, 28 Apr 2021 09:26:32 +0200 Subject: [PATCH] Fix / placeholder in dark time --- .../room/relationship/RoomChildRelationInfo.kt | 3 +-- .../res/drawable/placeholder_round_background.xml | 5 +++++ vector/src/main/res/drawable/placeholder_shape_8.xml | 11 +++++++++++ vector/src/main/res/layout/item_editable_avatar.xml | 2 +- .../main/res/layout/item_editable_square_avatar.xml | 2 +- vector/src/main/res/layout/item_room_placeholder.xml | 6 +++--- 6 files changed, 22 insertions(+), 7 deletions(-) create mode 100644 vector/src/main/res/drawable/placeholder_round_background.xml create mode 100644 vector/src/main/res/drawable/placeholder_shape_8.xml diff --git a/matrix-sdk-android/src/main/java/org/matrix/android/sdk/internal/session/room/relationship/RoomChildRelationInfo.kt b/matrix-sdk-android/src/main/java/org/matrix/android/sdk/internal/session/room/relationship/RoomChildRelationInfo.kt index cff1019893..2efea7f118 100644 --- a/matrix-sdk-android/src/main/java/org/matrix/android/sdk/internal/session/room/relationship/RoomChildRelationInfo.kt +++ b/matrix-sdk-android/src/main/java/org/matrix/android/sdk/internal/session/room/relationship/RoomChildRelationInfo.kt @@ -24,7 +24,6 @@ import org.matrix.android.sdk.api.session.space.model.SpaceParentContent import org.matrix.android.sdk.internal.database.mapper.ContentMapper import org.matrix.android.sdk.internal.database.model.CurrentStateEventEntity import org.matrix.android.sdk.internal.database.query.whereType -import timber.log.Timber /** * Relationship between rooms and spaces @@ -66,7 +65,7 @@ internal class RoomChildRelationInfo( // } .mapNotNull { ContentMapper.map(it.root?.content).toModel()?.let { scc -> - Timber.v("## Space child desc state event $scc") +// Timber.v("## Space child desc state event $scc") // Children where via is not present are ignored. scc.via?.let { via -> SpaceChildInfo( diff --git a/vector/src/main/res/drawable/placeholder_round_background.xml b/vector/src/main/res/drawable/placeholder_round_background.xml new file mode 100644 index 0000000000..b7bde9ed67 --- /dev/null +++ b/vector/src/main/res/drawable/placeholder_round_background.xml @@ -0,0 +1,5 @@ + + + + diff --git a/vector/src/main/res/drawable/placeholder_shape_8.xml b/vector/src/main/res/drawable/placeholder_shape_8.xml new file mode 100644 index 0000000000..f0a9e856a2 --- /dev/null +++ b/vector/src/main/res/drawable/placeholder_shape_8.xml @@ -0,0 +1,11 @@ + + + + + + + + + + \ No newline at end of file diff --git a/vector/src/main/res/layout/item_editable_avatar.xml b/vector/src/main/res/layout/item_editable_avatar.xml index 654787384f..7c067cc46c 100644 --- a/vector/src/main/res/layout/item_editable_avatar.xml +++ b/vector/src/main/res/layout/item_editable_avatar.xml @@ -13,7 +13,7 @@ android:id="@+id/itemEditableAvatarImageContainer" android:layout_width="128dp" android:layout_height="128dp" - android:background="@drawable/header_panel_round_background" + android:background="@drawable/placeholder_round_background" android:contentDescription="@string/a11y_change_avatar" app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintEnd_toEndOf="parent" diff --git a/vector/src/main/res/layout/item_editable_square_avatar.xml b/vector/src/main/res/layout/item_editable_square_avatar.xml index 04bf95e983..d931e807ea 100644 --- a/vector/src/main/res/layout/item_editable_square_avatar.xml +++ b/vector/src/main/res/layout/item_editable_square_avatar.xml @@ -13,7 +13,7 @@ android:id="@+id/itemEditableAvatarImageContainer" android:layout_width="80dp" android:layout_height="80dp" - android:background="@drawable/rounded_rect_shape_16" + android:background="@drawable/placeholder_shape_8" android:contentDescription="@string/a11y_change_avatar" app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintEnd_toEndOf="parent" diff --git a/vector/src/main/res/layout/item_room_placeholder.xml b/vector/src/main/res/layout/item_room_placeholder.xml index c5fdd7781a..8ce1ded2e1 100644 --- a/vector/src/main/res/layout/item_room_placeholder.xml +++ b/vector/src/main/res/layout/item_room_placeholder.xml @@ -25,7 +25,7 @@ android:layout_width="56dp" android:layout_height="56dp" android:importantForAccessibility="no" - android:src="@drawable/header_panel_round_background" /> + android:src="@drawable/placeholder_round_background" /> @@ -46,7 +46,7 @@ android:layout_marginStart="@dimen/layout_horizontal_margin" android:layout_marginTop="12dp" android:layout_marginEnd="70dp" - android:background="@drawable/rounded_rect_shape_8" + android:background="@drawable/placeholder_shape_8" app:layout_constrainedWidth="true" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintHorizontal_bias="0.0" @@ -61,7 +61,7 @@ android:layout_height="30dp" android:layout_marginTop="8dp" android:layout_marginEnd="20dp" - android:background="@drawable/rounded_rect_shape_8" + android:background="@drawable/placeholder_shape_8" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="@+id/roomNameView" app:layout_constraintTop_toBottomOf="@+id/roomNameView" />