From 4a5e67208662acc95bd9ffd34bebaca76bf68b0e Mon Sep 17 00:00:00 2001 From: Yuichiro Kinoshita Date: Thu, 9 Nov 2023 12:46:50 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20ellipsize=E3=81=8C=E3=81=86=E3=81=BE?= =?UTF-8?q?=E3=81=8F=E5=8B=95=E4=BD=9C=E3=81=97=E3=81=AA=E3=81=84=E5=95=8F?= =?UTF-8?q?=E9=A1=8C=E3=82=92=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../milktea/common_android_ui/user/UserTextHelper.kt | 5 ++--- .../milktea/note/timeline/TimelineListAdapterViewHolders.kt | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/modules/common_android_ui/src/main/java/net/pantasystem/milktea/common_android_ui/user/UserTextHelper.kt b/modules/common_android_ui/src/main/java/net/pantasystem/milktea/common_android_ui/user/UserTextHelper.kt index 21a022bc3a..9fb93ab7ff 100644 --- a/modules/common_android_ui/src/main/java/net/pantasystem/milktea/common_android_ui/user/UserTextHelper.kt +++ b/modules/common_android_ui/src/main/java/net/pantasystem/milktea/common_android_ui/user/UserTextHelper.kt @@ -1,6 +1,5 @@ package net.pantasystem.milktea.common_android_ui.user -import android.text.SpannableString import android.view.View import android.widget.TextView import androidx.databinding.BindingAdapter @@ -69,8 +68,8 @@ object UserTextHelper { } userName?.let { userName.setText( - SpannableString.valueOf(user.displayUserName), - TextView.BufferType.SPANNABLE, + user.displayUserName, + TextView.BufferType.NORMAL ) } } diff --git a/modules/features/note/src/main/java/net/pantasystem/milktea/note/timeline/TimelineListAdapterViewHolders.kt b/modules/features/note/src/main/java/net/pantasystem/milktea/note/timeline/TimelineListAdapterViewHolders.kt index ef03e278e3..cd8c807cd9 100644 --- a/modules/features/note/src/main/java/net/pantasystem/milktea/note/timeline/TimelineListAdapterViewHolders.kt +++ b/modules/features/note/src/main/java/net/pantasystem/milktea/note/timeline/TimelineListAdapterViewHolders.kt @@ -199,6 +199,6 @@ class HasReplyToNoteViewHolder( private val spannableFactory = object : Spannable.Factory() { override fun newSpannable(source: CharSequence?): Spannable { - return (source as? Spannable?) ?: SpannableString.valueOf(source) + return (source as? Spannable?) ?: SpannableString(source) } } \ No newline at end of file