|
@@ -155,7 +155,7 @@ class MessageActionsDialog(
|
|
|
if (CapabilitiesUtil.hasSpreedFeatureCapability(user, "reactions") &&
|
|
|
Conversation.ConversationReadOnlyState.CONVERSATION_READ_ONLY !=
|
|
|
currentConversation?.conversationReadOnlyState &&
|
|
|
- !(message.isCommandMessage || message.isDeletedCommentMessage || message.isDeleted)
|
|
|
+ isReactableMessageType(message)
|
|
|
) {
|
|
|
checkAndSetEmojiSelfReaction(dialogMessageActionsBinding.emojiThumbsUp)
|
|
|
dialogMessageActionsBinding.emojiThumbsUp.setOnClickListener {
|
|
@@ -192,6 +192,10 @@ class MessageActionsDialog(
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ private fun isReactableMessageType(message: ChatMessage): Boolean {
|
|
|
+ return !(message.isCommandMessage || message.isDeletedCommentMessage || message.isDeleted)
|
|
|
+ }
|
|
|
+
|
|
|
private fun checkAndSetEmojiSelfReaction(emoji: EmojiTextView) {
|
|
|
if (emoji.text?.toString() != null && message.reactionsSelf?.contains(emoji.text?.toString()) == true) {
|
|
|
emoji.background = AppCompatResources.getDrawable(context, R.drawable.reaction_self_bottom_sheet_background)
|