Commit graph

1824 commits

Author SHA1 Message Date
Alexander Capehart
97e144058a
music: add playlist deletion dialog
Add a dialog that allows the user to confirm playlist deletion, instead
of it happening immediately.
2023-05-17 18:56:09 -06:00
Alexander Capehart
d1f9200bf9
list: unwind choiceviewholder
Unwind ChoiceViewHolder into specific impls.

Was not re-usable enough w/playlists in order to be reasonable.
2023-05-17 17:39:52 -06:00
Alexander Capehart
b2e899a211
search: add playlist results
Add playlist results to the search view.
2023-05-17 17:12:29 -06:00
Alexander Capehart
06885ba264
music: extend equality impls
Extend the music equals/hashCode implementations to take into account
the raw music.

This way, items that change in non-UID metadata are actually considered
different at runtime while UIDs can still persist the data in a stable
manner.
2023-05-17 16:11:26 -06:00
Alexander Capehart
d0a68353a7
music: simplify picker closing
Simplify picker closing navigation by avoiding weird communication via
state change and instead simply navigate twice from NewPlaylistDialog.

This is probably really stupid. But so is the other way.
2023-05-17 12:09:51 -06:00
Alexander Capehart
6cfb50a10f
detail: drop equality checks
Most of the list creation operations are O(1), and the stateflow
equality makes it not matter anyway.
2023-05-17 11:56:50 -06:00
Alexander Capehart
9c7e1d9fc2
image: differentiate different parent songs
Differentiate parents based on their song composition.

This way, it's less likely for an artist/genre/playlist image to get
"stuck" after a library change.
2023-05-17 11:12:26 -06:00
Alexander Capehart
dcc82608bd
music: add playlist deletion
Add basic playlist deletion flow.

