diff --git a/app/src/main/java/com/gh/gamecenter/gamedetail/rating/RatingReplyAdapter.kt b/app/src/main/java/com/gh/gamecenter/gamedetail/rating/RatingReplyAdapter.kt index bf0c4ea099..04a22ee255 100644 --- a/app/src/main/java/com/gh/gamecenter/gamedetail/rating/RatingReplyAdapter.kt +++ b/app/src/main/java/com/gh/gamecenter/gamedetail/rating/RatingReplyAdapter.kt @@ -273,10 +273,6 @@ class RatingReplyAdapter( likeCountTv.setDrawableStart(R.drawable.comment_vote_unselect) } likeCountTv.text = if (replyEntity.vote > 0) NumberUtils.transSimpleCount(replyEntity.vote) else "" - contentTv.setTextWithHighlightedTextWrappedInsideWrapper( - text = replyEntity.content, - copyClickedText = true - ) userIconIv.display( replyEntity.user.border, replyEntity.user.icon, @@ -292,6 +288,7 @@ class RatingReplyAdapter( badgeTv.visibility = View.GONE } val parent = replyEntity.parent + var contentCharSequence: CharSequence = replyEntity.content if (parent != null) { val prefix = "回复" val colon = " :" @@ -321,14 +318,17 @@ class RatingReplyAdapter( R.color.text_title ).build() - contentTv.text = SpannableStringBuilder() + contentCharSequence = SpannableStringBuilder() .append(prefixSpan) .append(parentUserNameSpan) .append(colonSpan) .append(replyEntity.content) - } else { - contentTv.text = replyEntity.content } + + contentTv.setTextWithHighlightedTextWrappedInsideWrapper( + text = contentCharSequence, + copyClickedText = true + ) badgeIv.setOnClickListener { DialogUtils.showViewBadgeDialog(mContext, replyEntity.user.badge, object : ConfirmListener { override fun onConfirm() {