song: convert header to C++

This commit is contained in:
Max Kellermann
2013-07-28 13:25:12 +02:00
parent 43f613d9be
commit ba161ec572
91 changed files with 643 additions and 691 deletions

View File

@@ -60,7 +60,7 @@ struct XspfParser {
* The current song. It is allocated after the "location"
* element.
*/
struct song *song;
Song *song;
XspfParser()
:state(ROOT) {}
@@ -187,7 +187,7 @@ xspf_text(G_GNUC_UNUSED GMarkupParseContext *context,
case XspfParser::LOCATION:
if (parser->song == NULL) {
char *uri = g_strndup(text, text_len);
parser->song = song_remote_new(uri);
parser->song = Song::NewRemote(uri);
g_free(uri);
}
@@ -209,7 +209,7 @@ xspf_parser_destroy(gpointer data)
XspfParser *parser = (XspfParser *)data;
if (parser->state >= XspfParser::TRACK && parser->song != NULL)
song_free(parser->song);
parser->song->Free();
}
/*