Commit b85ed92b authored by Antoine Cellerier's avatar Antoine Cellerier

Attempt to allow using meta information in the MSN now playing format ... I...

Attempt to allow using meta information in the MSN now playing format ... I have no idea if this will really work.
parent c2a74987
...@@ -134,6 +134,7 @@ static int ItemChange( vlc_object_t *p_this, const char *psz_var, ...@@ -134,6 +134,7 @@ static int ItemChange( vlc_object_t *p_this, const char *psz_var,
char *psz_title = NULL; char *psz_title = NULL;
char *psz_artist = NULL; char *psz_artist = NULL;
char *psz_album = NULL; char *psz_album = NULL;
char *psz_buf = NULL;
input_thread_t *p_input; input_thread_t *p_input;
playlist_t *p_playlist = pl_Yield( p_this ); playlist_t *p_playlist = pl_Yield( p_this );
...@@ -162,13 +163,17 @@ static int ItemChange( vlc_object_t *p_this, const char *psz_var, ...@@ -162,13 +163,17 @@ static int ItemChange( vlc_object_t *p_this, const char *psz_var,
if( psz_title == NULL ) psz_title = strdup( N_("(no title)") ); if( psz_title == NULL ) psz_title = strdup( N_("(no title)") );
if( psz_artist == NULL ) psz_artist = strdup( N_("(no artist)") ); if( psz_artist == NULL ) psz_artist = strdup( N_("(no artist)") );
if( psz_album == NULL ) psz_album = strdup( N_("(no album)") ); if( psz_album == NULL ) psz_album = strdup( N_("(no album)") );
psz_buf = str_format_meta( p_this, p_intf->p_sys->psz_format );
snprintf( psz_tmp, snprintf( psz_tmp,
MSN_MAX_LENGTH, MSN_MAX_LENGTH,
"\\0Music\\01\\0%s\\0%s\\0%s\\0%s\\0\\0\\0", "\\0Music\\01\\0%s\\0%s\\0%s\\0%s\\0\\0\\0",
p_intf->p_sys->psz_format, psz_buf,
psz_artist, psz_artist,
psz_title, psz_title,
psz_album ); psz_album );
free( psz_buf );
free( psz_title ); free( psz_title );
free( psz_artist ); free( psz_artist );
free( psz_album ); free( psz_album );
......
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