Repository navigation
Expand file tree
/
Copy pathLua4RSNotify.h
More file actions
38 lines (32 loc) · 1.68 KB
/
Copy pathLua4RSNotify.h
File metadata and controls
38 lines (32 loc) · 1.68 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#ifndef LUA4RSNOTIFY_H
#define LUA4RSNOTIFY_H
#include <retroshare/rschats.h>
#include <retroshare/rsfiles.h>
#include <retroshare/rsevents.h>
class Lua4RSNotify
{
public:
Lua4RSNotify();
~Lua4RSNotify();
void start();
void stop();
// Legacy Lua event adapters
public:
void notifyListPreChange (int /* list */, int /* type */);
void notifyListChange (int /* list */, int /* type */);
void notifyChatMessage (const ChatMessage& /* msg */);
void notifyChatLobbyEvent (uint64_t /* lobby id */, uint32_t /* event type */, const RsGxsId& /* nickname */, const std::string& /* any string */);
void notifyCustomState (const std::string& /* peer_id */, const std::string& /* status_string */);
void notifyHashingInfo (uint32_t /* type */, const std::string& /* fileinfo */);
void notifyTurtleSearchResult (uint32_t search_id, const std::vector<TurtleFileInfoV2>& files);
void notifyDiskFull (uint32_t /* location */, uint32_t /* size limit in MB */);
void notifyPeerStatusChanged (const std::string& /* peer_id */, uint32_t /* status */);
/* one or more peers has changed the states */
void notifyPeerStatusChangedSummary ();
void notifyDiscInfoChanged ();
void notifyDownloadComplete (const std::string& /* fileHash */);
private:
void handleEvent(std::shared_ptr<const RsEvent> event);
RsEventsHandlerId_t _handlerId = 0;
};
#endif // LUA4RSNOTIFY_H