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

Unverified Commit 667487db authored by Wolf-Martell Montwé's avatar Wolf-Martell Montwé
Browse files

Remove messageListUnreadTextColor and messageListReadTextColor attributes

parent 04389085
Loading
Loading
Loading
Loading
+0 −6
Original line number Diff line number Diff line
@@ -54,8 +54,6 @@ class MessageListAdapter internal constructor(
    private val answeredIcon: Drawable = ResourcesCompat.getDrawable(res, Icons.Outlined.Reply, theme)!!
    private val forwardedAnsweredIcon: Drawable =
        ResourcesCompat.getDrawable(res, Icons.Outlined.CompareArrows, theme)!!
    private val unreadTextColor: Int = theme.resolveColorAttribute(R.attr.messageListUnreadTextColor)
    private val readTextColor: Int = theme.resolveColorAttribute(R.attr.messageListReadTextColor)
    private val activeItemBackgroundColor: Int = theme.resolveColorAttribute(
        colorAttrId = R.attr.messageListActiveItemBackgroundColor,
        alphaFractionAttrId = R.attr.messageListActiveItemBackgroundAlphaFraction,
@@ -373,7 +371,6 @@ class MessageListAdapter internal constructor(
        }

        with(messageListItem) {
            val textColor = if (isRead) readTextColor else unreadTextColor
            val maybeBoldTypeface = if (isRead) Typeface.NORMAL else Typeface.BOLD
            val displayDate = relativeDateTimeFormatter.formatDate(messageDate)
            val displayThreadCount = if (appearance.showingThreadedList) threadCount else 0
@@ -407,13 +404,11 @@ class MessageListAdapter internal constructor(
                    messageStringBuilder.append(" – ").append(preview)
                }
            }
            holder.preview.setTextColor(textColor)
            holder.preview.setText(messageStringBuilder, TextView.BufferType.SPANNABLE)

            formatPreviewText(holder.preview, beforePreviewText, isRead)

            holder.subject.typeface = Typeface.create(holder.subject.typeface, maybeBoldTypeface)
            holder.subject.setTextColor(textColor)

            val firstLineText = if (appearance.senderAboveSubject) displayName else subject
            holder.subject.text = firstLineText
@@ -425,7 +420,6 @@ class MessageListAdapter internal constructor(
            }

            holder.date.typeface = Typeface.create(holder.date.typeface, maybeBoldTypeface)
            holder.date.setTextColor(textColor)
            holder.date.text = displayDate
            holder.attachment.isVisible = hasAttachments

+1 −2
Original line number Diff line number Diff line
@@ -100,8 +100,7 @@
        app:layout_constraintHorizontal_chainStyle="packed"
        app:layout_constraintStart_toEndOf="@+id/status"
        app:layout_constraintTop_toTopOf="@+id/top_guideline"
        tools:text="Subject"
        tools:textColor="?attr/messageListReadTextColor" />
        tools:text="Subject" />

    <TextView
        android:id="@+id/thread_count"
+0 −2
Original line number Diff line number Diff line
@@ -12,8 +12,6 @@
        <attr name="messageListActiveItemBackgroundColor" format="reference|color"/>
        <attr name="messageListActiveItemBackgroundAlphaFraction" format="fraction"/>
        <attr name="messageListActiveItemBackgroundAlphaBackground" format="reference|color"/>
        <attr name="messageListUnreadTextColor" format="reference|color"/>
        <attr name="messageListReadTextColor" format="reference|color"/>
        <attr name="messageListSwipeSelectColor" format="reference|color"/>
        <attr name="messageListSwipeToggleReadColor" format="reference|color"/>
        <attr name="messageListSwipeToggleStarColor" format="reference|color"/>
+1 −4
Original line number Diff line number Diff line
@@ -78,8 +78,6 @@
        <item name="messageListActiveItemBackgroundColor">?attr/colorSecondaryVariant</item>
        <item name="messageListActiveItemBackgroundAlphaFraction">60%</item>
        <item name="messageListActiveItemBackgroundAlphaBackground">?attr/colorSurface</item>
        <item name="messageListUnreadTextColor">#dd000000</item>
        <item name="messageListReadTextColor">#ff444444</item>

        <item name="messageListSwipeSelectColor">@color/material_blue_600</item>
        <item name="messageListSwipeToggleReadColor">@color/material_blue_600</item>
@@ -179,6 +177,7 @@

        <item name="textColorPrimaryRecipientDropdown">@android:color/primary_text_dark</item>
        <item name="textColorSecondaryRecipientDropdown">@android:color/secondary_text_dark</item>

        <item name="messageListRegularItemBackgroundColor">?android:attr/windowBackground</item>
        <item name="messageListReadItemBackgroundColor">?attr/messageListRegularItemBackgroundColor</item>
        <item name="messageListUnreadItemBackgroundColor">#ff505050</item>
@@ -186,8 +185,6 @@
        <item name="messageListActiveItemBackgroundColor">?attr/colorSecondaryVariant</item>
        <item name="messageListActiveItemBackgroundAlphaFraction">50%</item>
        <item name="messageListActiveItemBackgroundAlphaBackground">?attr/colorSurface</item>
        <item name="messageListUnreadTextColor">#ffffffff</item>
        <item name="messageListReadTextColor">#ffaaaaaa</item>

        <item name="messageListSwipeSelectColor">@color/material_blue_700</item>
        <item name="messageListSwipeToggleReadColor">@color/material_blue_700</item>