diff options
Diffstat (limited to 'plugins/ConnectionNotify/src/ConnectionNotify.cpp')
-rw-r--r-- | plugins/ConnectionNotify/src/ConnectionNotify.cpp | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/plugins/ConnectionNotify/src/ConnectionNotify.cpp b/plugins/ConnectionNotify/src/ConnectionNotify.cpp index cb1e82dbec..a703a9f5a2 100644 --- a/plugins/ConnectionNotify/src/ConnectionNotify.cpp +++ b/plugins/ConnectionNotify/src/ConnectionNotify.cpp @@ -859,13 +859,7 @@ extern "C" int __declspec(dllexport) Load(void) LoadSettings();
connExceptions = LoadSettingsConnections();
- PROTOCOLDESCRIPTOR pd = { 0 };
- pd.cbSize = sizeof(pd);
- pd.szName = PLUGINNAME;
- pd.type = PROTOTYPE_PROTOCOL;
- Proto_RegisterModule(&pd);
-
- //set all contacts to offline
+ // set all contacts to offline
for (auto &hContact : Contacts(PLUGINNAME))
db_set_w(hContact, PLUGINNAME, "status", ID_STATUS_OFFLINE);
@@ -903,3 +897,15 @@ extern "C" int __declspec(dllexport) Unload(void) #endif
return 0;
}
+
+/////////////////////////////////////////////////////////////////////////////////////////
+
+struct CMPlugin : public CMPluginBase
+{
+ CMPlugin() :
+ CMPluginBase(PLUGINNAME)
+ {
+ RegisterProtocol(PROTOTYPE_PROTOCOL);
+ }
+}
+ g_plugin;
|