mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-06-28 16:17:28 -04:00
proper handling of peer connections notifications
This commit is contained in:
parent
98e41ad075
commit
15e43dce01
10 changed files with 97 additions and 34 deletions
|
@ -477,12 +477,24 @@ void p3LinkMgrIMPL::tickMonitors()
|
|||
if (peer.actions & RS_PEER_CONNECTED)
|
||||
{
|
||||
p3Notify *notify = RsServer::notify();
|
||||
|
||||
if (notify)
|
||||
{
|
||||
// normally these two below should disappear: there's no notion of popup in libretroshare.
|
||||
// all GUI-type display features should be chosen in NotifyQt.
|
||||
notify->AddPopupMessage(RS_POPUP_CONNECT, peer.id.toStdString(),"", "Online: ");
|
||||
notify->AddFeedItem(RS_FEED_ITEM_PEER_CONNECT, peer.id.toStdString());
|
||||
|
||||
notify->notifyPeerConnected(peer.id.toStdString());
|
||||
}
|
||||
}
|
||||
if (peer.actions & RS_PEER_DISCONNECTED)
|
||||
{
|
||||
p3Notify *notify = RsServer::notify();
|
||||
|
||||
if (notify)
|
||||
notify->notifyPeerDisconnected(peer.id.toStdString());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue