diff --git a/CHANGELOG.md b/CHANGELOG.md
index da542f0e2..add8aa646 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -10,6 +10,12 @@ at the cost of longer loading times
- Added Last Added sorting
- Search now takes sort tags and file names in account [#184]
+#### What's Fixed
+- Fixed default material theme being used before app shows up
+
+#### What's Changed
+- Updated music hashing (Will wipe playback state)
+
## 2.5.0
#### What's New
diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml
index 1177fc4b3..675d4c529 100644
--- a/app/src/main/AndroidManifest.xml
+++ b/app/src/main/AndroidManifest.xml
@@ -14,12 +14,6 @@
-
)
* An ISO-8601/RFC 3339 Date.
*
* Unlike a typical Date within the standard library, this class just represents the ID3v2/Vorbis
- * date format, which is largely assumed to be a subset of ISO-8601. No validation outside of
- * format validation is done.
+ * date format, which is largely assumed to be a subset of ISO-8601. No validation outside of format
+ * validation is done.
*
* The reasoning behind Date is that Auxio cannot trust any kind of metadata date to actually make
* sense in a calendar, due to bad tagging, locale-specific issues, or simply from the limited
@@ -345,7 +345,6 @@ class Date private constructor(private val tokens: List) : Comparable
private val second: Int?
get() = tokens.getOrNull(5)
-
override fun hashCode() = tokens.hashCode()
override fun equals(other: Any?) = other is Date && tokens == other.tokens
diff --git a/app/src/main/java/org/oxycblt/auxio/music/system/MediaStoreBackend.kt b/app/src/main/java/org/oxycblt/auxio/music/system/MediaStoreBackend.kt
index 0ed809f1f..47d4bc82c 100644
--- a/app/src/main/java/org/oxycblt/auxio/music/system/MediaStoreBackend.kt
+++ b/app/src/main/java/org/oxycblt/auxio/music/system/MediaStoreBackend.kt
@@ -318,9 +318,9 @@ abstract class MediaStoreBackend : Indexer.Backend {
}
/**
- * Represents a song as it is represented by MediaStore. This is progressively mutated over
- * several steps of the music loading process until it is complete enough to be transformed into
- * an immutable song.
+ * Represents a song as it is represented by MediaStore. This is progressively mutated in the
+ * chain of Backend instances until it is complete enough to be transformed into an immutable
+ * song.
*/
data class Audio(
var id: Long? = null,
@@ -348,8 +348,7 @@ abstract class MediaStoreBackend : Indexer.Backend {
fun toSong() =
Song(
// Assert that the fields that should always exist are present. I can't confirm
- // that
- // every device provides these fields, but it seems likely that they do.
+ // that every device provides these fields, but it seems likely that they do.
rawName = requireNotNull(title) { "Malformed audio: No title" },
rawSortName = sortTitle,
path =
diff --git a/app/src/main/java/org/oxycblt/auxio/search/SearchViewModel.kt b/app/src/main/java/org/oxycblt/auxio/search/SearchViewModel.kt
index 5de47cfb0..f5210927c 100644
--- a/app/src/main/java/org/oxycblt/auxio/search/SearchViewModel.kt
+++ b/app/src/main/java/org/oxycblt/auxio/search/SearchViewModel.kt
@@ -137,7 +137,9 @@ class SearchViewModel(application: Application) :
search(lastQuery)
}
- /** Searches the song list by the normalized name, then the sort name, and then the file name. */
+ /**
+ * Searches the song list by the normalized name, then the sort name, and then the file name.
+ */
private fun List.filterSongsBy(value: String) =
baseFilterBy(value) { it.path.name.contains(value) }.ifEmpty { null }
@@ -145,17 +147,17 @@ class SearchViewModel(application: Application) :
private fun List.filterParentsBy(value: String) =
baseFilterBy(value) { false }.ifEmpty { null }
- private inline fun List.baseFilterBy(
- value: String,
- additional: (T) -> Boolean
- ) = filter {
- // The basic comparison is first by the *normalized* name, as that allows a non-unicode
- // search to match with some unicode characters. If that fails, we if there is a sort name
- // we can leverage, as those are often used to make non-unicode variants of unicode titles.
- it.resolveNameNormalized(application).contains(value, ignoreCase = true) ||
- it.rawSortName?.contains(value, ignoreCase = true) == true ||
- additional(it)
- }
+ private inline fun List.baseFilterBy(value: String, additional: (T) -> Boolean) =
+ filter {
+ // The basic comparison is first by the *normalized* name, as that allows a non-unicode
+ // search to match with some unicode characters. If that fails, we if there is a sort
+ // name
+ // we can leverage, as those are often used to make non-unicode variants of unicode
+ // titles.
+ it.resolveNameNormalized(application).contains(value, ignoreCase = true) ||
+ it.rawSortName?.contains(value, ignoreCase = true) == true ||
+ additional(it)
+ }
private fun Music.resolveNameNormalized(context: Context): String {
// This method normalizes strings so that songs with accented characters will show
diff --git a/app/src/main/res/layout/widget_default.xml b/app/src/main/res/layout/widget_default.xml
index a270f5822..a51b36977 100644
--- a/app/src/main/res/layout/widget_default.xml
+++ b/app/src/main/res/layout/widget_default.xml
@@ -5,7 +5,7 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="?attr/colorSurface"
- android:theme="@style/Theme.Widget"
+ android:theme="@style/Theme.Auxio.Widget"
tools:ignore="Overdraw">
+ android:theme="@style/Theme.Auxio.Widget">
-
+
+
-
+
\ No newline at end of file
diff --git a/app/src/main/res/values/themes.xml b/app/src/main/res/values/themes.xml
index 783896c98..74061c215 100644
--- a/app/src/main/res/values/themes.xml
+++ b/app/src/main/res/values/themes.xml
@@ -3,7 +3,7 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-