Commit 03d1fbd5 authored by Salah-Eddin Shaban's avatar Salah-Eddin Shaban Committed by Thomas Guillem

input: automatically select subtitle attachments

If no sub track has already been selected via sub-file or autodetection.

Close #18897
Signed-off-by: Thomas Guillem's avatarThomas Guillem <thomas@gllm.fr>
parent 62f27ca5
......@@ -1194,8 +1194,11 @@ static void LoadSlaves( input_thread_t *p_input )
{
var_SetString( p_input, "sub-description", a->psz_description ? a->psz_description : "");
input_SlaveSourceAdd( p_input, SLAVE_TYPE_SPU, psz_mrl,
SLAVE_ADD_NOFLAG );
if( input_SlaveSourceAdd( p_input, SLAVE_TYPE_SPU, psz_mrl,
p_forced[ SLAVE_TYPE_SPU ] ?
SLAVE_ADD_NOFLAG : SLAVE_ADD_FORCED ) == VLC_SUCCESS )
p_forced[ SLAVE_TYPE_SPU ] = true;
free( psz_mrl );
/* Don't update item slaves for attachements */
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment