Fixed selecting participant in group conversation when typing '@'

This commit is contained in:
Sylvain Berfini 2025-03-12 10:57:01 +01:00
parent fbf68db2dd
commit 0e6d91a467
4 changed files with 5 additions and 19 deletions

View file

@ -46,16 +46,11 @@ class MessageBottomSheetParticipantModel
}
@UiThread
fun toggleShowSipUri() {
fun clicked() {
if (!isOurOwnReaction && !corePreferences.onlyDisplaySipUriUsername) {
showSipUri.postValue(showSipUri.value == false)
} else {
clicked()
onClick?.invoke()
}
}
@UiThread
fun clicked() {
onClick?.invoke()
}
}

View file

@ -58,19 +58,14 @@ class ParticipantModel
}
@UiThread
fun toggleShowSipUri() {
if (!corePreferences.onlyDisplaySipUriUsername) {
fun onClicked() {
if (onClicked == null && !corePreferences.onlyDisplaySipUriUsername) {
showSipUri.postValue(showSipUri.value == false)
} else {
onClicked()
onClicked?.invoke(this)
}
}
@UiThread
fun onClicked() {
onClicked?.invoke(this)
}
@UiThread
fun openMenu(view: View) {
onMenuClicked?.invoke(view, this)

View file

@ -32,7 +32,6 @@
<androidx.appcompat.widget.AppCompatTextView
style="@style/default_text_style"
android:onClick="@{() -> model.toggleShowSipUri()}"
android:id="@+id/name"
android:layout_width="0dp"
android:layout_height="wrap_content"
@ -47,7 +46,6 @@
<androidx.appcompat.widget.AppCompatTextView
style="@style/default_text_style_300"
android:onClick="@{() -> model.toggleShowSipUri()}"
android:id="@+id/sip_address"
android:layout_width="0dp"
android:layout_height="wrap_content"

View file

@ -33,7 +33,6 @@
<androidx.appcompat.widget.AppCompatTextView
style="@style/default_text_style"
android:onClick="@{() -> model.toggleShowSipUri()}"
android:id="@+id/name"
android:layout_width="0dp"
android:layout_height="wrap_content"
@ -49,7 +48,6 @@
<androidx.appcompat.widget.AppCompatTextView
style="@style/default_text_style_300"
android:onClick="@{() -> model.toggleShowSipUri()}"
android:id="@+id/sip_address"
android:layout_width="0dp"
android:layout_height="wrap_content"