Merge branch 'badPacketMessage'

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@1168 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
joss17 2009-05-05 13:35:36 +00:00
parent 16231dea2b
commit 698425ba9e
7 changed files with 75 additions and 1 deletions

View file

@ -55,6 +55,27 @@ bool p3Notify::NotifySysMessage(uint32_t &sysid, uint32_t &type,
return false;
}
/* Output for retroshare-gui */
bool p3Notify::NotifyLogMessage(uint32_t &sysid, uint32_t &type,
std::string &title, std::string &msg)
{
RsStackMutex stack(noteMtx); /************* LOCK MUTEX ************/
if (pendingLogMsgs.size() > 0)
{
p3NotifyLogMsg smsg = pendingLogMsgs.front();
pendingLogMsgs.pop_front();
sysid = smsg.sysid;
type = smsg.type;
title = smsg.title;
msg = smsg.msg;
return true;
}
return false;
}
bool p3Notify::NotifyPopupMessage(uint32_t &ptype, std::string &name, std::string &msg)
{
@ -132,6 +153,23 @@ bool p3Notify::AddSysMessage(uint32_t sysid, uint32_t type,
return true;
}
bool p3Notify::AddLogMessage(uint32_t sysid, uint32_t type,
std::string title, std::string msg)
{
RsStackMutex stack(noteMtx); /************* LOCK MUTEX ************/
p3NotifyLogMsg smsg;
smsg.sysid = sysid;
smsg.type = type;
smsg.title = title;
smsg.msg = msg;
pendingLogMsgs.push_back(smsg);
return true;
}
bool p3Notify::GetFeedItem(RsFeedItem &item)
{