Revert latest changes regarding avatar to properly fix phone number avatar across app
This commit is contained in:
parent
ce3d333a98
commit
d9dce51823
16 changed files with 29 additions and 12 deletions
|
@ -203,7 +203,7 @@ dependencies {
|
||||||
implementation "androidx.security:security-crypto-ktx:1.1.0-alpha03"
|
implementation "androidx.security:security-crypto-ktx:1.1.0-alpha03"
|
||||||
implementation "androidx.window:window:1.0.0"
|
implementation "androidx.window:window:1.0.0"
|
||||||
|
|
||||||
def nav_version = "2.5.2"
|
def nav_version = "2.5.3"
|
||||||
implementation "androidx.navigation:navigation-fragment-ktx:$nav_version"
|
implementation "androidx.navigation:navigation-fragment-ktx:$nav_version"
|
||||||
implementation "androidx.navigation:navigation-ui-ktx:$nav_version"
|
implementation "androidx.navigation:navigation-ui-ktx:$nav_version"
|
||||||
|
|
||||||
|
|
|
@ -354,7 +354,7 @@ private suspend fun loadContactPictureWithCoil(
|
||||||
transformations(CircleCropTransformation())
|
transformations(CircleCropTransformation())
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
imageView.load(R.drawable.icon_single_contact_avatar_alt)
|
imageView.load(R.drawable.icon_single_contact_avatar)
|
||||||
}
|
}
|
||||||
} else if (contact.showGroupChatAvatar) {
|
} else if (contact.showGroupChatAvatar) {
|
||||||
imageView.load(AppCompatResources.getDrawable(context, R.drawable.icon_multiple_contacts_avatar))
|
imageView.load(AppCompatResources.getDrawable(context, R.drawable.icon_multiple_contacts_avatar))
|
||||||
|
@ -366,7 +366,7 @@ private suspend fun loadContactPictureWithCoil(
|
||||||
transformations(CircleCropTransformation())
|
transformations(CircleCropTransformation())
|
||||||
error(
|
error(
|
||||||
if (displayName.isEmpty() || AppUtils.getInitials(displayName) == "+") {
|
if (displayName.isEmpty() || AppUtils.getInitials(displayName) == "+") {
|
||||||
AppCompatResources.getDrawable(context, R.drawable.icon_single_contact_avatar_alt)
|
AppCompatResources.getDrawable(context, R.drawable.icon_single_contact_avatar)
|
||||||
} else {
|
} else {
|
||||||
coroutineScope {
|
coroutineScope {
|
||||||
withContext(Dispatchers.IO) {
|
withContext(Dispatchers.IO) {
|
||||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 12 KiB |
|
@ -1,7 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
|
||||||
<item>
|
|
||||||
<bitmap android:src="@drawable/voip_single_contact_avatar_alt_2"
|
|
||||||
android:tint="?attr/drawableTintColor"/>
|
|
||||||
</item>
|
|
||||||
</selector>
|
|
|
@ -70,6 +70,8 @@
|
||||||
android:layout_alignParentLeft="true"
|
android:layout_alignParentLeft="true"
|
||||||
android:layout_marginLeft="10dp"
|
android:layout_marginLeft="10dp"
|
||||||
android:layout_marginRight="10dp"
|
android:layout_marginRight="10dp"
|
||||||
|
android:background="@drawable/generated_avatar_bg"
|
||||||
|
android:src="@drawable/voip_single_contact_avatar"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:visibility="@{data.chatMessage.outgoing || selectionListViewModel.isEditionEnabled ? View.GONE : (data.hideAvatar ? View.INVISIBLE : View.VISIBLE)}" />
|
android:visibility="@{data.chatMessage.outgoing || selectionListViewModel.isEditionEnabled ? View.GONE : (data.hideAvatar ? View.INVISIBLE : View.VISIBLE)}" />
|
||||||
|
|
||||||
|
|
|
@ -34,6 +34,8 @@
|
||||||
android:layout_height="@dimen/contact_avatar_size"
|
android:layout_height="@dimen/contact_avatar_size"
|
||||||
android:layout_alignParentStart="true"
|
android:layout_alignParentStart="true"
|
||||||
android:layout_centerHorizontal="true"
|
android:layout_centerHorizontal="true"
|
||||||
|
android:background="@drawable/generated_avatar_bg"
|
||||||
|
android:src="@drawable/voip_single_contact_avatar"
|
||||||
android:contentDescription="@null" />
|
android:contentDescription="@null" />
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
|
|
|
@ -32,6 +32,8 @@
|
||||||
android:layout_height="@dimen/contact_avatar_size"
|
android:layout_height="@dimen/contact_avatar_size"
|
||||||
android:layout_alignParentStart="true"
|
android:layout_alignParentStart="true"
|
||||||
android:layout_centerHorizontal="true"
|
android:layout_centerHorizontal="true"
|
||||||
|
android:background="@drawable/generated_avatar_bg"
|
||||||
|
android:src="@drawable/voip_single_contact_avatar"
|
||||||
android:contentDescription="@null" />
|
android:contentDescription="@null" />
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
|
|
|
@ -20,6 +20,8 @@
|
||||||
android:layout_height="@dimen/contact_avatar_size"
|
android:layout_height="@dimen/contact_avatar_size"
|
||||||
android:layout_marginRight="10dp"
|
android:layout_marginRight="10dp"
|
||||||
coilContact="@{data}"
|
coilContact="@{data}"
|
||||||
|
android:background="@drawable/generated_avatar_bg"
|
||||||
|
android:src="@drawable/voip_single_contact_avatar"
|
||||||
android:contentDescription="@null"
|
android:contentDescription="@null"
|
||||||
android:layout_centerVertical="true"/>
|
android:layout_centerVertical="true"/>
|
||||||
|
|
||||||
|
|
|
@ -33,6 +33,8 @@
|
||||||
android:layout_height="@dimen/contact_avatar_size"
|
android:layout_height="@dimen/contact_avatar_size"
|
||||||
android:layout_alignParentStart="true"
|
android:layout_alignParentStart="true"
|
||||||
android:layout_centerHorizontal="true"
|
android:layout_centerHorizontal="true"
|
||||||
|
android:background="@drawable/generated_avatar_bg"
|
||||||
|
android:src="@drawable/voip_single_contact_avatar"
|
||||||
android:contentDescription="@null" />
|
android:contentDescription="@null" />
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
|
|
|
@ -87,6 +87,8 @@
|
||||||
android:layout_width="@dimen/contact_avatar_big_size"
|
android:layout_width="@dimen/contact_avatar_big_size"
|
||||||
android:layout_height="@dimen/contact_avatar_big_size"
|
android:layout_height="@dimen/contact_avatar_big_size"
|
||||||
coilContactBig="@{viewModel}"
|
coilContactBig="@{viewModel}"
|
||||||
|
android:background="@drawable/generated_avatar_bg"
|
||||||
|
android:src="@drawable/voip_single_contact_avatar"
|
||||||
android:contentDescription="@null" />
|
android:contentDescription="@null" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
|
|
|
@ -79,6 +79,8 @@
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
coilContactBig="@{viewModel}"
|
coilContactBig="@{viewModel}"
|
||||||
|
android:background="@drawable/generated_avatar_bg"
|
||||||
|
android:src="@drawable/voip_single_contact_avatar"
|
||||||
android:contentDescription="@null" />
|
android:contentDescription="@null" />
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
|
|
|
@ -39,6 +39,8 @@
|
||||||
coilContact="@{viewModel}"
|
coilContact="@{viewModel}"
|
||||||
android:layout_marginRight="10dp"
|
android:layout_marginRight="10dp"
|
||||||
android:layout_centerVertical="true"
|
android:layout_centerVertical="true"
|
||||||
|
android:background="@drawable/generated_avatar_bg"
|
||||||
|
android:src="@drawable/voip_single_contact_avatar"
|
||||||
android:contentDescription="@null" />
|
android:contentDescription="@null" />
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
|
|
|
@ -36,6 +36,8 @@
|
||||||
android:layout_height="@dimen/contact_avatar_size"
|
android:layout_height="@dimen/contact_avatar_size"
|
||||||
android:layout_alignParentStart="true"
|
android:layout_alignParentStart="true"
|
||||||
android:layout_centerHorizontal="true"
|
android:layout_centerHorizontal="true"
|
||||||
|
android:background="@drawable/generated_avatar_bg"
|
||||||
|
android:src="@drawable/voip_single_contact_avatar"
|
||||||
android:contentDescription="@null" />
|
android:contentDescription="@null" />
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
|
|
|
@ -89,6 +89,8 @@
|
||||||
android:layout_width="@dimen/contact_avatar_big_size"
|
android:layout_width="@dimen/contact_avatar_big_size"
|
||||||
android:layout_height="@dimen/contact_avatar_big_size"
|
android:layout_height="@dimen/contact_avatar_big_size"
|
||||||
coilContactBig="@{viewModel}"
|
coilContactBig="@{viewModel}"
|
||||||
|
android:background="@drawable/generated_avatar_bg"
|
||||||
|
android:src="@drawable/voip_single_contact_avatar"
|
||||||
android:contentDescription="@null" />
|
android:contentDescription="@null" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
|
|
|
@ -33,7 +33,9 @@
|
||||||
coilContact="@{data}"
|
coilContact="@{data}"
|
||||||
android:layout_marginLeft="40dp"
|
android:layout_marginLeft="40dp"
|
||||||
android:layout_marginRight="10dp"
|
android:layout_marginRight="10dp"
|
||||||
android:layout_centerVertical="true"/>
|
android:layout_centerVertical="true"
|
||||||
|
android:background="@drawable/generated_avatar_bg"
|
||||||
|
android:src="@drawable/voip_single_contact_avatar"/>
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:visibility="@{data.isInRemoteConference ? View.VISIBLE : View.GONE, default=gone}"
|
android:visibility="@{data.isInRemoteConference ? View.VISIBLE : View.GONE, default=gone}"
|
||||||
|
|
|
@ -22,7 +22,9 @@
|
||||||
coilContact="@{data}"
|
coilContact="@{data}"
|
||||||
android:layout_marginStart="10dp"
|
android:layout_marginStart="10dp"
|
||||||
android:layout_marginEnd="10dp"
|
android:layout_marginEnd="10dp"
|
||||||
android:layout_centerVertical="true"/>
|
android:layout_centerVertical="true"
|
||||||
|
android:background="@drawable/generated_avatar_bg"
|
||||||
|
android:src="@drawable/voip_single_contact_avatar"/>
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/delete"
|
android:id="@+id/delete"
|
||||||
|
|
Loading…
Reference in a new issue