summaryrefslogtreecommitdiff
path: root/app/src/main/java/de/danoeh/antennapod/adapter/SubscriptionsRecyclerAdapter.java
diff options
context:
space:
mode:
authorByteHamster <ByteHamster@users.noreply.github.com>2023-10-15 10:26:13 +0200
committerGitHub <noreply@github.com>2023-10-15 10:26:13 +0200
commit0efa91a0b193bb902716b74d14fbaf6a53bc6251 (patch)
tree461f21b4f6fed079f76e812f1215f92b56de3914 /app/src/main/java/de/danoeh/antennapod/adapter/SubscriptionsRecyclerAdapter.java
parent475e0f51280c530754188d48342d92dca4da2a7b (diff)
downloadAntennaPod-0efa91a0b193bb902716b74d14fbaf6a53bc6251.zip
Add error icon on subscriptions screen (#6679)
Diffstat (limited to 'app/src/main/java/de/danoeh/antennapod/adapter/SubscriptionsRecyclerAdapter.java')
-rw-r--r--app/src/main/java/de/danoeh/antennapod/adapter/SubscriptionsRecyclerAdapter.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/SubscriptionsRecyclerAdapter.java b/app/src/main/java/de/danoeh/antennapod/adapter/SubscriptionsRecyclerAdapter.java
index bfa37b600..284f3e468 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/SubscriptionsRecyclerAdapter.java
+++ b/app/src/main/java/de/danoeh/antennapod/adapter/SubscriptionsRecyclerAdapter.java
@@ -216,6 +216,7 @@ public class SubscriptionsRecyclerAdapter extends SelectableAdapter<Subscription
private final FrameLayout selectView;
private final CheckBox selectCheckbox;
private final CardView card;
+ private final View errorIcon;
public SubscriptionViewHolder(@NonNull View itemView) {
super(itemView);
@@ -226,6 +227,7 @@ public class SubscriptionsRecyclerAdapter extends SelectableAdapter<Subscription
selectView = itemView.findViewById(R.id.selectContainer);
selectCheckbox = itemView.findViewById(R.id.selectCheckBox);
card = itemView.findViewById(R.id.outerContainer);
+ errorIcon = itemView.findViewById(R.id.errorIcon);
}
public void bind(NavDrawerData.DrawerItem drawerItem) {
@@ -249,9 +251,11 @@ public class SubscriptionsRecyclerAdapter extends SelectableAdapter<Subscription
textAndImageCombined = feed.isLocalFeed() && feed.getImageUrl() != null
&& feed.getImageUrl().startsWith(Feed.PREFIX_GENERATIVE_COVER);
coverLoader.withUri(feed.getImageUrl());
+ errorIcon.setVisibility(feed.hasLastUpdateFailed() ? View.VISIBLE : View.GONE);
} else {
textAndImageCombined = true;
coverLoader.withResource(R.drawable.ic_tag);
+ errorIcon.setVisibility(View.GONE);
}
if (UserPreferences.shouldShowSubscriptionTitle()) {
// No need for fallback title when already showing title