Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8a3ea4df authored by cketti's avatar cketti
Browse files

Clean up content description of message list items

parent 47469223
Loading
Loading
Loading
Loading
+8 −7
Original line number Original line Diff line number Diff line
@@ -409,15 +409,16 @@ class MessageListAdapter internal constructor(


            holder.subject.typeface = Typeface.create(holder.subject.typeface, maybeBoldTypeface)
            holder.subject.typeface = Typeface.create(holder.subject.typeface, maybeBoldTypeface)
            holder.subject.setTextColor(textColor)
            holder.subject.setTextColor(textColor)
            if (appearance.senderAboveSubject) {

                holder.subject.text = displayName
            val firstLineText = if (appearance.senderAboveSubject) displayName else subject
            holder.subject.text = firstLineText

            holder.subject.contentDescription = if (isRead) {
                null
            } else {
            } else {
                holder.subject.text = subject
                res.getString(R.string.message_list_content_description_unread_prefix, firstLineText)
            }
            if (!isRead) {
                holder.subject.contentDescription =
                    "${res.getString(R.string.unread_mail)} ${holder.subject.text}"
            }
            }

            holder.date.typeface = Typeface.create(holder.date.typeface, maybeBoldTypeface)
            holder.date.typeface = Typeface.create(holder.date.typeface, maybeBoldTypeface)
            holder.date.setTextColor(textColor)
            holder.date.setTextColor(textColor)
            holder.date.text = displayDate
            holder.date.text = displayDate
+2 −1
Original line number Original line Diff line number Diff line
@@ -1342,5 +1342,6 @@ You can keep this message and use it as a backup for your secret key. If you wan
    <!-- Might be displayed in a notification when deleting an account (in the background) -->
    <!-- Might be displayed in a notification when deleting an account (in the background) -->
    <string name="background_work_notification_remove_account">Removing account…</string>
    <string name="background_work_notification_remove_account">Removing account…</string>


    <string name="unread_mail">Unread mail</string>
    <!-- For unread messages the first line of a message list item is modified by this to improve the experience for people with screen readers. -->
    <string name="message_list_content_description_unread_prefix">unread, %s</string>
</resources>
</resources>