X-Git-Url: http://git.tdb.fi/?p=xinema.git;a=blobdiff_plain;f=source%2Fclient.cpp;h=f042c66b020b70d31e0c0348c098c25a04540321;hp=f116892a06b1073401a5c1683007935f29b9bd97;hb=3bd92c1fa7a85b47356cd6f2bad23893955a0785;hpb=6fd809bbdbfe628ef1e63b68665f374751838baf diff --git a/source/client.cpp b/source/client.cpp index f116892..f042c66 100644 --- a/source/client.cpp +++ b/source/client.cpp @@ -90,6 +90,7 @@ void Client::list_directory(const FS::Path &dn) void Client::stream_created(XineStream &stream) { + stream.signal_title_changed.connect(sigc::mem_fun(this, &Client::stream_title_changed)); stream.signal_duration_changed.connect(sigc::mem_fun(this, &Client::stream_duration_changed)); stream.signal_position_changed.connect(sigc::mem_fun(this, &Client::stream_position_changed)); string title = stream.get_title(); @@ -97,6 +98,11 @@ void Client::stream_created(XineStream &stream) send_reply("title "+title); } +void Client::stream_title_changed(const string &title) +{ + send_reply("title "+title); +} + void Client::stream_duration_changed(const Time::TimeDelta &dur) { send_reply(format("duration %.3f", dur/Time::sec));