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 /protocols/Steam | |
parent | c5bf7d6123dd1c3b82ccb8fdb1b068077e9d56d4 (diff) |
CMPlugin to receive a reference to PLUGININFOEX
Diffstat (limited to 'protocols/Steam')
-rw-r--r-- | protocols/Steam/src/main.cpp | 19 | ||||
-rw-r--r-- | protocols/Steam/src/steam_proto.h | 6 |
2 files changed, 13 insertions, 12 deletions
diff --git a/protocols/Steam/src/main.cpp b/protocols/Steam/src/main.cpp index cbe75d5100..1b7be830aa 100644 --- a/protocols/Steam/src/main.cpp +++ b/protocols/Steam/src/main.cpp @@ -1,10 +1,13 @@ #include "stdafx.h"
+CMPlugin g_plugin;
int &hLangpack(g_plugin.m_hLang);
HANDLE hExtraXStatus;
-PLUGININFOEX pluginInfo =
+/////////////////////////////////////////////////////////////////////////////////////////
+
+PLUGININFOEX pluginInfoEx =
{
sizeof(PLUGININFOEX),
__PLUGIN_NAME,
@@ -18,14 +21,16 @@ PLUGININFOEX pluginInfo = { 0x68f5a030, 0xba32, 0x48ec, { 0x95, 0x7, 0x5c, 0x2f, 0xbd, 0xea, 0x52, 0x17 }}
};
-extern "C" __declspec(dllexport) PLUGININFOEX* MirandaPluginInfoEx(DWORD)
+CMPlugin::CMPlugin() :
+ ACCPROTOPLUGIN<CSteamProto>("STEAM", pluginInfoEx)
{
- return &pluginInfo;
+ SetUniqueId("SteamID");
}
-/////////////////////////////////////////////////////////////////////////////////////////
-
-CMPlugin g_plugin;
+extern "C" __declspec(dllexport) PLUGININFOEX* MirandaPluginInfoEx(DWORD)
+{
+ return &pluginInfoEx;
+}
/////////////////////////////////////////////////////////////////////////////////////////
@@ -35,7 +40,7 @@ extern "C" __declspec(dllexport) const MUUID MirandaInterfaces[] = { MIID_PROTOC extern "C" int __declspec(dllexport) Load(void)
{
- mir_getLP(&pluginInfo);
+ mir_getLP(&pluginInfoEx);
char iconName[100];
mir_snprintf(iconName, "%s_%s", MODULE, "gaming");
diff --git a/protocols/Steam/src/steam_proto.h b/protocols/Steam/src/steam_proto.h index 4298d45737..39c1b7a2be 100644 --- a/protocols/Steam/src/steam_proto.h +++ b/protocols/Steam/src/steam_proto.h @@ -276,11 +276,7 @@ protected: struct CMPlugin : public ACCPROTOPLUGIN<CSteamProto>
{
- CMPlugin() :
- ACCPROTOPLUGIN<CSteamProto>("STEAM")
- {
- SetUniqueId("SteamID");
- }
+ CMPlugin();
};
int OnReloadIcons(WPARAM wParam, LPARAM lParam);
|