diff --git a/app/src/main/java/com/deniscerri/ytdl/util/FormatUtil.kt b/app/src/main/java/com/deniscerri/ytdl/util/FormatUtil.kt index 8e69019c..da3713a0 100644 --- a/app/src/main/java/com/deniscerri/ytdl/util/FormatUtil.kt +++ b/app/src/main/java/com/deniscerri/ytdl/util/FormatUtil.kt @@ -28,7 +28,9 @@ class FormatUtil(private var context: Context) { @SuppressLint("RestrictedApi") fun getAudioFormatImportance(forVideoDownload: Boolean) : List { - val preferredFormatSize = sharedPreferences.getString("preferred_format_size", "") + val preferredFormatSizeAudio = sharedPreferences.getString("preferred_format_size_audio", "") + val preferredFormatSizeGeneral = sharedPreferences.getString("preferred_format_size", "") + val preferredFormatSize = if (!preferredFormatSizeAudio.isNullOrEmpty()) preferredFormatSizeAudio else preferredFormatSizeGeneral if (sharedPreferences.getBoolean("use_format_sorting", false)) { val itemValues = context.getStringArray(R.array.format_importance_audio_values).toMutableList() diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index e4c05f41..8a88caa9 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -490,6 +490,7 @@ Recodes the video making it compatible with other apps There is no free space for this configuration. Preferred Format Size + Preferred Audio Format Size Smallest Largest Prefer DRC Audio diff --git a/app/src/main/res/xml/processing_preferences.xml b/app/src/main/res/xml/processing_preferences.xml index efb59e26..1185c174 100644 --- a/app/src/main/res/xml/processing_preferences.xml +++ b/app/src/main/res/xml/processing_preferences.xml @@ -328,6 +328,16 @@ app:useSimpleSummaryProvider="true" app:title="@string/preferred_format_size" /> + +