mirror of
https://github.com/SchildiChat/SchildiChat-android.git
synced 2025-03-17 19:58:57 +03:00
Make long press on reply do same action as long press on message
Change-Id: Icfc101e8233ba55d5e95b47dfb2530faadea56df
This commit is contained in:
parent
32d076cbdf
commit
048e1edb54
2 changed files with 6 additions and 1 deletions
|
@ -273,7 +273,7 @@ abstract class AbsMessageItem<H : AbsMessageItem.Holder>(
|
|||
|
||||
override fun onStateUpdated(state: PreviewReplyUiState) {
|
||||
replyPreviewRetriever?.let {
|
||||
replyView?.render(state, it, attributes.informationData, movementMethod, coroutineScope)
|
||||
replyView?.render(state, it, attributes.informationData, movementMethod, attributes.itemLongClickListener, coroutineScope)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -77,6 +77,7 @@ class InReplyToView @JvmOverloads constructor(
|
|||
retriever: ReplyPreviewRetriever,
|
||||
roomInformationData: MessageInformationData,
|
||||
movementMethod: MovementMethod?,
|
||||
itemLongClickListener: OnLongClickListener?,
|
||||
coroutineScope: CoroutineScope,
|
||||
force: Boolean = false) {
|
||||
if (newState == state && !force) {
|
||||
|
@ -91,6 +92,10 @@ class InReplyToView @JvmOverloads constructor(
|
|||
is PreviewReplyUiState.Error -> renderError(newState)
|
||||
is PreviewReplyUiState.InReplyTo -> renderReplyTo(newState, retriever, roomInformationData, movementMethod, coroutineScope)
|
||||
}
|
||||
|
||||
setOnLongClickListener(itemLongClickListener)
|
||||
// Somehow this one needs it additionally?
|
||||
views.replyTextView.setOnLongClickListener(itemLongClickListener)
|
||||
}
|
||||
|
||||
override fun onClick(v: View?) {
|
||||
|
|
Loading…
Add table
Reference in a new issue