diff options
author | George Hazan <ghazan@miranda.im> | 2018-05-20 15:08:48 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2018-05-20 15:08:48 +0300 |
commit | 8a74e7495ce5ad39de4f5c25121a84d35df90c36 (patch) | |
tree | 03e5b4870f09a3163306740c2eebee47bc15b042 /plugins/Quotes/src | |
parent | c5bf7d6123dd1c3b82ccb8fdb1b068077e9d56d4 (diff) |
CMPlugin to receive a reference to PLUGININFOEX
Diffstat (limited to 'plugins/Quotes/src')
-rw-r--r-- | plugins/Quotes/src/Forex.cpp | 19 | ||||
-rw-r--r-- | plugins/Quotes/src/stdafx.h | 7 |
2 files changed, 13 insertions, 13 deletions
diff --git a/plugins/Quotes/src/Forex.cpp b/plugins/Quotes/src/Forex.cpp index 5d791bee55..9b7b3ffafc 100644 --- a/plugins/Quotes/src/Forex.cpp +++ b/plugins/Quotes/src/Forex.cpp @@ -3,7 +3,9 @@ #include "stdafx.h"
+CMPlugin g_plugin;
int &hLangpack(g_plugin.m_hLang);
+
HANDLE g_hEventWorkThreadStop;
//int g_nStatus = ID_STATUS_OFFLINE;
bool g_bAutoUpdate = true;
@@ -277,15 +279,11 @@ inline int Quotes_UnhookEvent(HANDLE h) /////////////////////////////////////////////////////////////////////////////////////////
-CMPlugin g_plugin;
-
-/////////////////////////////////////////////////////////////////////////////////////////
-
EXTERN_C __declspec(dllexport) const MUUID MirandaInterfaces[] = { MIID_PROTOCOL, MIID_LAST };
/////////////////////////////////////////////////////////////////////////////////////////
-PLUGININFOEX Global_pluginInfo =
+PLUGININFOEX pluginInfoEx =
{
sizeof(PLUGININFOEX),
__PLUGIN_NAME,
@@ -299,16 +297,23 @@ PLUGININFOEX Global_pluginInfo = { 0xe882056d, 0xd1d, 0x4131, { 0x9a, 0x98, 0x40, 0x4c, 0xba, 0xea, 0x6a, 0x9c } }
};
+CMPlugin::CMPlugin() :
+ PLUGIN<CMPlugin>(QUOTES_PROTOCOL_NAME, pluginInfoEx)
+{
+ RegisterProtocol(PROTOTYPE_VIRTUAL);
+ SetUniqueId(DB_STR_QUOTE_SYMBOL);
+}
+
EXTERN_C __declspec(dllexport) PLUGININFOEX* MirandaPluginInfoEx(DWORD)
{
- return &Global_pluginInfo;
+ return &pluginInfoEx;
}
/////////////////////////////////////////////////////////////////////////////////////////
EXTERN_C int __declspec(dllexport) Load(void)
{
- mir_getLP(&Global_pluginInfo);
+ mir_getLP(&pluginInfoEx);
if (false == CModuleInfo::Verify())
return 1;
diff --git a/plugins/Quotes/src/stdafx.h b/plugins/Quotes/src/stdafx.h index ea4fed341e..b8fb295aaa 100644 --- a/plugins/Quotes/src/stdafx.h +++ b/plugins/Quotes/src/stdafx.h @@ -118,10 +118,5 @@ inline tstring quotes_a2t(const char* s) struct CMPlugin : public PLUGIN<CMPlugin>
{
- CMPlugin() :
- PLUGIN<CMPlugin>(QUOTES_PROTOCOL_NAME)
- {
- RegisterProtocol(PROTOTYPE_VIRTUAL);
- SetUniqueId(DB_STR_QUOTE_SYMBOL);
- }
+ CMPlugin();
};
|