From 1ed09133bc796a817e543177f2b91ec17d0b7751 Mon Sep 17 00:00:00 2001 From: deniscerri <64997243+deniscerri@users.noreply.github.com> Date: Tue, 14 Mar 2023 12:56:31 +0100 Subject: [PATCH] removed format card title if there are not formats in audio section --- .../deniscerri/ytdlnis/ui/downloadcard/DownloadAudioFragment.kt | 1 + app/src/main/res/layout/fragment_download_audio.xml | 1 + app/src/main/res/xml/root_preferences.xml | 2 +- 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/com/deniscerri/ytdlnis/ui/downloadcard/DownloadAudioFragment.kt b/app/src/main/java/com/deniscerri/ytdlnis/ui/downloadcard/DownloadAudioFragment.kt index 18d9d23a..5c9571bb 100644 --- a/app/src/main/java/com/deniscerri/ytdlnis/ui/downloadcard/DownloadAudioFragment.kt +++ b/app/src/main/java/com/deniscerri/ytdlnis/ui/downloadcard/DownloadAudioFragment.kt @@ -131,6 +131,7 @@ class DownloadAudioFragment(private var resultItem: ResultItem, private var curr val formatCard = view.findViewById(R.id.format_card_constraintLayout) if (formats.isEmpty()) { formatCard.visibility = View.GONE + view.findViewById(R.id.audio_quality_title).visibility = View.GONE } else { val chosenFormat = downloadItem.format uiUtil.populateFormatCard(formatCard, chosenFormat) diff --git a/app/src/main/res/layout/fragment_download_audio.xml b/app/src/main/res/layout/fragment_download_audio.xml index d56bfe83..c00b151e 100644 --- a/app/src/main/res/layout/fragment_download_audio.xml +++ b/app/src/main/res/layout/fragment_download_audio.xml @@ -127,6 +127,7 @@ diff --git a/app/src/main/res/xml/root_preferences.xml b/app/src/main/res/xml/root_preferences.xml index 4cbae319..4cb28b04 100644 --- a/app/src/main/res/xml/root_preferences.xml +++ b/app/src/main/res/xml/root_preferences.xml @@ -218,7 +218,7 @@ android:entryValues="@array/video_formats" android:icon="@drawable/ic_video" app:key="video_quality" - app:summary="Best Quality" + app:summary="@string/best_quality" app:title="@string/video_quality" />