Skip to content
Snippets Groups Projects
Commit b4becbcc authored by Tristan Matthews's avatar Tristan Matthews
Browse files

sflphone_api: use static instead of anon. namespace

Refs #48032
parent 9f3cc70d
No related branches found
No related tags found
No related merge requests found
...@@ -51,37 +51,35 @@ ...@@ -51,37 +51,35 @@
#include "client/videomanager.h" #include "client/videomanager.h"
#endif // SFL_VIDEO #endif // SFL_VIDEO
namespace {
// This manager pointer is only set after proper library initialization. // This manager pointer is only set after proper library initialization.
ManagerImpl* _manager = nullptr; static ManagerImpl* _manager = nullptr;
CallManager* _getCallManager() static CallManager* _getCallManager()
{ {
return _manager->getClient()->getCallManager(); return _manager->getClient()->getCallManager();
} }
ConfigurationManager* _getConfigurationManager() static ConfigurationManager* _getConfigurationManager()
{ {
return _manager->getClient()->getConfigurationManager(); return _manager->getClient()->getConfigurationManager();
} }
#ifdef SFL_PRESENCE #ifdef SFL_PRESENCE
PresenceManager* _getPresenceManager() static PresenceManager* _getPresenceManager()
{ {
return _manager->getClient()->getPresenceManager(); return _manager->getClient()->getPresenceManager();
} }
#endif // SFL_PRESENCE #endif // SFL_PRESENCE
#ifdef SFL_VIDEO #ifdef SFL_VIDEO
VideoManager* _getVideoManager() static VideoManager* _getVideoManager()
{ {
return _manager->getClient()->getVideoManager(); return _manager->getClient()->getVideoManager();
} }
#endif // SFL_VIDEO #endif // SFL_VIDEO
// User handlers of library events // User handlers of library events
struct sflph_ev_handlers _evHandlers; static sflph_ev_handlers _evHandlers;
}
const char * const char *
sflph_version() sflph_version()
...@@ -89,7 +87,7 @@ sflph_version() ...@@ -89,7 +87,7 @@ sflph_version()
return PACKAGE_VERSION; return PACKAGE_VERSION;
} }
int sflph_init(struct sflph_ev_handlers* ev_handlers, enum sflph_init_flag flags) int sflph_init(sflph_ev_handlers* ev_handlers, enum sflph_init_flag flags)
{ {
// Ignore initialization if already done // Ignore initialization if already done
if (_manager) { if (_manager) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment