summaryrefslogtreecommitdiff
path: root/server/include/api_core_events.h
diff options
context:
space:
mode:
authorGluzskiy Alexandr <sss@sss.chaoslab.ru>2016-01-20 05:35:09 +0300
committerGluzskiy Alexandr <sss@sss.chaoslab.ru>2016-01-20 05:35:09 +0300
commit09a905e401df451f12673d75dc8d4d72ee73b7c9 (patch)
tree75e620ca41dd673f9286f3351f2982c2bbfc51e1 /server/include/api_core_events.h
parentbb8cd8a9ff7d80046cc2c7d41742c74d8f811c62 (diff)
server:
very basic implementation of download_state_changed event api call for plugins started work on thread safety (plugins may and will be multithreaded, so api for plugins should be thread safe)
Diffstat (limited to 'server/include/api_core_events.h')
-rw-r--r--server/include/api_core_events.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/server/include/api_core_events.h b/server/include/api_core_events.h
index e7e0dac..072ec45 100644
--- a/server/include/api_core_events.h
+++ b/server/include/api_core_events.h
@@ -21,15 +21,24 @@
#ifndef API_CORE_EVENTS_H
#define API_CORE_EVENTS_H
+class module_base;
+
namespace core_events
{
enum download_state {download_stopped, download_running, download_completed, download_error};
+struct download_state_info
+{
+ int download_id;
+ download_state state;
+};
+
+
class core_events
{
public:
- virtual void download_state_changed(int download_id, download_state state);
+ virtual void download_state_changed(module_base *m, std::list<download_state_info> state_list);
};
};