From 95fa1951781f7fea87830ae78983956d2b288331 Mon Sep 17 00:00:00 2001 From: Gluzskiy Alexandr Date: Sat, 30 Oct 2010 19:13:35 +0300 Subject: new file: core/basic-services.cpp modified: core/commonheaders.h new file: core/constants.h modified: core/main.cpp modified: core/services.h --- core/basic-services.cpp | 12 ++++++++++++ core/commonheaders.h | 4 +++- core/constants.h | 1 + core/main.cpp | 3 --- core/services.h | 5 +++++ 5 files changed, 21 insertions(+), 4 deletions(-) create mode 100644 core/basic-services.cpp create mode 100644 core/constants.h diff --git a/core/basic-services.cpp b/core/basic-services.cpp new file mode 100644 index 0000000..3774007 --- /dev/null +++ b/core/basic-services.cpp @@ -0,0 +1,12 @@ +#include "commonheaders.h" + +SERVICE get_version(void*) +{ + return 0; +} + + +void register_core_services() +{ + CreateServiceFunction("EC/GetVersionInt", (SERVICE)get_version); +} diff --git a/core/commonheaders.h b/core/commonheaders.h index 6528473..7815095 100644 --- a/core/commonheaders.h +++ b/core/commonheaders.h @@ -17,7 +17,9 @@ #include //utf8cpp #include "include/utf8cpp/utf8.h" - + +//ec +#include "constants.h" #include "../api/ec_pluginapi.h" #include "services.h" #include "modules.h" diff --git a/core/constants.h b/core/constants.h new file mode 100644 index 0000000..edce9aa --- /dev/null +++ b/core/constants.h @@ -0,0 +1 @@ +const unsigned long ec_version = 0x00000001; \ No newline at end of file diff --git a/core/main.cpp b/core/main.cpp index 5a27e20..36b6f92 100644 --- a/core/main.cpp +++ b/core/main.cpp @@ -5,9 +5,6 @@ std::list plugins; boost::mutex plugin_list_mutex; std::list services; boost::mutex service_list_mutex; -void CreateServiceFunction(const char* name, SERVICE svc); -void* CallService(const char *,void*); -int ServiceExists(const char *); ACE_Log_Msg logger; diff --git a/core/services.h b/core/services.h index a915294..c498fc4 100644 --- a/core/services.h +++ b/core/services.h @@ -13,4 +13,9 @@ private: SERVICE pService; }; +void CreateServiceFunction(const char* name, SERVICE svc); +void* CallService(const char *,void*); +int ServiceExists(const char *); + + #endif // SERVICES_H_INCLUDED -- cgit v1.2.3