Commit 7f779f6a authored by zorglub's avatar zorglub

Merge author/artist

WX compilation unchecked
parent 9a128b54
...@@ -27,7 +27,6 @@ ...@@ -27,7 +27,6 @@
/* VLC meta name */ /* VLC meta name */
#define VLC_META_INFO_CAT N_("Meta-information") #define VLC_META_INFO_CAT N_("Meta-information")
#define VLC_META_TITLE N_("Title") #define VLC_META_TITLE N_("Title")
#define VLC_META_AUTHOR N_("Author")
#define VLC_META_ARTIST N_("Artist") #define VLC_META_ARTIST N_("Artist")
#define VLC_META_GENRE N_("Genre") #define VLC_META_GENRE N_("Genre")
#define VLC_META_COPYRIGHT N_("Copyright") #define VLC_META_COPYRIGHT N_("Copyright")
...@@ -56,7 +55,6 @@ ...@@ -56,7 +55,6 @@
struct vlc_meta_t struct vlc_meta_t
{ {
char *psz_title; char *psz_title;
char *psz_author;
char *psz_artist; char *psz_artist;
char *psz_genre; char *psz_genre;
char *psz_copyright; char *psz_copyright;
...@@ -87,7 +85,6 @@ struct vlc_meta_t ...@@ -87,7 +85,6 @@ struct vlc_meta_t
#define vlc_meta_SetTitle( meta, b ) vlc_meta_Set( meta, title, b ); #define vlc_meta_SetTitle( meta, b ) vlc_meta_Set( meta, title, b );
#define vlc_meta_SetArtist( meta, b ) vlc_meta_Set( meta, artist, b ); #define vlc_meta_SetArtist( meta, b ) vlc_meta_Set( meta, artist, b );
#define vlc_meta_SetAuthor( meta, b ) vlc_meta_Set( meta, author, b );
#define vlc_meta_SetGenre( meta, b ) vlc_meta_Set( meta, genre, b ); #define vlc_meta_SetGenre( meta, b ) vlc_meta_Set( meta, genre, b );
#define vlc_meta_SetCopyright( meta, b ) vlc_meta_Set( meta, copyright, b ); #define vlc_meta_SetCopyright( meta, b ) vlc_meta_Set( meta, copyright, b );
#define vlc_meta_SetAlbum( meta, b ) vlc_meta_Set( meta, album, b ); #define vlc_meta_SetAlbum( meta, b ) vlc_meta_Set( meta, album, b );
...@@ -108,7 +105,6 @@ static inline vlc_meta_t *vlc_meta_New( void ) ...@@ -108,7 +105,6 @@ static inline vlc_meta_t *vlc_meta_New( void )
vlc_meta_t *m = (vlc_meta_t*)malloc( sizeof( vlc_meta_t ) ); vlc_meta_t *m = (vlc_meta_t*)malloc( sizeof( vlc_meta_t ) );
if( !m ) return NULL; if( !m ) return NULL;
m->psz_title = NULL; m->psz_title = NULL;
m->psz_author = NULL;
m->psz_artist = NULL; m->psz_artist = NULL;
m->psz_genre = NULL; m->psz_genre = NULL;
m->psz_copyright = NULL; m->psz_copyright = NULL;
...@@ -131,7 +127,6 @@ static inline vlc_meta_t *vlc_meta_New( void ) ...@@ -131,7 +127,6 @@ static inline vlc_meta_t *vlc_meta_New( void )
static inline void vlc_meta_Delete( vlc_meta_t *m ) static inline void vlc_meta_Delete( vlc_meta_t *m )
{ {
free( m->psz_title ); free( m->psz_title );
free( m->psz_author );
free( m->psz_artist ); free( m->psz_artist );
free( m->psz_genre ); free( m->psz_genre );
free( m->psz_copyright ); free( m->psz_copyright );
...@@ -160,7 +155,6 @@ static inline void vlc_meta_Merge( vlc_meta_t *dst, vlc_meta_t *src ) ...@@ -160,7 +155,6 @@ static inline void vlc_meta_Merge( vlc_meta_t *dst, vlc_meta_t *src )
dst->psz_##a = strdup( src->psz_##a ); \ dst->psz_##a = strdup( src->psz_##a ); \
} }
COPY_FIELD( title ); COPY_FIELD( title );
COPY_FIELD( author );
COPY_FIELD( artist ); COPY_FIELD( artist );
COPY_FIELD( genre ); COPY_FIELD( genre );
COPY_FIELD( copyright ); COPY_FIELD( copyright );
...@@ -192,7 +186,6 @@ struct meta_export_t ...@@ -192,7 +186,6 @@ struct meta_export_t
}; };
#define VLC_META_ENGINE_TITLE 0x00000001 #define VLC_META_ENGINE_TITLE 0x00000001
#define VLC_META_ENGINE_AUTHOR 0x00000002
#define VLC_META_ENGINE_ARTIST 0x00000004 #define VLC_META_ENGINE_ARTIST 0x00000004
#define VLC_META_ENGINE_GENRE 0x00000008 #define VLC_META_ENGINE_GENRE 0x00000008
#define VLC_META_ENGINE_COPYRIGHT 0x00000010 #define VLC_META_ENGINE_COPYRIGHT 0x00000010
......
...@@ -549,6 +549,7 @@ struct module_symbols_t ...@@ -549,6 +549,7 @@ struct module_symbols_t
void *__input_ArtFetch_deprecated; void *__input_ArtFetch_deprecated;
void *input_AskForArt_deprecated; void *input_AskForArt_deprecated;
int (*playlist_AskForArtEnqueue_inner) (playlist_t *, input_item_t *); int (*playlist_AskForArtEnqueue_inner) (playlist_t *, input_item_t *);
uint32_t (*input_CurrentMetaFlags_inner) (vlc_meta_t *p_meta);
}; };
# if defined (__PLUGIN__) # if defined (__PLUGIN__)
# define aout_FiltersCreatePipeline (p_symbols)->aout_FiltersCreatePipeline_inner # define aout_FiltersCreatePipeline (p_symbols)->aout_FiltersCreatePipeline_inner
...@@ -1023,6 +1024,7 @@ struct module_symbols_t ...@@ -1023,6 +1024,7 @@ struct module_symbols_t
# define input_ItemAddInfo (p_symbols)->input_ItemAddInfo_inner # define input_ItemAddInfo (p_symbols)->input_ItemAddInfo_inner
# define input_ItemAddOptionNoDup (p_symbols)->input_ItemAddOptionNoDup_inner # define input_ItemAddOptionNoDup (p_symbols)->input_ItemAddOptionNoDup_inner
# define playlist_AskForArtEnqueue (p_symbols)->playlist_AskForArtEnqueue_inner # define playlist_AskForArtEnqueue (p_symbols)->playlist_AskForArtEnqueue_inner
# define input_CurrentMetaFlags (p_symbols)->input_CurrentMetaFlags_inner
# elif defined (HAVE_DYNAMIC_PLUGINS) && !defined (__BUILTIN__) # elif defined (HAVE_DYNAMIC_PLUGINS) && !defined (__BUILTIN__)
/****************************************************************** /******************************************************************
* STORE_SYMBOLS: store VLC APIs into p_symbols for plugin access. * STORE_SYMBOLS: store VLC APIs into p_symbols for plugin access.
...@@ -1500,6 +1502,7 @@ struct module_symbols_t ...@@ -1500,6 +1502,7 @@ struct module_symbols_t
((p_symbols)->input_ItemAddInfo_inner) = input_ItemAddInfo; \ ((p_symbols)->input_ItemAddInfo_inner) = input_ItemAddInfo; \
((p_symbols)->input_ItemAddOptionNoDup_inner) = input_ItemAddOptionNoDup; \ ((p_symbols)->input_ItemAddOptionNoDup_inner) = input_ItemAddOptionNoDup; \
((p_symbols)->playlist_AskForArtEnqueue_inner) = playlist_AskForArtEnqueue; \ ((p_symbols)->playlist_AskForArtEnqueue_inner) = playlist_AskForArtEnqueue; \
((p_symbols)->input_CurrentMetaFlags_inner) = input_CurrentMetaFlags; \
(p_symbols)->net_ConvertIPv4_deprecated = NULL; \ (p_symbols)->net_ConvertIPv4_deprecated = NULL; \
(p_symbols)->vlc_input_item_GetInfo_deprecated = NULL; \ (p_symbols)->vlc_input_item_GetInfo_deprecated = NULL; \
(p_symbols)->vlc_input_item_AddInfo_deprecated = NULL; \ (p_symbols)->vlc_input_item_AddInfo_deprecated = NULL; \
......
...@@ -413,7 +413,7 @@ static int Control( demux_t *p_demux, int i_query, va_list args ) ...@@ -413,7 +413,7 @@ static int Control( demux_t *p_demux, int i_query, va_list args )
if( p_sys->ic->title[0] ) if( p_sys->ic->title[0] )
vlc_meta_SetTitle( p_meta, p_sys->ic->title ); vlc_meta_SetTitle( p_meta, p_sys->ic->title );
if( p_sys->ic->author[0] ) if( p_sys->ic->author[0] )
vlc_meta_SetAuthor( p_meta, p_sys->ic->author ); vlc_meta_SetArtist( p_meta, p_sys->ic->author );
if( p_sys->ic->copyright[0] ) if( p_sys->ic->copyright[0] )
vlc_meta_SetCopyright( p_meta, p_sys->ic->copyright ); vlc_meta_SetCopyright( p_meta, p_sys->ic->copyright );
if( p_sys->ic->comment[0] ) if( p_sys->ic->comment[0] )
......
...@@ -817,9 +817,9 @@ static int DemuxInit( demux_t *p_demux ) ...@@ -817,9 +817,9 @@ static int DemuxInit( demux_t *p_demux )
{ {
vlc_meta_SetTitle( p_sys->meta, p_cd->psz_title ); vlc_meta_SetTitle( p_sys->meta, p_cd->psz_title );
} }
if( p_cd->psz_author && *p_cd->psz_author ) if( p_cd->psz_artist && *p_cd->psz_artist )
{ {
vlc_meta_SetAuthor( p_sys->meta, p_cd->psz_author ); vlc_meta_SetArtist( p_sys->meta, p_cd->psz_artist );
} }
if( p_cd->psz_copyright && *p_cd->psz_copyright ) if( p_cd->psz_copyright && *p_cd->psz_copyright )
{ {
......
...@@ -672,7 +672,7 @@ static int ASF_ReadObject_content_description(stream_t *s, asf_object_t *p_obj) ...@@ -672,7 +672,7 @@ static int ASF_ReadObject_content_description(stream_t *s, asf_object_t *p_obj)
asf_object_content_description_t *p_cd = asf_object_content_description_t *p_cd =
(asf_object_content_description_t *)p_obj; (asf_object_content_description_t *)p_obj;
uint8_t *p_peek, *p_data; uint8_t *p_peek, *p_data;
int i_peek, i_title, i_author, i_copyright, i_description, i_rating; int i_peek, i_title, i_artist, i_copyright, i_description, i_rating;
vlc_iconv_t cd = (vlc_iconv_t)-1; vlc_iconv_t cd = (vlc_iconv_t)-1;
const char *ib = NULL; const char *ib = NULL;
char *ob = NULL; char *ob = NULL;
...@@ -701,13 +701,13 @@ static int ASF_ReadObject_content_description(stream_t *s, asf_object_t *p_obj) ...@@ -701,13 +701,13 @@ static int ASF_ReadObject_content_description(stream_t *s, asf_object_t *p_obj)
p_data = p_peek + 24; p_data = p_peek + 24;
i_title = GetWLE( p_data ); p_data += 2; i_title = GetWLE( p_data ); p_data += 2;
i_author= GetWLE( p_data ); p_data += 2; i_artist= GetWLE( p_data ); p_data += 2;
i_copyright = GetWLE( p_data ); p_data += 2; i_copyright = GetWLE( p_data ); p_data += 2;
i_description = GetWLE( p_data ); p_data += 2; i_description = GetWLE( p_data ); p_data += 2;
i_rating = GetWLE( p_data ); p_data += 2; i_rating = GetWLE( p_data ); p_data += 2;
GETSTRINGW( p_cd->psz_title, i_title ); GETSTRINGW( p_cd->psz_title, i_title );
GETSTRINGW( p_cd->psz_author, i_author ); GETSTRINGW( p_cd->psz_artist, i_artist );
GETSTRINGW( p_cd->psz_copyright, i_copyright ); GETSTRINGW( p_cd->psz_copyright, i_copyright );
GETSTRINGW( p_cd->psz_description, i_description ); GETSTRINGW( p_cd->psz_description, i_description );
GETSTRINGW( p_cd->psz_rating, i_rating ); GETSTRINGW( p_cd->psz_rating, i_rating );
...@@ -716,9 +716,9 @@ static int ASF_ReadObject_content_description(stream_t *s, asf_object_t *p_obj) ...@@ -716,9 +716,9 @@ static int ASF_ReadObject_content_description(stream_t *s, asf_object_t *p_obj)
#ifdef ASF_DEBUG #ifdef ASF_DEBUG
msg_Dbg( s, msg_Dbg( s,
"read \"content description object\" title:\"%s\" author:\"%s\" copyright:\"%s\" description:\"%s\" rating:\"%s\"", "read \"content description object\" title:\"%s\" artist:\"%s\" copyright:\"%s\" description:\"%s\" rating:\"%s\"",
p_cd->psz_title, p_cd->psz_title,
p_cd->psz_author, p_cd->psz_artist,
p_cd->psz_copyright, p_cd->psz_copyright,
p_cd->psz_description, p_cd->psz_description,
p_cd->psz_rating ); p_cd->psz_rating );
...@@ -734,7 +734,7 @@ static void ASF_FreeObject_content_description( asf_object_t *p_obj) ...@@ -734,7 +734,7 @@ static void ASF_FreeObject_content_description( asf_object_t *p_obj)
(asf_object_content_description_t *)p_obj; (asf_object_content_description_t *)p_obj;
FREENULL( p_cd->psz_title ); FREENULL( p_cd->psz_title );
FREENULL( p_cd->psz_author ); FREENULL( p_cd->psz_artist );
FREENULL( p_cd->psz_copyright ); FREENULL( p_cd->psz_copyright );
FREENULL( p_cd->psz_description ); FREENULL( p_cd->psz_description );
FREENULL( p_cd->psz_rating ); FREENULL( p_cd->psz_rating );
......
...@@ -264,7 +264,7 @@ typedef struct ...@@ -264,7 +264,7 @@ typedef struct
ASF_OBJECT_COMMON ASF_OBJECT_COMMON
char *psz_title; char *psz_title;
char *psz_author; char *psz_artist;
char *psz_copyright; char *psz_copyright;
char *psz_description; char *psz_description;
char *psz_rating; char *psz_rating;
......
...@@ -805,7 +805,7 @@ static int Control( demux_t *p_demux, int i_query, va_list args ) ...@@ -805,7 +805,7 @@ static int Control( demux_t *p_demux, int i_query, va_list args )
vlc_meta_SetArtist( p_meta, psz_utf ); vlc_meta_SetArtist( p_meta, psz_utf );
break; break;
case FOURCC_0xa9aut: case FOURCC_0xa9aut:
vlc_meta_SetAuthor( p_meta, psz_utf ); vlc_meta_SetArtist( p_meta, psz_utf );
break; break;
case FOURCC_0xa9ART: case FOURCC_0xa9ART:
vlc_meta_SetArtist( p_meta, psz_utf ); vlc_meta_SetArtist( p_meta, psz_utf );
......
...@@ -166,14 +166,14 @@ static int Demux( demux_t *p_demux ) ...@@ -166,14 +166,14 @@ static int Demux( demux_t *p_demux )
char *psz_base_asx = NULL; char *psz_base_asx = NULL;
char *psz_title_asx = NULL; char *psz_title_asx = NULL;
char *psz_author_asx = NULL; char *psz_artist_asx = NULL;
char *psz_copyright_asx = NULL; char *psz_copyright_asx = NULL;
char *psz_moreinfo_asx = NULL; char *psz_moreinfo_asx = NULL;
char *psz_abstract_asx = NULL; char *psz_abstract_asx = NULL;
char *psz_base_entry = NULL; char *psz_base_entry = NULL;
char *psz_title_entry = NULL; char *psz_title_entry = NULL;
char *psz_author_entry = NULL; char *psz_artist_entry = NULL;
char *psz_copyright_entry = NULL; char *psz_copyright_entry = NULL;
char *psz_moreinfo_entry = NULL; char *psz_moreinfo_entry = NULL;
char *psz_abstract_entry = NULL; char *psz_abstract_entry = NULL;
...@@ -292,7 +292,7 @@ static int Demux( demux_t *p_demux ) ...@@ -292,7 +292,7 @@ static int Demux( demux_t *p_demux )
psz_backup = psz_parse+=8; psz_backup = psz_parse+=8;
if( ( psz_parse = strcasestr( psz_parse, "</Author>" ) ) ) if( ( psz_parse = strcasestr( psz_parse, "</Author>" ) ) )
{ {
StoreString( p_demux, (b_entry ? &psz_author_entry : &psz_author_asx), psz_backup, psz_parse ); StoreString( p_demux, (b_entry ? &psz_artist_entry : &psz_artist_asx), psz_backup, psz_parse );
psz_parse += 9; psz_parse += 9;
} }
else continue; else continue;
...@@ -379,7 +379,7 @@ static int Demux( demux_t *p_demux ) ...@@ -379,7 +379,7 @@ static int Demux( demux_t *p_demux )
/* cleanup entry */ /* cleanup entry */
FREENULL( psz_title_entry ) FREENULL( psz_title_entry )
FREENULL( psz_base_entry ) FREENULL( psz_base_entry )
FREENULL( psz_author_entry ) FREENULL( psz_artist_entry )
FREENULL( psz_copyright_entry ) FREENULL( psz_copyright_entry )
FREENULL( psz_moreinfo_entry ) FREENULL( psz_moreinfo_entry )
FREENULL( psz_abstract_entry ) FREENULL( psz_abstract_entry )
...@@ -429,7 +429,7 @@ static int Demux( demux_t *p_demux ) ...@@ -429,7 +429,7 @@ static int Demux( demux_t *p_demux )
input_ItemCopyOptions( p_current->p_input, p_entry ); input_ItemCopyOptions( p_current->p_input, p_entry );
p_entry->p_meta = vlc_meta_New(); p_entry->p_meta = vlc_meta_New();
if( psz_title_entry ) vlc_meta_SetTitle( p_entry->p_meta, psz_title_entry ); if( psz_title_entry ) vlc_meta_SetTitle( p_entry->p_meta, psz_title_entry );
if( psz_author_entry ) vlc_meta_SetAuthor( p_entry->p_meta, psz_author_entry ); if( psz_artist_entry ) vlc_meta_SetArtist( p_entry->p_meta, psz_artist_entry );
if( psz_copyright_entry ) vlc_meta_SetCopyright( p_entry->p_meta, psz_copyright_entry ); if( psz_copyright_entry ) vlc_meta_SetCopyright( p_entry->p_meta, psz_copyright_entry );
if( psz_moreinfo_entry ) vlc_meta_SetURL( p_entry->p_meta, psz_moreinfo_entry ); if( psz_moreinfo_entry ) vlc_meta_SetURL( p_entry->p_meta, psz_moreinfo_entry );
if( psz_abstract_entry ) vlc_meta_SetDescription( p_entry->p_meta, psz_abstract_entry ); if( psz_abstract_entry ) vlc_meta_SetDescription( p_entry->p_meta, psz_abstract_entry );
...@@ -452,14 +452,14 @@ static int Demux( demux_t *p_demux ) ...@@ -452,14 +452,14 @@ static int Demux( demux_t *p_demux )
vlc_mutex_lock( &p_current->p_input->lock ); vlc_mutex_lock( &p_current->p_input->lock );
if( !p_current->p_input->p_meta ) p_current->p_input->p_meta = vlc_meta_New(); if( !p_current->p_input->p_meta ) p_current->p_input->p_meta = vlc_meta_New();
if( psz_title_asx ) vlc_meta_SetTitle( p_current->p_input->p_meta, psz_title_asx ); if( psz_title_asx ) vlc_meta_SetTitle( p_current->p_input->p_meta, psz_title_asx );
if( psz_author_asx ) vlc_meta_SetAuthor( p_current->p_input->p_meta, psz_author_asx ); if( psz_artist_asx ) vlc_meta_SetArtist( p_current->p_input->p_meta, psz_artist_asx );
if( psz_copyright_asx ) vlc_meta_SetCopyright( p_current->p_input->p_meta, psz_copyright_asx ); if( psz_copyright_asx ) vlc_meta_SetCopyright( p_current->p_input->p_meta, psz_copyright_asx );
if( psz_moreinfo_asx ) vlc_meta_SetURL( p_current->p_input->p_meta, psz_moreinfo_asx ); if( psz_moreinfo_asx ) vlc_meta_SetURL( p_current->p_input->p_meta, psz_moreinfo_asx );
if( psz_abstract_asx ) vlc_meta_SetDescription( p_current->p_input->p_meta, psz_abstract_asx ); if( psz_abstract_asx ) vlc_meta_SetDescription( p_current->p_input->p_meta, psz_abstract_asx );
vlc_mutex_unlock( &p_current->p_input->lock ); vlc_mutex_unlock( &p_current->p_input->lock );
FREENULL( psz_base_asx ); FREENULL( psz_base_asx );
FREENULL( psz_title_asx ); FREENULL( psz_title_asx );
FREENULL( psz_author_asx ); FREENULL( psz_artist_asx );
FREENULL( psz_copyright_asx ); FREENULL( psz_copyright_asx );
FREENULL( psz_moreinfo_asx ); FREENULL( psz_moreinfo_asx );
FREENULL( psz_abstract_asx ); FREENULL( psz_abstract_asx );
......
...@@ -515,15 +515,15 @@ void Playlist::UpdateTreeItem( wxTreeItemId item ) ...@@ -515,15 +515,15 @@ void Playlist::UpdateTreeItem( wxTreeItemId item )
wxString msg; wxString msg;
wxString duration = wxU( "" ); wxString duration = wxU( "" );
char *psz_author; char *psz_artist;
if( p_item->p_input->p_meta ) if( p_item->p_input->p_meta )
{ {
psz_author= p_item->p_input->p_meta->psz_artist ? psz_artist= p_item->p_input->p_meta->psz_artist ?
strdup( p_item->p_input->p_meta->psz_artist ) : strdup( p_item->p_input->p_meta->psz_artist ) :
strdup(""); strdup("");
} }
else else
psz_author = strdup( "" ); psz_artist = strdup( "" );
char psz_duration[MSTRTIME_MAX_SIZE]; char psz_duration[MSTRTIME_MAX_SIZE];
mtime_t dur = p_item->p_input->i_duration; mtime_t dur = p_item->p_input->i_duration;
...@@ -535,16 +535,16 @@ void Playlist::UpdateTreeItem( wxTreeItemId item ) ...@@ -535,16 +535,16 @@ void Playlist::UpdateTreeItem( wxTreeItemId item )
wxU( " )" ) ); wxU( " )" ) );
} }
if( !strcmp( psz_author, "" ) || p_item->p_input->b_fixed_name == VLC_TRUE ) if( !strcmp( psz_artist, "" ) || p_item->p_input->b_fixed_name == VLC_TRUE )
{ {
msg = wxString( wxU( p_item->p_input->psz_name ) ) + duration; msg = wxString( wxU( p_item->p_input->psz_name ) ) + duration;
} }
else else
{ {
msg = wxString(wxU( psz_author )) + wxT(" - ") + msg = wxString(wxU( psz_artist )) + wxT(" - ") +
wxString(wxU(p_item->p_input->psz_name)) + duration; wxString(wxU(p_item->p_input->psz_name)) + duration;
} }
free( psz_author ); free( psz_artist );
treectrl->SetItemText( item , msg ); treectrl->SetItemText( item , msg );
treectrl->SetItemImage( item, p_item->p_input->i_type ); treectrl->SetItemImage( item, p_item->p_input->i_type );
......
...@@ -290,10 +290,10 @@ void PlaylistManager::UpdateTreeItem( wxTreeItemId item ) ...@@ -290,10 +290,10 @@ void PlaylistManager::UpdateTreeItem( wxTreeItemId item )
wxString msg; wxString msg;
wxString duration = wxU( "" ); wxString duration = wxU( "" );
char *psz_author = p_item->p_input->p_meta->psz_artist ? char *psz_artist = p_item->p_input->p_meta->psz_artist ?
strdup( p_item->p_input->p_meta->psz_artist ) : strdup( p_item->p_input->p_meta->psz_artist ) :
strdup( "" ); strdup( "" );
if( !psz_author ) if( !psz_artist )
{ {
UnlockPlaylist( p_intf->p_sys, p_playlist ); UnlockPlaylist( p_intf->p_sys, p_playlist );
return; return;
...@@ -309,16 +309,16 @@ void PlaylistManager::UpdateTreeItem( wxTreeItemId item ) ...@@ -309,16 +309,16 @@ void PlaylistManager::UpdateTreeItem( wxTreeItemId item )
wxU( " )" ) ); wxU( " )" ) );
} }
if( !strcmp( psz_author, "" ) || p_item->p_input->b_fixed_name == VLC_TRUE ) if( !strcmp( psz_artist, "" ) || p_item->p_input->b_fixed_name == VLC_TRUE )
{ {
msg = wxString( wxU( p_item->p_input->psz_name ) ) + duration; msg = wxString( wxU( p_item->p_input->psz_name ) ) + duration;
} }
else else
{ {
msg = wxString(wxU( psz_author )) + wxT(" - ") + msg = wxString(wxU( psz_artist )) + wxT(" - ") +
wxString(wxU(p_item->p_input->psz_name)) + duration; wxString(wxU(p_item->p_input->psz_name)) + duration;
} }
free( psz_author ); free( psz_artist );
treectrl->SetItemText( item , msg ); treectrl->SetItemText( item , msg );
treectrl->SetItemImage( item, p_item->p_input->i_type ); treectrl->SetItemImage( item, p_item->p_input->i_type );
......
...@@ -172,8 +172,8 @@ static void xspf_export_item( playlist_item_t *p_item, FILE *p_file, ...@@ -172,8 +172,8 @@ static void xspf_export_item( playlist_item_t *p_item, FILE *p_file,
} }
if( !psz ) if( !psz )
{ {
psz = p_item->p_input->p_meta->psz_author ? psz = p_item->p_input->p_meta->psz_artist ?
strdup( p_item->p_input->p_meta->psz_author ): strdup( p_item->p_input->p_meta->psz_artist ):
strdup( "" ); strdup( "" );
} }
psz_temp = convert_xml_special_chars( psz ); psz_temp = convert_xml_special_chars( psz );
......
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