No confirmation dialog yet, that will need to be implemented later.
2023-05-17 11:07:16 -06:00
Alexander Capehart
956b6fda2b
all: fix inspections
Fix miscellanious code inspections.
2023-05-14 09:59:08 -06:00
Alexander Capehart
d0444bb41d
detail: add duration indicator to playlist
Add a duration indicator alongside the song count in the playlist
detail header.
2023-05-13 20:05:04 -06:00
Alexander Capehart
949a9c879c
detail: improve playlist presentation
Improve playlist presentation in the detail views, especially when
it is empty.
2023-05-13 19:32:03 -06:00
Alexander Capehart
7435165929
music: add playlist addition
Implement playlist addition and it's UI flow.
2023-05-13 19:06:51 -06:00
Alexander Capehart
4fe91c25e3
music: streamline new playlist implementation
Make the implementation of the playlist creation dialog signifigantly
simpler by removing some aspects that don't really need implementation
yet.
2023-05-13 11:40:35 -06:00
Weblate (bot)
13709e3e8e
Translations update from Hosted Weblate (#418)
* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/uk/

* Translated using Weblate (Punjabi)

Currently translated at 100.0% (30 of 30 strings)

Translation: Auxio/Metadata
Translate-URL: https://hosted.weblate.org/projects/auxio/metadata/pa/

* Translated using Weblate (Hindi)

Currently translated at 16.4% (43 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/hi/

* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/uk/

* Translated using Weblate (Malayalam)

Currently translated at 100.0% (30 of 30 strings)

Translation: Auxio/Metadata
Translate-URL: https://hosted.weblate.org/projects/auxio/metadata/ml/

* Translated using Weblate (Hindi)

Currently translated at 100.0% (30 of 30 strings)

Translation: Auxio/Metadata
Translate-URL: https://hosted.weblate.org/projects/auxio/metadata/hi/

* Translated using Weblate (French)

Currently translated at 83.9% (219 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/fr/

* Added translation using Weblate (Persian)

* Translated using Weblate (Romanian)

Currently translated at 55.5% (145 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/ro/

* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/uk/

* Translated using Weblate (Croatian)

Currently translated at 100.0% (30 of 30 strings)

Translation: Auxio/Metadata
Translate-URL: https://hosted.weblate.org/projects/auxio/metadata/hr/

* Translated using Weblate (Turkish)

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/tr/

* Translated using Weblate (Persian)

Currently translated at 9.9% (26 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/fa/

* Translated using Weblate (Italian)

Currently translated at 99.6% (260 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/it/

* Translated using Weblate (Hindi)

Currently translated at 17.6% (46 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/hi/

* Translated using Weblate (Czech)

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/cs/

* Translated using Weblate (Malayalam)

Currently translated at 32.9% (86 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/ml/

* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/uk/

* Translated using Weblate (Czech)

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/cs/

* Translated using Weblate (Russian)

Currently translated at 100.0% (263 of 263 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/ru/

* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (263 of 263 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/uk/

* Translated using Weblate (Belarusian)

Currently translated at 100.0% (263 of 263 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/be/

* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (263 of 263 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/uk/

---------

Co-authored-by: BMN <weblate@yopmail.com>
Co-authored-by: ShareASmile <aapshergill@gmail.com>
Co-authored-by: Martin Derleth <contactmder@pm.me>
Co-authored-by: alex <hdhdhfhfbbffhhfhfjfjf@gmail.com>
Co-authored-by: Milo Ivir <mail@milotype.de>
Co-authored-by: Eren İnce <erenince@proton.me>
Co-authored-by: Alireza Najdshad <alirezanajdshad28@gmail.com>
Co-authored-by: atilluF <110931720+atilluF@users.noreply.github.com>
Co-authored-by: Projjal Moitra <moitraprojjal@disroot.org>
Co-authored-by: Fjuro <ifjuro@proton.me>
Co-authored-by: Raman <xysed@tutanota.com>
Co-authored-by: Макар Разин <makarrazin14@gmail.com>
2023-05-12 22:46:08 +00:00
Alexander Capehart
e71727e18c
actions: use jdk 17
Using it as of last commit.
2023-05-12 16:33:49 -06:00
Alexander Capehart
5bf5687ccf
build: update agp to 8.0.1 2023-05-12 16:30:18 -06:00
Alexander Capehart
e2104c58b8
music: clean up playlist name dialog
Cleanup the playlist naming dialog to have nicer UX/implementation.
2023-05-12 15:42:30 -06:00
Alexander Capehart
97705a37e4
music: remove uid tests
Remove Music.UID tests for now in favor of adding them to the main
datatype tests instead in the future.
2023-05-12 13:46:24 -06:00
Alexander Capehart
763061c352
music: automatically number new playlists
Automatically number new playlists, from Playlist 1, Playlist 2, etc.

This comes with the additional requirement that all playlists have
unique names.
2023-05-12 13:43:18 -06:00
Alexander Capehart
e01ea25d0b
music: add playlist naming flow
Add a real playlist naming dialog and UX flow.

This is a bit rough at the moment since theres a good amount of nuance
here. Should improve as the playlist implementation continues to grow
more fleshed out.
2023-05-12 10:39:56 -06:00
Alexander Capehart
7ba2b1bb41
music: strip articles from extremely short names
Strip articles from names that are longer than 2-4 characters, compared
the prior limit of 3-5.

Resolves #440.
2023-05-12 07:01:04 -06:00
Alexander Capehart
eb4adcc109
all: unwind picker abstraction
Unwind the picker abstraction into smaller dialog packages.

While this increases repetition, it will make the playlist dialog
implementations much less shoddy.
2023-05-11 16:21:04 -06:00
Alexander Capehart
e68cc4d620
build: update deps
Update a huge amount of dependencies. Forgot specifically what I
did.
2023-05-11 15:42:47 -06:00
Alexander Capehart
715739f005
playback: remove parent mediasession value
Is redundant now given that METADATA_KEY_DISPLAY_DESCRIPTION is used
now.
2023-05-11 15:11:25 -06:00
Alexander Capehart
43036cfd59
playback: fix notif not responding to settings
Fix an issue where changes in image settings would not cause the
notification to respond.
2023-05-11 15:10:35 -06:00
Alexander Capehart
a8691cf693
build: enable r8 full mode
Enable R8 full mode for the app.

Should shave off ~150kb.
2023-05-11 15:07:09 -06:00
Alexander Capehart
cb69400905
music: add playlist creation stub
Add a stub for creating a new playlist.

UX details are not worked out yet, so the functionality is still
extremely bare.
2023-05-11 13:16:45 -06:00
Alexander Capehart
a5176d6209
all: do not do work on static initialization
Try to lazily initialize certain static variables that do work (like
Regex) to speed up initialization time.
2023-05-11 13:10:47 -06:00
Alexander Capehart
c98ca8712f
music: re-add fallible async execution
Re-add the tryAsync wrapper function to the loading process to properly
handle music loading errors.

Turns out there is basically no other way to properly do this except for
the insane exception -> Result -> exception hack.
2023-05-11 12:57:43 -06:00
Alexander Capehart
aa24ea00ea
all: use sealed interface when possible
Use sealed interface instead of sealed class when no class features are
actually used by the code.
2023-05-11 12:36:58 -06:00
Alexander Capehart
4e5a3f7fe1
tests: fix failure
Fix some accidental regressions and unported mocks.
2023-05-11 12:25:20 -06:00
Alexander Capehart
b72f33a989
search: match file names case-insensitively
Not doing this lead to some inconsistent search results at points.

Resolves #437.
2023-05-11 12:21:58 -06:00
Alexander Capehart
c7b875376c
music: refactor name implementation
Refactor the music name implementation to do the following:
1. Unify normal and sort names under a single datatype
2. Handle arbitrary-length digit strings
3. Ignore puncutation regardless of the intelligent sort
configuration, as it is trivially localizable.

Resolves #423.

Co-authored by: ChatGPT-3.5
2023-05-11 12:19:39 -06:00
Alexander Capehart
ca349dea18
music: fix tests
Fix tests that weren't migated to media3.
2023-05-10 20:48:44 -06:00
Alexander Capehart
3daaadf8ea
all: disable media3 optin insanity
Forgot to do this in the prior commit. Again, nearly every use of
ExoPlayer by Auxio is considered "unsafe" and would fail the build
unless I slather it all in OptIn annotations or have a global lint.xml
file just sitting in the root directory.
2023-05-10 17:50:58 -06:00
Alexander Capehart
c1e4d0f10e
all: switch to media3
Move everything over to the media3 library instead of ExoPlayer.

Media3 is worse in every way. It labels half of ExoPlayer as "unsafe"
because it thinks that it's garbage uwu "helpful" abstractions are
perfectly servicable when in reality they are a pile of garbage filled
with insane performance issues, race conditions, and a seeming lack
of awareness to the sheer absurdity of android's media APIs. It is
absolutely horrible, but ExoPlayer will stop being maintained soon
and I will have to move over for further maintenance.
2023-05-10 17:47:31 -06:00
Alexander Capehart
c6c3816bfc
Merge branch 'master' into dev 2023-05-10 17:09:06 -06:00
Alexander Capehart
04ef09dd94
build: update deps
Time to catch up on dependency updates after working non-stop for a
month and a half.
2023-05-10 14:00:36 -06:00
Alexander Capehart
78d9f9f613
Merge pull request #425 from OxygenCobalt/3.0.5-cherrypick
Version 3.0.5
2023-04-17 00:03:14 +00:00
Alexander Capehart
d0f8291085
music: fix incorrect sort punct removal
Fix incorrect punctuation removal resulting in weird sorting behavior.
2023-04-16 18:01:32 -06:00
Alexander Capehart
e6b00b1025
build: bump to 3.0.5
Bump the version to 3.0.5.
2023-04-16 17:30:51 -06:00
Alexander Capehart
b031adabeb
music: correctly bubble exceptions
Correctly bubble failures in the music loading process.

Do it the easy way and simply map to a result, then backl to an
exception. I need to actually just make it fully bubble event
2023-04-16 17:29:21 -06:00
Alexander Capehart
89d599ae4e
widget: fix inconsistent cover corner radius
Somehow the line that makes the corner sizes consistent was lost.
2023-04-16 17:29:09 -06:00
Alexander Capehart
20feba024e
Merge pull request #419 from chrispalmeri/sorting
Updates to intelligent sorting
2023-04-15 17:46:55 -06:00
Alexander Capehart
0756726281
Merge pull request #419 from chrispalmeri/sorting
Updates to intelligent sorting
2023-04-15 13:03:00 -06:00
Chris Palmeri
6ac0cf358a
Use six digit sort name padding 2023-04-15 10:11:39 -05:00
Chris Palmeri
d04cd4ce4f
Refactor sort name changes 2023-04-15 10:05:15 -05:00
Chris Palmeri
b34462340a
Strip symbols and forget thousands separator 2023-04-12 23:33:16 -05:00
Chris Palmeri
7d8cdba6a9
Regex numbers and common thumb 2023-04-12 00:52:04 -05:00
Weblate (bot)
2e34933c86
Translations update from Hosted Weblate (#403)
* Update translation files

Updated by "Cleanup translation files" hook in Weblate.

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/

* Translated using Weblate (Czech)

Currently translated at 100.0% (260 of 260 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/cs/

* Translated using Weblate (German)

Currently translated at 100.0% (260 of 260 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/de/

* Translated using Weblate (Russian)

Currently translated at 100.0% (260 of 260 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/ru/

* Translated using Weblate (Lithuanian)

Currently translated at 100.0% (260 of 260 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/lt/

* Translated using Weblate (Belarusian)

Currently translated at 100.0% (260 of 260 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/be/

* Translated using Weblate (Czech)

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/cs/

* Translated using Weblate (German)

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/de/

* Translated using Weblate (Spanish)

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/es/

* Translated using Weblate (Korean)

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/ko/

* Translated using Weblate (Russian)

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/ru/

* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/uk/

* Translated using Weblate (Chinese (Simplified))

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/zh_Hans/

* Translated using Weblate (Belarusian)

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/be/

* Translated using Weblate (Lithuanian)

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/lt/

* Added translation using Weblate (Odia)

* Added translation using Weblate (Finnish)

* Translated using Weblate (Odia)

Currently translated at 0.7% (2 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/or/

* Translated using Weblate (Greek)

Currently translated at 45.5% (119 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/el/

* Translated using Weblate (Italian)

Currently translated at 99.6% (260 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/it/

* Translated using Weblate (Polish)

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/pl/

* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/uk/

* Translated using Weblate (Croatian)

Currently translated at 100.0% (30 of 30 strings)

Translation: Auxio/Metadata
Translate-URL: https://hosted.weblate.org/projects/auxio/metadata/hr/

* Translated using Weblate (Croatian)

Currently translated at 100.0% (261 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/hr/

* Translated using Weblate (Odia)

Currently translated at 1.9% (5 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/or/

* Translated using Weblate (Finnish)

Currently translated at 90.0% (235 of 261 strings)

Translation: Auxio/Strings
Translate-URL: https://hosted.weblate.org/projects/auxio/strings/fi/

---------

Co-authored-by: Fjuro <ifjuro@proton.me>
Co-authored-by: qwerty287 <ndev@web.de>
Co-authored-by: Макар Разин <makarrazin14@gmail.com>
Co-authored-by: Vaclovas Intas <vaclovas1999@gmail.com>
Co-authored-by: gallegonovato <fran-carro@hotmail.es>
Co-authored-by: Hoseok Seo <ddinghoya@gmail.com>
Co-authored-by: BMN <weblate@yopmail.com>
Co-authored-by: Eric <hamburger2048@users.noreply.hosted.weblate.org>
Co-authored-by: Jiri Grönroos <jiri.gronroos@iki.fi>
Co-authored-by: Subham Jena <subhamjena8465@gmail.com>
Co-authored-by: Ricardo Feleque <rnfeq869w@relay.firefox.com>
Co-authored-by: atilluF <atilluF@users.noreply.hosted.weblate.org>
Co-authored-by: Maciej Klupp <maciej.klupp@gmail.com>
Co-authored-by: Milo Ivir <mail@milotype.de>
2023-04-11 07:49:58 -06:00