Fix dummy list items crashing Android 9

This commit is contained in:
ByteHamster 2022-12-04 18:27:51 +01:00
parent 4513711981
commit 742f6f3e8a
2 changed files with 2 additions and 4 deletions

View File

@ -11,7 +11,6 @@ import de.danoeh.antennapod.activity.MainActivity;
import de.danoeh.antennapod.model.feed.Feed;
import de.danoeh.antennapod.fragment.FeedItemlistFragment;
import de.danoeh.antennapod.ui.common.SquareImageView;
import de.danoeh.antennapod.ui.common.ThemeUtils;
import java.lang.ref.WeakReference;
import java.util.ArrayList;
@ -48,8 +47,7 @@ public class HorizontalFeedListAdapter extends RecyclerView.Adapter<HorizontalFe
if (position >= data.size()) {
holder.itemView.setAlpha(0.1f);
Glide.with(mainActivityRef.get()).clear(holder.imageView);
holder.imageView.setImageResource(
ThemeUtils.getDrawableFromAttr(mainActivityRef.get(), android.R.attr.textColorSecondary));
holder.imageView.setImageResource(R.color.medium_gray);
return;
}

View File

@ -219,7 +219,7 @@ public class EpisodeItemViewHolder extends RecyclerView.ViewHolder {
placeholder.setText("");
if (coverHolder.getVisibility() == View.VISIBLE) {
new CoverLoader(activity)
.withResource(ThemeUtils.getDrawableFromAttr(activity, android.R.attr.textColorSecondary))
.withResource(R.color.medium_gray)
.withPlaceholderView(placeholder)
.withCoverView(cover)
.load();