Disable the ability to customize audio focus on Android 12 and up.
Android 12 automatically regulates audio streams even further than it
did in previous versions, to the point where the audio focus setting
no longer makes sense on that version. I may extend the removal to all
versions in the future.
Fix an issue where headset focus would restart playback unexpectedly.
At some point during the broadcast refactor, I accidentally switched
the values of CONNECTED and DISCONNECTED when handling
AudioManager.ACTION_HEADSET_PLUG. This resulted in playback starting
for no reason in some situations.
Use body typography in more places, reworking the letter spacing as to
make it more pleasent to use with the inter typeface.
This should hopefully be the last time I fret over typography.
Everything should line up in the way desired by M3.
Remove the elevation component from all toolbars and the bottom bar.
Material3 states that top and bottom app bars should not cast a drop
shadow. Auxio ignored this and used one anyway. This largely stemmed
from incorrect use of the AppBarLayout styles, which were mostly just
incorrect M2 styles with a new background plastered over. Fix this
by creating a new style that inherits the proper M3 styles and then
using that on all AppBarLayout instances in the app.
Do a couple things to the music models:
1. Make the genre field non-nullable. This is because I beleive I've
largely eliminated the genre bugs in previous versions and future ones
can be caught with a crash screen I plan to add.
2. Make the initial album grouping process use hashCode instead of a
pair of names. This just helps with loading speed in general, albeit I
am slightly worried that it may result in improper grouping if some
edge case appears.
Apply body typography in new places in the app.
For awhile, Body and Title typography were used interchangeably, as
they occupy the same text size range. This commit defines the Body
text as to be used for one-line widgets or tertiary widgets, while
the Title text is defined to be used for multi-line or heading widgets.
Fix an issue with M3SwitchPreference where the switch would not update
properly.
When reacing M3SwitchPreference, I wanted to make an optimization
regarding updating the switch to M3, so I decided to make the
preference check if they have already applied the switch, and then
ignore it if that's the case. However, I ended up forgetting that
ViewHolders tend to need to be re-bound, which resulted in this
optimization leading to inconsistent application of the M3 switches.
Fix this by removing that optimization.
Update the contribution information and templates.
The contribution information and templates were growing a bit stale,
given that they haven't gotten a refresh since ~1.3.0. This commit
reworks them to be more thorough and straightfoward.
Add a CHANGELOG document that keeps track of the past and current
release notes.
Making all of our releases rely on GitHub to keep track of them is not
really a good idea, so this document serves as a record of past release
changelogs just as a pre-caution. It also allows a live preview of the
next version whenever something is changed.
Improve the way track numbers are handled in the album detail view.
Previously, Auxio would show track numbers by simplying stringifying
the integer and then showing it in a TextView. This was problematic for
two reasons:
- Numerics from other languages like Arabic would not be respected
- Invalid track numbers [e.g 0] would be shown regardless of the
situation.
This commit fixes that by placing all track numbers through a format
string first, and showing a generic song icon instead of a number
whenever the track number is 0.
Completely rework the Context extensions for resources.
Previously, Auxio has used a strange hodge-podge of context extensions
and verbose code to get resources. Fix this by unifying most of the
resource accesses under a single, unified set of extensions. The only
ones excluded for now is the getString call, as that is used in far too
many places to effectively replace.
Re-add index correction, albeit with a new system that accomodates the
single queue mechanism.
The issue with using the previous queue mechanism for the single queue
was that it risked using the index of an incorrect duplicate song, as
the search would always start at index 0. Fix this by implementing a
sort of "wobbly" search that starts at the current index and moves back
and forth, checking the closest items first and the furthest items
last.
Add an option to force-reload the app.
Currently, Auxio will load music once and then never re-load it. This
is a really decision I made early on and now regret completely. The
only way to remedy this properly is to create an automatic rescanning
system, but that is a major technical undertaking that I want to save
for later.
Resolves#71.
Improve the russian translations for this app.
These translations were proposed by lisiczka43 with the following
rationale:
"[use] less literal translations, [use] shorter wording to fit into UI
elements, [correct] mistranslations, [improve] consistency of
terminolgy, [enforce] strict ё, [add] missing new strings"
Apparently the previous russian translations were quite Amateurish.
This should make them better.
Completely refactor the way music is grouped up into artists and
albums.
The issue with previous attempts at implementing better artist
management was the reliance on MediaStore IDs in many parts of the
program. Dumpster this by merging the hash and ID values into a
single field that is garunteed to be unique enough. This allows songs
to be adequately grouped into case-insensitive artists while also
deduplicating albums that may have been split my MediaStore due to
heterogeneous formats.
Resolves#66.
Move all duplicate checking to the album creation stage, adding a new
check for duplicate albums.
Album names can be similarly duplicated as artist names, most often
when one has an album consisting of multiple differing file formats.
This commit fixes that by grouping albums up by their ID as usual,
but then merging together albums that have the same (lowercase) album
name and (lowercase) artist name.
Use a proper composition of the "many" and "other" fields in the plural
fields of specific languages.
In the french/czech plural configuration, both "many" and "other" are
used for string fields. The lint does not make this obvious, so in
d7f34e6 I ended up switching the "other" field to "many". This resulted
in some devices on those languages crashing. To fix this, we define
the "many" and "other" fields with the same value to avoid a crash.
Resolves#69.
Re-add the inter typeface.
It's not good design to have two similar typefaces, so I may as well
revert back to Inter once and for all. It's too good of a typeface
compared to the mess of Roboto and other native fonts.
Group up album artists case-insensitively.
Music files from the same artist may format the artist differently, such as being
in uppercase/lowercase forms. If we have already built an artist that has a
functionally identical name to another artist, then simply merge the artists
instead of keeping them separate.
Modify the music loader to use the normal artist name when using song
titles while still retaining album artist functionality.
Oftentimes music files will be tagged as to use the artist tag to
specify performers, collaborators, and others, and then use the album
artist tag to group them up into a single artist. Previously, Auxio
would only use the album artist tag, which flattened the collaborator
information out for consistency. Resolve this by implementing a sort
of "resolved artist name" for songs that is used in the UI and nowhere
else. This seems to work well, but at the same time further ruins the
API surface for handling music objects. An acceptable price to pay
for a better UX.
Migrate to the native roboto typeface on body elements.
Migrating to the native typeface saves on APK size, contributes to a
more native look and feel, and create a more compact UI for smaller
devices. Inter Semibold remains as the "Flair" type that distinguishes
Auxio from other apps.
Bundle our custom ExoPlayer components into aar instead of directly
depending on the project. This just makes things far better regarding
ease of use and reproducible builds.
Actually migrate to API 32 [Android 12L], co-inciding with the upgrade
of my studio install and the android gradle plugin. Alongside this, add
a bunch of fixes for lints that the new studio picked up.
Expose a custom MediaButtonReceiver that handles the media button
intent. This is not because I wanted to implement this. Some apps
like gadgetbridge just blindly query ACTION_MEDIA_BUTTON instead of
relying on the more modern MediaController API, which I expected
most apps would use instead.
Resolves#62.
I want to hold off with this migration actually. I feel like it's too
jarring of a change to be included as of right now.
This reverts commit 50170f202e.
Wrap the basic fetchArt call in a try statement to prevent exceptions
from being unable to open a file from propagating outwards. This allows
us to safely degrade when creating mosaics.
Some apps query for media apps by checking for apps that have a
BroadcastReciever that handles the ACTION_MEDIA_BUTTON intent. However,
Auxio does not have a custom media button reciever, instead relying on
the androidx media button reciever. This resulted in Auxio not showing
up in apps like GadgetBridge. Fix this by exposing the androidx media
button reciever in the manifest, which allows this app to be detected.
Implement a facimile of the new Material 3/You switches in the settings
menu. There's no defined spec for this yet, so I just shamelessly ripped
the implementation from Doodle.
Dumpster Inter in favor of Roboto. This is mostly for three reasons:
1. Reduces the insane typography setup that Auxio uses
2. Reduces total app size since .ttf files are pretty large and the
dynamic fonts feature was proprietary.
3. Creates a more cohesive look and feel given that nearly every
android app also uses Roboto.
When using gesture navigation, swipe up events might conflict with the
slide up behavior of the playback layout. To fix this, inset the
playback bar based on the gesture insets instead of the system bar
insets.