image: key based on object hashcode

Key images based on the full object hashcode, alongside the UID.

Hopefully this reduces the likelihood of images getting stuck further.
This commit is contained in:
Alexander Capehart 2023-05-18 17:11:55 -06:00
parent 3a5e1a5111
commit 3feee67388
No known key found for this signature in database
GPG key ID: 37DBE3621FE9AD47
2 changed files with 3 additions and 3 deletions

View file

@ -14,6 +14,7 @@ be parsed as images
- Fixed issue where short names starting with an article would not be correctly sorted (ex. "the 1")
- Fixed incorrect item arrangement on landscape
- Fixed disappearing dividers in search view
- Reduced likelihood that images (eg. album covers) would not update when the music library changed
#### Dev/Meta
- Switched to androidx media3 (New Home of ExoPlayer) for backing player components

View file

@ -36,12 +36,11 @@ import org.oxycblt.auxio.list.Sort
import org.oxycblt.auxio.music.*
class SongKeyer @Inject constructor() : Keyer<Song> {
override fun key(data: Song, options: Options) =
"${data.album.uid}${data.album.songs.hashCode()}"
override fun key(data: Song, options: Options) = "${data.album.uid}${data.album.hashCode()}"
}
class ParentKeyer @Inject constructor() : Keyer<MusicParent> {
override fun key(data: MusicParent, options: Options) = "${data.uid}${data.songs.hashCode()}"
override fun key(data: MusicParent, options: Options) = "${data.uid}${data.hashCode()}"
}
/**