6 #include "sounddecoder.h"
28 void Jukebox::set_playlist(const Playlist *p)
30 bool was_playing = decoder;
33 if(playlist && was_playing)
39 if(!playlist || playlist->empty() || decoder)
42 in = playlist->open(current);
43 decoder = SoundDecoder::open_io(*in);
44 streamer.play(*decoder);
49 if(!playlist || playlist->empty())
53 current = playlist->advance(current, 1);
54 signal_track_changed.emit(current);
58 void Jukebox::previous()
60 if(!playlist || playlist->empty())
64 current = playlist->advance(current, -1);
65 signal_track_changed.emit(current);
81 if(decoder && decoder->eof())