diff options
Diffstat (limited to '')
-rw-r--r-- | src/playlist/AsxPlaylistPlugin.cxx | 14 | ||||
-rw-r--r-- | src/playlist/CuePlaylistPlugin.cxx | 6 | ||||
-rw-r--r-- | src/playlist/DespotifyPlaylistPlugin.cxx | 6 | ||||
-rw-r--r-- | src/playlist/EmbeddedCuePlaylistPlugin.cxx | 10 | ||||
-rw-r--r-- | src/playlist/ExtM3uPlaylistPlugin.cxx | 8 | ||||
-rw-r--r-- | src/playlist/LastFMPlaylistPlugin.cxx | 4 | ||||
-rw-r--r-- | src/playlist/M3uPlaylistPlugin.cxx | 6 | ||||
-rw-r--r-- | src/playlist/MemoryPlaylistProvider.cxx | 6 | ||||
-rw-r--r-- | src/playlist/MemoryPlaylistProvider.hxx | 4 | ||||
-rw-r--r-- | src/playlist/PlsPlaylistPlugin.cxx | 6 | ||||
-rw-r--r-- | src/playlist/RssPlaylistPlugin.cxx | 14 | ||||
-rw-r--r-- | src/playlist/SoundCloudPlaylistPlugin.cxx | 6 | ||||
-rw-r--r-- | src/playlist/XspfPlaylistPlugin.cxx | 6 |
13 files changed, 48 insertions, 48 deletions
diff --git a/src/playlist/AsxPlaylistPlugin.cxx b/src/playlist/AsxPlaylistPlugin.cxx index 25319ca6b..198b1d581 100644 --- a/src/playlist/AsxPlaylistPlugin.cxx +++ b/src/playlist/AsxPlaylistPlugin.cxx @@ -21,7 +21,7 @@ #include "AsxPlaylistPlugin.hxx" #include "MemoryPlaylistProvider.hxx" #include "input_stream.h" -#include "song.h" +#include "Song.hxx" #include "tag.h" #include <glib.h> @@ -60,7 +60,7 @@ struct AsxParser { * The current song. It is allocated after the "location" * element. */ - struct song *song; + Song *song; AsxParser() :state(ROOT) {} @@ -91,7 +91,7 @@ asx_start_element(G_GNUC_UNUSED GMarkupParseContext *context, case AsxParser::ROOT: if (g_ascii_strcasecmp(element_name, "entry") == 0) { parser->state = AsxParser::ENTRY; - parser->song = song_remote_new("asx:"); + parser->song = Song::NewRemote("asx:"); parser->tag = TAG_NUM_OF_ITEM_TYPES; } @@ -108,12 +108,12 @@ asx_start_element(G_GNUC_UNUSED GMarkupParseContext *context, replace the existing song's URI, because that attribute is immutable */ - struct song *song = song_remote_new(href); + Song *song = Song::NewRemote(href); if (parser->song != NULL) { song->tag = parser->song->tag; parser->song->tag = NULL; - song_free(parser->song); + parser->song->Free(); } parser->song = song; @@ -145,7 +145,7 @@ asx_end_element(G_GNUC_UNUSED GMarkupParseContext *context, if (strcmp(parser->song->uri, "asx:") != 0) parser->songs.emplace_front(parser->song); else - song_free(parser->song); + parser->song->Free(); parser->state = AsxParser::ROOT; } else @@ -192,7 +192,7 @@ asx_parser_destroy(gpointer data) AsxParser *parser = (AsxParser *)data; if (parser->state >= AsxParser::ENTRY) - song_free(parser->song); + parser->song->Free(); } /* diff --git a/src/playlist/CuePlaylistPlugin.cxx b/src/playlist/CuePlaylistPlugin.cxx index 3d8098672..23f2aa82a 100644 --- a/src/playlist/CuePlaylistPlugin.cxx +++ b/src/playlist/CuePlaylistPlugin.cxx @@ -21,7 +21,7 @@ #include "CuePlaylistPlugin.hxx" #include "PlaylistPlugin.hxx" #include "tag.h" -#include "song.h" +#include "Song.hxx" #include "input_stream.h" #include "cue/CueParser.hxx" #include "TextInputStream.hxx" @@ -63,12 +63,12 @@ cue_playlist_close(struct playlist_provider *_playlist) delete playlist; } -static struct song * +static Song * cue_playlist_read(struct playlist_provider *_playlist) { CuePlaylist *playlist = (CuePlaylist *)_playlist; - struct song *song = playlist->parser.Get(); + Song *song = playlist->parser.Get(); if (song != NULL) return song; diff --git a/src/playlist/DespotifyPlaylistPlugin.cxx b/src/playlist/DespotifyPlaylistPlugin.cxx index 25f12785a..444a41a13 100644 --- a/src/playlist/DespotifyPlaylistPlugin.cxx +++ b/src/playlist/DespotifyPlaylistPlugin.cxx @@ -22,7 +22,7 @@ #include "DespotifyUtils.hxx" #include "MemoryPlaylistProvider.hxx" #include "tag.h" -#include "song.h" +#include "Song.hxx" extern "C" { #include <despotify.h> @@ -37,7 +37,7 @@ static void add_song(std::forward_list<SongPointer> &songs, struct ds_track *track) { const char *dsp_scheme = despotify_playlist_plugin.schemes[0]; - struct song *song; + Song *song; char uri[128]; char *ds_uri; @@ -51,7 +51,7 @@ add_song(std::forward_list<SongPointer> &songs, struct ds_track *track) return; } - song = song_remote_new(uri); + song = Song::NewRemote(uri); song->tag = mpd_despotify_tag_from_track(track); songs.emplace_front(song); diff --git a/src/playlist/EmbeddedCuePlaylistPlugin.cxx b/src/playlist/EmbeddedCuePlaylistPlugin.cxx index eaedc738f..b88e4ae8c 100644 --- a/src/playlist/EmbeddedCuePlaylistPlugin.cxx +++ b/src/playlist/EmbeddedCuePlaylistPlugin.cxx @@ -28,7 +28,7 @@ #include "PlaylistPlugin.hxx" #include "tag.h" #include "tag_handler.h" -#include "song.h" +#include "Song.hxx" #include "TagFile.hxx" #include "cue/CueParser.hxx" @@ -128,12 +128,12 @@ embcue_playlist_close(struct playlist_provider *_playlist) g_free(playlist); } -static struct song * +static Song * embcue_playlist_read(struct playlist_provider *_playlist) { struct embcue_playlist *playlist = (struct embcue_playlist *)_playlist; - struct song *song = playlist->parser->Get(); + Song *song = playlist->parser->Get(); if (song != NULL) return song; @@ -152,13 +152,13 @@ embcue_playlist_read(struct playlist_provider *_playlist) playlist->parser->Feed(line); song = playlist->parser->Get(); if (song != NULL) - return song_replace_uri(song, playlist->filename); + return song->ReplaceURI(playlist->filename); } playlist->parser->Finish(); song = playlist->parser->Get(); if (song != NULL) - song = song_replace_uri(song, playlist->filename); + song = song->ReplaceURI(playlist->filename); return song; } diff --git a/src/playlist/ExtM3uPlaylistPlugin.cxx b/src/playlist/ExtM3uPlaylistPlugin.cxx index 923536ea9..72be308a1 100644 --- a/src/playlist/ExtM3uPlaylistPlugin.cxx +++ b/src/playlist/ExtM3uPlaylistPlugin.cxx @@ -20,7 +20,7 @@ #include "config.h" #include "ExtM3uPlaylistPlugin.hxx" #include "PlaylistPlugin.hxx" -#include "song.h" +#include "Song.hxx" #include "tag.h" #include "util/StringUtil.hxx" #include "TextInputStream.hxx" @@ -105,14 +105,14 @@ extm3u_parse_tag(const char *line) return tag; } -static struct song * +static Song * extm3u_read(struct playlist_provider *_playlist) { ExtM3uPlaylist *playlist = (ExtM3uPlaylist *)_playlist; struct tag *tag = NULL; std::string line; const char *line_s; - struct song *song; + Song *song; do { if (!playlist->tis->ReadLine(line)) { @@ -134,7 +134,7 @@ extm3u_read(struct playlist_provider *_playlist) ++line_s; } while (line_s[0] == '#' || *line_s == 0); - song = song_remote_new(line_s); + song = Song::NewRemote(line_s); song->tag = tag; return song; } diff --git a/src/playlist/LastFMPlaylistPlugin.cxx b/src/playlist/LastFMPlaylistPlugin.cxx index 496388407..b4933e6a3 100644 --- a/src/playlist/LastFMPlaylistPlugin.cxx +++ b/src/playlist/LastFMPlaylistPlugin.cxx @@ -22,7 +22,7 @@ #include "PlaylistPlugin.hxx" #include "PlaylistRegistry.hxx" #include "conf.h" -#include "song.h" +#include "Song.hxx" #include "input_stream.h" #include <glib.h> @@ -268,7 +268,7 @@ lastfm_close(struct playlist_provider *_playlist) g_free(playlist); } -static struct song * +static Song * lastfm_read(struct playlist_provider *_playlist) { struct lastfm_playlist *playlist = (struct lastfm_playlist *)_playlist; diff --git a/src/playlist/M3uPlaylistPlugin.cxx b/src/playlist/M3uPlaylistPlugin.cxx index e1e0a803b..ee61baa7b 100644 --- a/src/playlist/M3uPlaylistPlugin.cxx +++ b/src/playlist/M3uPlaylistPlugin.cxx @@ -20,7 +20,7 @@ #include "config.h" #include "M3uPlaylistPlugin.hxx" #include "PlaylistPlugin.hxx" -#include "song.h" +#include "Song.hxx" #include "TextInputStream.hxx" #include <glib.h> @@ -51,7 +51,7 @@ m3u_close(struct playlist_provider *_playlist) g_free(playlist); } -static struct song * +static Song * m3u_read(struct playlist_provider *_playlist) { M3uPlaylist *playlist = (M3uPlaylist *)_playlist; @@ -68,7 +68,7 @@ m3u_read(struct playlist_provider *_playlist) ++line_s; } while (line_s[0] == '#' || *line_s == 0); - return song_remote_new(line_s); + return Song::NewRemote(line_s); } static const char *const m3u_suffixes[] = { diff --git a/src/playlist/MemoryPlaylistProvider.cxx b/src/playlist/MemoryPlaylistProvider.cxx index 4fe3d6cef..c2b6d9312 100644 --- a/src/playlist/MemoryPlaylistProvider.cxx +++ b/src/playlist/MemoryPlaylistProvider.cxx @@ -19,7 +19,7 @@ #include "config.h" #include "MemoryPlaylistProvider.hxx" -#include "song.h" +#include "Song.hxx" static void memory_playlist_close(struct playlist_provider *_playlist) @@ -29,7 +29,7 @@ memory_playlist_close(struct playlist_provider *_playlist) delete playlist; } -static struct song * +static Song * memory_playlist_read(struct playlist_provider *_playlist) { MemoryPlaylistProvider *playlist = (MemoryPlaylistProvider *)_playlist; @@ -57,7 +57,7 @@ MemoryPlaylistProvider::MemoryPlaylistProvider(std::forward_list<SongPointer> && playlist_provider_init(this, &memory_playlist_plugin); } -inline song * +inline Song * MemoryPlaylistProvider::Read() { if (songs.empty()) diff --git a/src/playlist/MemoryPlaylistProvider.hxx b/src/playlist/MemoryPlaylistProvider.hxx index 246ffd10a..efbc46fe1 100644 --- a/src/playlist/MemoryPlaylistProvider.hxx +++ b/src/playlist/MemoryPlaylistProvider.hxx @@ -25,7 +25,7 @@ #include <forward_list> -struct song; +struct Song; class MemoryPlaylistProvider : public playlist_provider { std::forward_list<SongPointer> songs; @@ -33,7 +33,7 @@ class MemoryPlaylistProvider : public playlist_provider { public: MemoryPlaylistProvider(std::forward_list<SongPointer> &&_songs); - song *Read(); + Song *Read(); }; #endif diff --git a/src/playlist/PlsPlaylistPlugin.cxx b/src/playlist/PlsPlaylistPlugin.cxx index faa7212f3..268211b59 100644 --- a/src/playlist/PlsPlaylistPlugin.cxx +++ b/src/playlist/PlsPlaylistPlugin.cxx @@ -21,7 +21,7 @@ #include "PlsPlaylistPlugin.hxx" #include "MemoryPlaylistProvider.hxx" #include "input_stream.h" -#include "song.h" +#include "Song.hxx" #include "tag.h" #include <glib.h> @@ -50,7 +50,7 @@ pls_parser(GKeyFile *keyfile, std::forward_list<SongPointer> &songs) } while (num_entries > 0) { - struct song *song; + Song *song; key = g_strdup_printf("File%i", num_entries); value = g_key_file_get_string(keyfile, "playlist", key, &error); @@ -62,7 +62,7 @@ pls_parser(GKeyFile *keyfile, std::forward_list<SongPointer> &songs) } g_free(key); - song = song_remote_new(value); + song = Song::NewRemote(value); g_free(value); key = g_strdup_printf("Title%i", num_entries); diff --git a/src/playlist/RssPlaylistPlugin.cxx b/src/playlist/RssPlaylistPlugin.cxx index 3b69202e6..f96b54ae3 100644 --- a/src/playlist/RssPlaylistPlugin.cxx +++ b/src/playlist/RssPlaylistPlugin.cxx @@ -21,7 +21,7 @@ #include "RssPlaylistPlugin.hxx" #include "MemoryPlaylistProvider.hxx" #include "input_stream.h" -#include "song.h" +#include "Song.hxx" #include "tag.h" #include <glib.h> @@ -60,7 +60,7 @@ struct RssParser { * The current song. It is allocated after the "location" * element. */ - struct song *song; + Song *song; RssParser() :state(ROOT) {} @@ -90,7 +90,7 @@ rss_start_element(G_GNUC_UNUSED GMarkupParseContext *context, case RssParser::ROOT: if (g_ascii_strcasecmp(element_name, "item") == 0) { parser->state = RssParser::ITEM; - parser->song = song_remote_new("rss:"); + parser->song = Song::NewRemote("rss:"); parser->tag = TAG_NUM_OF_ITEM_TYPES; } @@ -107,12 +107,12 @@ rss_start_element(G_GNUC_UNUSED GMarkupParseContext *context, replace the existing song's URI, because that attribute is immutable */ - struct song *song = song_remote_new(href); + Song *song = Song::NewRemote(href); if (parser->song != NULL) { song->tag = parser->song->tag; parser->song->tag = NULL; - song_free(parser->song); + parser->song->Free(); } parser->song = song; @@ -142,7 +142,7 @@ rss_end_element(G_GNUC_UNUSED GMarkupParseContext *context, if (strcmp(parser->song->uri, "rss:") != 0) parser->songs.emplace_front(parser->song); else - song_free(parser->song); + parser->song->Free(); parser->state = RssParser::ROOT; } else @@ -189,7 +189,7 @@ rss_parser_destroy(gpointer data) RssParser *parser = (RssParser *)data; if (parser->state >= RssParser::ITEM) - song_free(parser->song); + parser->song->Free(); } /* diff --git a/src/playlist/SoundCloudPlaylistPlugin.cxx b/src/playlist/SoundCloudPlaylistPlugin.cxx index 5a258865c..7c93a57b3 100644 --- a/src/playlist/SoundCloudPlaylistPlugin.cxx +++ b/src/playlist/SoundCloudPlaylistPlugin.cxx @@ -22,7 +22,7 @@ #include "MemoryPlaylistProvider.hxx" #include "conf.h" #include "input_stream.h" -#include "song.h" +#include "Song.hxx" #include "tag.h" #include <glib.h> @@ -203,12 +203,12 @@ static int handle_end_map(void *ctx) /* got_url == 1, track finished, make it into a song */ data->got_url = 0; - struct song *s; + Song *s; struct tag *t; char *u; u = g_strconcat(data->stream_url, "?client_id=", soundcloud_config.apikey, NULL); - s = song_remote_new(u); + s = Song::NewRemote(u); g_free(u); t = tag_new(); t->time = data->duration / 1000; diff --git a/src/playlist/XspfPlaylistPlugin.cxx b/src/playlist/XspfPlaylistPlugin.cxx index 0484246e3..a0bb33f1c 100644 --- a/src/playlist/XspfPlaylistPlugin.cxx +++ b/src/playlist/XspfPlaylistPlugin.cxx @@ -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(); } /* |