added Language suffix for subtitle downloads
This commit is contained in:
parent
bd6b3c53c5
commit
1afb9cdba9
2 changed files with 19 additions and 0 deletions
|
@ -562,6 +562,24 @@ public class DownloadDialog extends DialogFragment
|
|||
selectedSubtitleIndex = position;
|
||||
break;
|
||||
}
|
||||
onItemSelectedSetFileName();
|
||||
}
|
||||
|
||||
private void onItemSelectedSetFileName() {
|
||||
final String setSubtitleLanguageCode = subtitleStreamsAdapter.getItem(selectedSubtitleIndex)
|
||||
.getLanguageTag();
|
||||
switch (dialogBinding.videoAudioGroup.getCheckedRadioButtonId()) {
|
||||
case R.id.audio_button:
|
||||
case R.id.video_button:
|
||||
dialogBinding.fileName.setText(FilenameUtils.createFilename(getContext(),
|
||||
currentInfo.getName()));
|
||||
break;
|
||||
case R.id.subtitle_button:
|
||||
dialogBinding.fileName.setText(FilenameUtils.createFilename(getContext(),
|
||||
currentInfo.getName() + getString(
|
||||
R.string.caption_file_name, setSubtitleLanguageCode)));
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -452,6 +452,7 @@
|
|||
<string name="resize_zoom">Zoom</string>
|
||||
<string name="caption_auto_generated">Auto-generated</string>
|
||||
<!-- Caption Settings -->
|
||||
<string name="caption_file_name">-%s</string>
|
||||
<string name="caption_setting_title">Captions</string>
|
||||
<string name="caption_setting_description">Modify player caption text scale and background styles. Requires app restart to take effect</string>
|
||||
<!-- Debug Settings -->
|
||||
|
|
Loading…
Reference in a new issue