mirror of
https://github.com/Rafostar/clapper.git
synced 2025-08-31 16:31:58 +02:00
Append some common subtitle track titles
In order to not end up with multiple subitle tracks simply named for e.g. "English", add some common postfix to it when detected in track title.
This commit is contained in:
@@ -231,7 +231,11 @@ class ClapperWidget extends Gtk.Grid
|
||||
break;
|
||||
case GstClapper.ClapperSubtitleInfo:
|
||||
type = 'subtitle';
|
||||
text = info.get_language() || 'Undetermined';
|
||||
const subsLang = info.get_language();
|
||||
text = (subsLang) ? subsLang.split(',')[0] : 'Undetermined';
|
||||
const subsTitle = Misc.getSubsTitle(info.get_title());
|
||||
if(subsTitle)
|
||||
text += ', ' + subsTitle;
|
||||
break;
|
||||
default:
|
||||
debug(`unrecognized media info type: ${info.constructor}`);
|
||||
|
Reference in New Issue
Block a user