-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Local feeds: add sort option for file name #5629
Local feeds: add sort option for file name #5629
Conversation
Merge branch 'develop' of github.com:AntennaPod/ into sb_add_sort_option_for_file_name
Didn't notice those until I created this PR and Github helpfully showed previous failures from the old PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for working on this! I have another round of feedback :)
app/src/main/java/de/danoeh/antennapod/dialog/IntraFeedSortDialog.java
Outdated
Show resolved
Hide resolved
app/src/main/java/de/danoeh/antennapod/dialog/IntraFeedSortDialog.java
Outdated
Show resolved
Hide resolved
app/src/main/java/de/danoeh/antennapod/dialog/IntraFeedSortDialog.java
Outdated
Show resolved
Hide resolved
app/src/main/java/de/danoeh/antennapod/dialog/IntraFeedSortDialog.java
Outdated
Show resolved
Hide resolved
Thanks for the great feedback @ByteHamster, I've made the changes requested and just have one question on preference (above). Happy to make any other changes / conform to style as requested! |
@@ -90,6 +98,11 @@ private static int duration(@Nullable FeedItem item) { | |||
return (item != null && item.getMedia() != null) ? item.getMedia().getDuration() : 0; | |||
} | |||
|
|||
@NonNull | |||
private static String itemLink(@Nullable FeedItem item) { | |||
return (item != null && item.getLink() != null) ? item.getLink() : ""; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it would make sense to convert it to lower case. Otherwise, "Bxxx" will be shown before "axxx".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good call @ByteHamster, I've made the change and tested it. I also took the liberty to modify the syntax in the switch-case to match the rest of the cases. I was a bit apprehensive to change things that are "not mine" but getting more comfortable doing the sensible thing. Thanks for all the patient coaching.
Default sort when first adding local feed:
Let me know if there are other changes. Cheers!
app/src/main/java/de/danoeh/antennapod/dialog/IntraFeedSortDialog.java
Outdated
Show resolved
Hide resolved
Thanks! Will be released in AntennaPod 2.5.0 |
Background
This PR adds the ability to sort local files by filename as described and discussed in PR #4610. I've refactored the code written by @widlok based on the feedback from @ByteHamster. I brought in @widlok 's commits as is to ensure history and credit is maintained but as addressed in the previous PRs his commits do not have an email associated, and I wasn't able to find one on their profile. If their email is known, I'm happy to do an interactive rebase and add them author on commits prior to refactor.
Closes
Closes #4597 Local feeds: add sort option for file name
Testing