fix no drc

This commit is contained in:
deniscerri 2025-09-23 20:49:24 +02:00
parent 74e3544526
commit 0e5d50d111
No known key found for this signature in database
GPG key ID: 95C43D517D830350

View file

@ -61,7 +61,7 @@ class FormatUtil(private var context: Context) {
val noDRC = sharedPreferences.getBoolean("no_prefer_drc_audio", false) val noDRC = sharedPreferences.getBoolean("no_prefer_drc_audio", false)
if (noDRC) { if (noDRC) {
formatImportance.add("no_drc") formatImportance.add(0,"no_drc")
} }
return formatImportance return formatImportance
@ -155,13 +155,10 @@ class FormatUtil(private var context: Context) {
} }
} }
"no_drc" -> { "no_drc" -> {
if (!a.format_note.contains("drc", false)) { val aHasDrc = a.format_note.contains("drc", ignoreCase = true)
0 val bHasDrc = b.format_note.contains("drc", ignoreCase = true)
}else { aHasDrc.compareTo(bHasDrc)
-1
}
} }
else -> 0 else -> 0