summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorflofriday <flohacksfriday@gmail.com>2024-06-30 11:18:44 +0200
committerGitHub <noreply@github.com>2024-06-30 11:18:44 +0200
commite51b0a36950d54705c1de5d511d66efb246dace4 (patch)
tree3907c82c0900ab15e7ca12edd9faa6b113dd1d93
parent52117f35ac94b05d612fd402d47a76fbe4ce9c68 (diff)
downloadAntennaPod-e51b0a36950d54705c1de5d511d66efb246dace4.zip
Fix useless refresh on welcome home screen (#7268)
If the user hasn't subscribed to any podcasts a welcome segment is shown on the homescreen. However, the scrollview with a refresh below was still there which was not only useless but could trigger an refresh at the wrong position and also tint the app bar.
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/home/HomeFragment.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/src/main/java/de/danoeh/antennapod/ui/screen/home/HomeFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/HomeFragment.java
index 9b10031b6..03a61b687 100644
--- a/app/src/main/java/de/danoeh/antennapod/ui/screen/home/HomeFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/HomeFragment.java
@@ -184,6 +184,10 @@ public class HomeFragment extends Fragment implements Toolbar.OnMenuItemClickLis
.subscribe(numEpisodes -> {
viewBinding.welcomeContainer.setVisibility(numEpisodes == 0 ? View.VISIBLE : View.GONE);
viewBinding.homeContainer.setVisibility(numEpisodes == 0 ? View.GONE : View.VISIBLE);
+ viewBinding.swipeRefresh.setVisibility(numEpisodes == 0 ? View.GONE : View.VISIBLE);
+ if (numEpisodes == 0) {
+ viewBinding.homeScrollView.setScrollY(0);
+ }
}, error -> Log.e(TAG, Log.getStackTraceString(error)));
}