updated GUI for new distant chat

This commit is contained in:
csoler 2015-11-26 20:40:06 -05:00
parent 26f4523f5f
commit a2e0f4196b
17 changed files with 215 additions and 1214 deletions

View file

@ -523,15 +523,15 @@ void p3Msgs::getPendingChatLobbyInvites(std::list<ChatLobbyInvite>& invites)
{
mChatSrv->getPendingChatLobbyInvites(invites) ;
}
bool p3Msgs::initiateDistantChatConnexion(const RsGxsId& to_gxs_id,const RsGxsId& from_gxs_id,uint32_t& error_code)
bool p3Msgs::initiateDistantChatConnexion(const RsGxsId& to_gxs_id,const RsGxsId& from_gxs_id,DistantChatPeerId& pid,uint32_t& error_code)
{
return mChatSrv->initiateDistantChatConnexion(to_gxs_id,from_gxs_id,error_code) ;
return mChatSrv->initiateDistantChatConnexion(to_gxs_id,from_gxs_id,pid,error_code) ;
}
bool p3Msgs::getDistantChatStatus(const RsGxsId &gxs_id,uint32_t &status,RsGxsId *from_gxs_id)
bool p3Msgs::getDistantChatStatus(const DistantChatPeerId& pid,DistantChatPeerInfo& info)
{
return mChatSrv->getDistantChatStatus(gxs_id,status,from_gxs_id) ;
return mChatSrv->getDistantChatStatus(pid,info) ;
}
bool p3Msgs::closeDistantChatConnexion(const RsGxsId& pid)
bool p3Msgs::closeDistantChatConnexion(const DistantChatPeerId &pid)
{
return mChatSrv->closeDistantChatConnexion(pid) ;
}

View file

@ -155,9 +155,9 @@ class p3Msgs: public RsMsgs
virtual bool getLobbyAutoSubscribe(const ChatLobbyId& lobby_id);
virtual ChatLobbyId createChatLobby(const std::string& lobby_name,const RsGxsId& lobby_identity,const std::string& lobby_topic,const std::set<RsPeerId>& invited_friends,ChatLobbyFlags privacy_type) ;
virtual bool initiateDistantChatConnexion(const RsGxsId& to_gxs_id,const RsGxsId& from_gxs_id,uint32_t& error_code) ;
virtual bool getDistantChatStatus(const RsGxsId& gxs_id,uint32_t& status, RsGxsId *from_gxs_id=NULL) ;
virtual bool closeDistantChatConnexion(const RsGxsId &pid) ;
virtual bool initiateDistantChatConnexion(const RsGxsId& to_gxs_id, const RsGxsId& from_gxs_id, DistantChatPeerId &pid, uint32_t& error_code) ;
virtual bool getDistantChatStatus(const DistantChatPeerId& gxs_id,DistantChatPeerInfo& info);
virtual bool closeDistantChatConnexion(const DistantChatPeerId &pid) ;
private:

View file

@ -56,6 +56,8 @@
#include <openssl/rand.h>
#include <fcntl.h>
#include <gxstunnel/p3gxstunnel.h>
#define ENABLE_GROUTER
#if (defined(__unix__) || defined(unix)) && !defined(USG)
@ -1472,13 +1474,16 @@ int RsServer::StartupRetroShare()
pqih -> addService(tr,true);
pqih -> addService(ftserver,true);
p3GxsTunnelService *gxs_tunnels = new p3GxsTunnelService() ;
rsGxsTunnels = gxs_tunnels;
rsDisc = mDisc;
rsMsgs = new p3Msgs(msgSrv, chatSrv);
// connect components to turtle router.
ftserver->connectToTurtleRouter(tr) ;
chatSrv->connectToTurtleRouter(tr) ;
chatSrv->connectToxsTunnelService(gxs_tunnels) ;
gr->connectToTurtleRouter(tr) ;
#ifdef ENABLE_GROUTER
msgSrv->connectToGlobalRouter(gr) ;
@ -1489,8 +1494,7 @@ int RsServer::StartupRetroShare()
pqih -> addService(mDisc,true);
pqih -> addService(msgSrv,true);
pqih -> addService(chatSrv,true);
pqih -> addService(mStatusSrv,true);
pqih -> addService(mStatusSrv,true);
// set interfaces for plugins
//