From 9bc388f1954949c7473d66b1d61136a38d8ba4a7 Mon Sep 17 00:00:00 2001 From: nift4 Date: Fri, 24 May 2024 09:40:58 +0200 Subject: [PATCH] 1.0.6 --- app/build.gradle.kts | 4 ++-- .../akanework/gramophone/ui/adapters/SongAdapter.kt | 7 +++++++ .../gramophone/ui/fragments/DetailDialogFragment.kt | 4 ++-- app/src/main/res/layout/adapter_grid_card.xml | 7 +++---- fastlane/metadata/android/en-US/changelogs/8.txt | 11 +++++++++++ 5 files changed, 25 insertions(+), 8 deletions(-) create mode 100644 fastlane/metadata/android/en-US/changelogs/8.txt diff --git a/app/build.gradle.kts b/app/build.gradle.kts index ce410c68b..a7d4943ba 100644 --- a/app/build.gradle.kts +++ b/app/build.gradle.kts @@ -43,8 +43,8 @@ android { // keep support for it for a while. minSdk = 21 targetSdk = 34 - versionCode = 7 - versionName = "1.0.5" + versionCode = 8 + versionName = "1.0.6" if (releaseType != "Release") { versionNameSuffix = myVersionName } diff --git a/app/src/main/kotlin/org/akanework/gramophone/ui/adapters/SongAdapter.kt b/app/src/main/kotlin/org/akanework/gramophone/ui/adapters/SongAdapter.kt index d301bf3c8..936ef8f95 100644 --- a/app/src/main/kotlin/org/akanework/gramophone/ui/adapters/SongAdapter.kt +++ b/app/src/main/kotlin/org/akanework/gramophone/ui/adapters/SongAdapter.kt @@ -393,6 +393,13 @@ class SongAdapter( } override fun getReleaseDate(item: MediaItem): Long { + if (item.mediaMetadata.releaseYear == null && item.mediaMetadata.releaseMonth == null + && item.mediaMetadata.releaseDay == null) { + return GregorianCalendar((item.mediaMetadata.recordingYear ?: 0) + 1900, + (item.mediaMetadata.recordingMonth ?: 1) - 1, + item.mediaMetadata.recordingDay ?: 0, 0, 0, 0) + .timeInMillis + } return GregorianCalendar((item.mediaMetadata.releaseYear ?: 0) + 1900, (item.mediaMetadata.releaseMonth ?: 1) - 1, item.mediaMetadata.releaseDay ?: 0, 0, 0, 0) diff --git a/app/src/main/kotlin/org/akanework/gramophone/ui/fragments/DetailDialogFragment.kt b/app/src/main/kotlin/org/akanework/gramophone/ui/fragments/DetailDialogFragment.kt index a0b50e26b..77ca60e26 100644 --- a/app/src/main/kotlin/org/akanework/gramophone/ui/fragments/DetailDialogFragment.kt +++ b/app/src/main/kotlin/org/akanework/gramophone/ui/fragments/DetailDialogFragment.kt @@ -64,8 +64,8 @@ class DetailDialogFragment : BaseFragment(false) { if (mediaMetadata.genre != null) { genreTextView.text = mediaMetadata.genre } - if (mediaMetadata.releaseYear != null) { - yearTextView.text = mediaMetadata.releaseYear?.toString() + if (mediaMetadata.releaseYear != null || mediaMetadata.recordingYear != null) { + yearTextView.text = (mediaMetadata.releaseYear ?: mediaMetadata.recordingYear)?.toString() } durationTextView.text = convertDurationToTimeStamp(mediaMetadata.extras!!.getLong("Duration")) mimeTypeTextView.text = mediaItem.localConfiguration?.mimeType ?: "(null)" diff --git a/app/src/main/res/layout/adapter_grid_card.xml b/app/src/main/res/layout/adapter_grid_card.xml index 3a0b228c1..288e9b773 100644 --- a/app/src/main/res/layout/adapter_grid_card.xml +++ b/app/src/main/res/layout/adapter_grid_card.xml @@ -80,12 +80,11 @@ android:layout_height="48dp" android:padding="12dp" app:tint="?attr/colorControlNormal" - android:layout_gravity="end|center_vertical" android:contentDescription="@string/now_playing" android:visibility="gone" - app:layout_constraintBottom_toBottomOf="parent" - app:layout_constraintEnd_toStartOf="@id/more" - app:layout_constraintTop_toTopOf="parent" /> + app:layout_constraintTop_toTopOf="@id/linearLayout" + app:layout_constraintBottom_toBottomOf="@id/linearLayout" + app:layout_constraintEnd_toStartOf="@id/more" /> track number) +- better old (<9) Android and A12 compatibility +- Nicely animated now playing indicator in song list +- Added AboutLibraries +- Migrated to Coil3 image loader + - Fixed issue where thumbnails are too big while scrolling list +- Many more bug fixes I forgot about \ No newline at end of file