summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--app/src/main/java/de/danoeh/antennapod/fragment/FeedItemlistFragment.java7
-rw-r--r--core/src/main/java/de/danoeh/antennapod/core/service/download/DownloadRequest.java3
-rw-r--r--ui/i18n/src/main/res/values/strings.xml1
-rw-r--r--ui/statistics/build.gradle2
-rw-r--r--ui/statistics/src/main/res/layout/feed_statistics.xml15
5 files changed, 20 insertions, 8 deletions
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/FeedItemlistFragment.java b/app/src/main/java/de/danoeh/antennapod/fragment/FeedItemlistFragment.java
index bb20cb4bc..fa2ed61ce 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/FeedItemlistFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/fragment/FeedItemlistFragment.java
@@ -163,8 +163,11 @@ public class FeedItemlistFragment extends Fragment implements AdapterView.OnItem
public void onScrolled(@NonNull RecyclerView view, int deltaX, int deltaY) {
super.onScrolled(view, deltaX, deltaY);
boolean hasMorePages = feed != null && feed.isPaged() && feed.getNextPageLink() != null;
- nextPageLoader.getRoot().setVisibility(
- (viewBinding.recyclerView.isScrolledToBottom() && hasMorePages) ? View.VISIBLE : View.GONE);
+ boolean pageLoaderVisible = viewBinding.recyclerView.isScrolledToBottom() && hasMorePages;
+ nextPageLoader.getRoot().setVisibility(pageLoaderVisible ? View.VISIBLE : View.GONE);
+ viewBinding.recyclerView.setPadding(
+ viewBinding.recyclerView.getPaddingLeft(), 0, viewBinding.recyclerView.getPaddingRight(),
+ pageLoaderVisible ? nextPageLoader.getRoot().getMeasuredHeight() : 0);
}
});
diff --git a/core/src/main/java/de/danoeh/antennapod/core/service/download/DownloadRequest.java b/core/src/main/java/de/danoeh/antennapod/core/service/download/DownloadRequest.java
index fc708ef6a..c085bc007 100644
--- a/core/src/main/java/de/danoeh/antennapod/core/service/download/DownloadRequest.java
+++ b/core/src/main/java/de/danoeh/antennapod/core/service/download/DownloadRequest.java
@@ -271,7 +271,7 @@ public class DownloadRequest implements Parcelable {
private boolean deleteOnFailure = false;
private final long feedfileId;
private final int feedfileType;
- private Bundle arguments = new Bundle();
+ private final Bundle arguments = new Bundle();
private boolean initiatedByUser = true;
public Builder(@NonNull String destination, @NonNull FeedMedia media) {
@@ -288,6 +288,7 @@ public class DownloadRequest implements Parcelable {
this.title = feed.getHumanReadableIdentifier();
this.feedfileId = feed.getId();
this.feedfileType = feed.getTypeAsInt();
+ arguments.putInt(REQUEST_ARG_PAGE_NR, feed.getPageNr());
}
public Builder withInitiatedByUser(boolean initiatedByUser) {
diff --git a/ui/i18n/src/main/res/values/strings.xml b/ui/i18n/src/main/res/values/strings.xml
index 0073eebf5..aa7fa18d4 100644
--- a/ui/i18n/src/main/res/values/strings.xml
+++ b/ui/i18n/src/main/res/values/strings.xml
@@ -708,6 +708,7 @@
<string name="statistics_space_used">Space used:</string>
<string name="statistics_episodes_started_total">Episodes started/total:</string>
<string name="statistics_view_all">View for all podcasts ยป</string>
+ <string name="wait_icon" translatable="false">{fa-spinner}</string>
<!-- AntennaPodSP -->
<string name="sp_apps_importing_feeds_msg">Importing subscriptions from single-purpose apps&#8230;</string>
diff --git a/ui/statistics/build.gradle b/ui/statistics/build.gradle
index cca840989..53ebd5acc 100644
--- a/ui/statistics/build.gradle
+++ b/ui/statistics/build.gradle
@@ -30,4 +30,6 @@ dependencies {
annotationProcessor "com.github.bumptech.glide:compiler:$glideVersion"
implementation "io.reactivex.rxjava2:rxandroid:$rxAndroidVersion"
implementation "io.reactivex.rxjava2:rxjava:$rxJavaVersion"
+ implementation "com.joanzapata.iconify:android-iconify-fontawesome:$iconifyVersion"
+ implementation "com.joanzapata.iconify:android-iconify-material:$iconifyVersion"
}
diff --git a/ui/statistics/src/main/res/layout/feed_statistics.xml b/ui/statistics/src/main/res/layout/feed_statistics.xml
index 7897a7d5f..6b9a7fa4c 100644
--- a/ui/statistics/src/main/res/layout/feed_statistics.xml
+++ b/ui/statistics/src/main/res/layout/feed_statistics.xml
@@ -13,12 +13,13 @@
android:layout_height="wrap_content"
android:text="@string/statistics_episodes_started_total" />
- <TextView
+ <com.joanzapata.iconify.widget.IconTextView
android:id="@+id/startedTotalLabel"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="8dp"
android:layout_marginStart="8dp"
+ android:text="@string/wait_icon"
tools:text="0 / 0" />
</TableRow>
@@ -30,12 +31,13 @@
android:layout_height="wrap_content"
android:text="@string/statistics_time_played" />
- <TextView
+ <com.joanzapata.iconify.widget.IconTextView
android:id="@+id/timePlayedLabel"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="8dp"
android:layout_marginStart="8dp"
+ android:text="@string/wait_icon"
tools:text="0 min" />
</TableRow>
@@ -48,12 +50,13 @@
android:layout_height="wrap_content"
android:text="@string/statistics_total_duration" />
- <TextView
+ <com.joanzapata.iconify.widget.IconTextView
android:id="@+id/totalDurationLabel"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="8dp"
android:layout_marginStart="8dp"
+ android:text="@string/wait_icon"
tools:text="0 min" />
</TableRow>
@@ -65,12 +68,13 @@
android:layout_height="wrap_content"
android:text="@string/statistics_episodes_on_device" />
- <TextView
+ <com.joanzapata.iconify.widget.IconTextView
android:id="@+id/onDeviceLabel"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="8dp"
android:layout_marginStart="8dp"
+ android:text="@string/wait_icon"
tools:text="0" />
</TableRow>
@@ -82,12 +86,13 @@
android:layout_height="wrap_content"
android:text="@string/statistics_space_used" />
- <TextView
+ <com.joanzapata.iconify.widget.IconTextView
android:id="@+id/spaceUsedLabel"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="8dp"
android:layout_marginStart="8dp"
+ android:text="@string/wait_icon"
tools:text="0 MB" />
</TableRow>