cleaning / review

This commit is contained in:
Valere 2019-07-22 23:34:40 +02:00
parent 36af8a6a9f
commit c58328f94e
3 changed files with 5 additions and 6 deletions

View File

@ -5,7 +5,7 @@ Features:
-

Improvements:
-
- UI for pending edits (#193)

Other changes:
-

View File

@ -164,8 +164,7 @@ abstract class AbsMessageItem<H : AbsMessageItem.Holder> : BaseEventItem<H>() {

protected fun renderSendState(root: View, textView: TextView?) {
root.isClickable = informationData.sendState.isSent()
val state = SendState.UNSENT.takeIf { informationData.hasPendingEdits }
?: informationData.sendState
val state = if (informationData.hasPendingEdits) SendState.UNSENT else informationData.sendState
textView?.setTextColor(colorProvider.getMessageTextColor(state))
}


View File

@ -30,9 +30,9 @@ data class MessageInformationData(
val memberName: CharSequence? = null,
val showInformation: Boolean = true,
/*List of reactions (emoji,count,isSelected)*/
var orderedReactionList: List<ReactionInfoData>? = null,
var hasBeenEdited: Boolean = false,
var hasPendingEdits: Boolean = false
val orderedReactionList: List<ReactionInfoData>? = null,
val hasBeenEdited: Boolean = false,
val hasPendingEdits: Boolean = false
) : Parcelable