reduce usage of pointers / replace std::pair in SearchEngine

This commit is contained in:
Andrzej Rybczak
2012-08-28 02:44:08 +02:00
parent a270fc8402
commit 397783d701
17 changed files with 237 additions and 241 deletions

View File

@@ -29,20 +29,13 @@
namespace MPD
{
namespace Message
{
extern const char *PartOfSongsAdded;
extern const char *FullPlaylist;
}
enum ItemType { itDirectory, itSong, itPlaylist };
enum PlayerState { psUnknown, psStop, psPlay, psPause };
enum ReplayGainMode { rgmOff, rgmTrack, rgmAlbum };
struct Item
{
Item() : song(0) { }
Song *song;
Song song;
ItemType type;
std::string name;
};
@@ -69,13 +62,10 @@ namespace MPD
typedef std::pair<std::string, bool> Output;
typedef std::vector<Item> ItemList;
typedef std::vector<Song *> SongList;
typedef std::vector<Song> SongList;
typedef std::vector<std::string> TagList;
typedef std::vector<Output> OutputList;
void FreeSongList(SongList &);
void FreeItemList(ItemList &);
class Connection
{
typedef void (*StatusUpdater) (Connection *, StatusChanges, void *);