diff options
author | Max Kellermann <max@duempel.org> | 2014-01-07 21:39:47 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2014-01-09 09:05:58 +0100 |
commit | 322b0616322760dc162447563d8f4da7e024ca90 (patch) | |
tree | 2f87cb3ce061556161797aba9f57ee08de5b9e21 /src/DecoderControl.hxx | |
parent | 43847f2244a34064af24704aac4cfad4a3c76f7d (diff) | |
download | mpd-322b0616322760dc162447563d8f4da7e024ca90.tar.gz mpd-322b0616322760dc162447563d8f4da7e024ca90.tar.xz mpd-322b0616322760dc162447563d8f4da7e024ca90.zip |
DetachedSong: fork of struct Song
From now on, struct Song will be used by the database only, and
DetachedSong will be used by everybody else. DetachedSong is easier
to use, but Song has lower overhead.
Diffstat (limited to 'src/DecoderControl.hxx')
-rw-r--r-- | src/DecoderControl.hxx | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/DecoderControl.hxx b/src/DecoderControl.hxx index 863398dca..bacdad347 100644 --- a/src/DecoderControl.hxx +++ b/src/DecoderControl.hxx @@ -36,7 +36,7 @@ #undef ERROR #endif -struct Song; +class DetachedSong; class MusicBuffer; class MusicPipe; @@ -123,7 +123,7 @@ struct DecoderControl { * This is a duplicate, and must be freed when this attribute * is cleared. */ - Song *song; + DetachedSong *song; /** * The initial seek position (in milliseconds), e.g. to the @@ -293,10 +293,10 @@ struct DecoderControl { * Caller must lock the object. */ gcc_pure - bool IsCurrentSong(const Song &_song) const; + bool IsCurrentSong(const DetachedSong &_song) const; gcc_pure - bool LockIsCurrentSong(const Song &_song) const { + bool LockIsCurrentSong(const DetachedSong &_song) const { Lock(); const bool result = IsCurrentSong(_song); Unlock(); @@ -360,7 +360,7 @@ public: * @param pipe the pipe which receives the decoded chunks (owned by * the caller) */ - void Start(Song *song, unsigned start_ms, unsigned end_ms, + void Start(DetachedSong *song, unsigned start_ms, unsigned end_ms, MusicBuffer &buffer, MusicPipe &pipe); void Stop(); |