mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-02-27 18:31:25 -05:00

* Switched p3Ranking to share Friends Links as well as own. * Modified rankmsgs to contain source id. * Fixed up rsNotify, added pqiNotify and global function call to get it. * Added notify for Bad Incoming Directory * Added Emergency Incoming directory so RS can keep running. * Added notify for Bad Packet (connecting to V0.3.X) * Added notify for Incomplete Packet Read (not been triggered yet!) * added close() to BinInterface, close on pqissl calls reset() * removed exit(1) calls from pqistreamer, replaced with bio->close(). * Increased Maximum Packet Size for HTML messages. * Fixed Online/Offline Message Forwarding. (TEST). * Increased DHT bootstrap buckets to 4. * Cleaned up much of serialiser debug (was slowing down Mac) * Added directory path to File Listings. * added ConvertSharedFilePath() so correct local dir can be found. * Added ForceDirectoryCheck() and InDirectoryCheck() for file hashing. * removed old TMP cache loading. * switched off Cache debug. git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@448 b45a01b8-16f6-495d-af2f-9b41ad6348cc
88 lines
2.2 KiB
C++
88 lines
2.2 KiB
C++
#ifndef RS_P3_NOTIFY_INTERFACE_H
|
|
#define RS_P3_NOTIFY_INTERFACE_H
|
|
|
|
/*
|
|
* libretroshare/src/rsserver: p3notify.h
|
|
*
|
|
* RetroShare C++ Interface.
|
|
*
|
|
* Copyright 2007-2008 by Robert Fernie.
|
|
*
|
|
* This library is free software; you can redistribute it and/or
|
|
* modify it under the terms of the GNU Library General Public
|
|
* License Version 2 as published by the Free Software Foundation.
|
|
*
|
|
* This library is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
* Library General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU Library General Public
|
|
* License along with this library; if not, write to the Free Software
|
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
|
|
* USA.
|
|
*
|
|
* Please report all bugs and problems to "retroshare@lunamutt.com".
|
|
*
|
|
*/
|
|
|
|
#include "rsiface/rsnotify.h"
|
|
#include "pqi/pqinotify.h"
|
|
|
|
#include "util/rsthreads.h"
|
|
|
|
class p3NotifySysMsg
|
|
{
|
|
public:
|
|
|
|
uint32_t sysid;
|
|
uint32_t type;
|
|
std::string title;
|
|
std::string msg;
|
|
};
|
|
|
|
class p3NotifyPopupMsg
|
|
{
|
|
public:
|
|
|
|
uint32_t type;
|
|
std::string name;
|
|
std::string msg;
|
|
};
|
|
|
|
|
|
class p3Notify: public RsNotify, public pqiNotify
|
|
{
|
|
public:
|
|
|
|
p3Notify() { return; }
|
|
virtual ~p3Notify() { return; }
|
|
|
|
/* Output for retroshare-gui */
|
|
virtual bool NotifySysMessage(uint32_t &sysid, uint32_t &type,
|
|
std::string &title, std::string &msg);
|
|
virtual bool NotifyPopupMessage(uint32_t &ptype, std::string &name, std::string &msg);
|
|
|
|
/* Control over Messages */
|
|
virtual bool GetSysMessageList(std::map<uint32_t, std::string> &list);
|
|
virtual bool GetPopupMessageList(std::map<uint32_t, std::string> &list);
|
|
|
|
virtual bool SetSysMessageMode(uint32_t sysid, uint32_t mode);
|
|
virtual bool SetPopupMessageMode(uint32_t ptype, uint32_t mode);
|
|
|
|
|
|
/* Overloaded from pqiNotify */
|
|
virtual bool AddPopupMessage(uint32_t ptype, std::string name, std::string msg);
|
|
virtual bool AddSysMessage(uint32_t sysid, uint32_t type, std::string title, std::string msg);
|
|
|
|
private:
|
|
|
|
RsMutex noteMtx;
|
|
|
|
std::list<p3NotifySysMsg> pendingSysMsgs;
|
|
std::list<p3NotifyPopupMsg> pendingPopupMsgs;
|
|
};
|
|
|
|
|
|
#endif
|