vlc | branch: master | Steve Lhomme <[email protected]> | Mon Mar 21 14:47:33 2016 +0100| [cd34e418962f3a3ee04a082d3196228c6f2b6a2d] | committer: Jean-Baptiste Kempf
chromecast: use a generic method to send messages on the player namespace > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=cd34e418962f3a3ee04a082d3196228c6f2b6a2d --- modules/stream_out/chromecast/chromecast.h | 2 ++ modules/stream_out/chromecast/chromecast_ctrl.cpp | 7 ++++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/modules/stream_out/chromecast/chromecast.h b/modules/stream_out/chromecast/chromecast.h index ddba2c2..6864434 100644 --- a/modules/stream_out/chromecast/chromecast.h +++ b/modules/stream_out/chromecast/chromecast.h @@ -121,6 +121,8 @@ private: const std::string & destinationId = DEFAULT_CHOMECAST_RECEIVER, castchannel::CastMessage_PayloadType payloadType = castchannel::CastMessage_PayloadType_STRING); + void pushMediaPlayerMessage(const std::stringstream & payload); + enum connection_status conn_status; unsigned i_receiver_requestId; diff --git a/modules/stream_out/chromecast/chromecast_ctrl.cpp b/modules/stream_out/chromecast/chromecast_ctrl.cpp index 384bbac..f39acc3 100644 --- a/modules/stream_out/chromecast/chromecast_ctrl.cpp +++ b/modules/stream_out/chromecast/chromecast_ctrl.cpp @@ -703,7 +703,7 @@ void intf_sys_t::msgPlayerLoad() free(psz_mime); - buildMessage(NAMESPACE_MEDIA, ss.str(), appTransportId); + pushMediaPlayerMessage( ss ); } /** @@ -734,6 +734,11 @@ int intf_sys_t::sendMessage(const castchannel::CastMessage &msg) return VLC_EGENERIC; } +void intf_sys_t::pushMediaPlayerMessage(const std::stringstream & payload) { + assert(!appTransportId.empty()); + buildMessage( NAMESPACE_MEDIA, payload.str(), appTransportId ); +} + /***************************************************************************** * Chromecast thread *****************************************************************************/ _______________________________________________ vlc-commits mailing list [email protected] https://mailman.videolan.org/listinfo/vlc-commits
