mirror of
https://github.com/nextcloud/talk-android
synced 2025-03-06 22:29:09 +00:00
Merge pull request #3046 from nextcloud/issue-3026
Changed reply length to have a max of 250 characters
This commit is contained in:
commit
f421788480
@ -189,7 +189,7 @@ class IncomingTextMessageViewHolder(itemView: View, payload: Any) :
|
||||
} else {
|
||||
parentChatMessage.actorDisplayName
|
||||
}
|
||||
binding.messageQuote.quotedMessage.text = parentChatMessage.text
|
||||
binding.messageQuote.quotedMessage.text = DisplayUtils.ellipsize(parentChatMessage.text, MAX_REPLY_LENGTH)
|
||||
|
||||
if (parentChatMessage.actorId?.equals(message.activeUser!!.userId) == true) {
|
||||
viewThemeUtils.platform.colorViewBackground(binding.messageQuote.quoteColoredView)
|
||||
@ -262,5 +262,6 @@ class IncomingTextMessageViewHolder(itemView: View, payload: Any) :
|
||||
|
||||
companion object {
|
||||
const val TEXT_SIZE_MULTIPLIER = 2.5
|
||||
const val MAX_REPLY_LENGTH = 250
|
||||
}
|
||||
}
|
||||
|
@ -164,7 +164,7 @@ class OutcomingTextMessageViewHolder(itemView: View) : OutcomingTextMessageViewH
|
||||
}
|
||||
binding.messageQuote.quotedMessageAuthor.text = parentChatMessage.actorDisplayName
|
||||
?: context!!.getText(R.string.nc_nick_guest)
|
||||
binding.messageQuote.quotedMessage.text = parentChatMessage.text
|
||||
binding.messageQuote.quotedMessage.text = DisplayUtils.ellipsize(parentChatMessage.text, MAX_REPLY_LENGTH)
|
||||
|
||||
binding.messageQuote.quotedMessageAuthor.setTextColor(textColor)
|
||||
binding.messageQuote.quotedMessage.setTextColor(textColor)
|
||||
@ -226,5 +226,6 @@ class OutcomingTextMessageViewHolder(itemView: View) : OutcomingTextMessageViewH
|
||||
|
||||
companion object {
|
||||
const val TEXT_SIZE_MULTIPLIER = 2.5
|
||||
const val MAX_REPLY_LENGTH = 250
|
||||
}
|
||||
}
|
||||
|
@ -85,7 +85,9 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@id/quotedMessageImage"
|
||||
android:layout_alignStart="@id/quotedMessageAuthor"
|
||||
android:ellipsize="end"
|
||||
android:lineSpacingMultiplier="1.2"
|
||||
android:maxLines="4"
|
||||
android:textAlignment="viewStart"
|
||||
android:textColor="@color/high_emphasis_text"
|
||||
android:textIsSelectable="false"
|
||||
|
Loading…
Reference in New Issue
Block a user