From 468f8f1b14af483b33daafac87c9513b39d9e1cc Mon Sep 17 00:00:00 2001 From: Conny Duck Date: Mon, 2 Jan 2023 14:36:07 +0100 Subject: [PATCH] use MaterialColors.getColor instead of ThemeUtils (fixes build) --- .../tusky/components/viewthread/edits/ViewEditsAdapter.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/com/keylesspalace/tusky/components/viewthread/edits/ViewEditsAdapter.kt b/app/src/main/java/com/keylesspalace/tusky/components/viewthread/edits/ViewEditsAdapter.kt index 204064f7..08c4a65f 100644 --- a/app/src/main/java/com/keylesspalace/tusky/components/viewthread/edits/ViewEditsAdapter.kt +++ b/app/src/main/java/com/keylesspalace/tusky/components/viewthread/edits/ViewEditsAdapter.kt @@ -8,6 +8,7 @@ import android.view.ViewGroup import androidx.recyclerview.widget.LinearLayoutManager import androidx.recyclerview.widget.RecyclerView import com.bumptech.glide.Glide +import com.google.android.material.color.MaterialColors import com.keylesspalace.tusky.R import com.keylesspalace.tusky.adapter.PollAdapter import com.keylesspalace.tusky.adapter.PollAdapter.Companion.MULTIPLE @@ -18,7 +19,6 @@ import com.keylesspalace.tusky.entity.StatusEdit import com.keylesspalace.tusky.interfaces.LinkListener import com.keylesspalace.tusky.util.AbsoluteTimeFormatter import com.keylesspalace.tusky.util.BindingHolder -import com.keylesspalace.tusky.util.ThemeUtils import com.keylesspalace.tusky.util.aspectRatios import com.keylesspalace.tusky.util.decodeBlurHash import com.keylesspalace.tusky.util.emojify @@ -147,7 +147,7 @@ class ViewEditsAdapter( val placeholder: Drawable = if (blurhash != null && useBlurhash) { decodeBlurHash(context, blurhash) } else { - ColorDrawable(ThemeUtils.getColor(context, R.attr.colorBackgroundAccent)) + ColorDrawable(MaterialColors.getColor(imageView, R.attr.colorBackgroundAccent)) } if (attachment.previewUrl.isNullOrEmpty()) {