summaryrefslogtreecommitdiff
path: root/plugins/Db_autobackups/src/main.cpp
diff options
context:
space:
mode:
authorMataes <mataes2007@gmail.com>2018-05-16 21:12:31 +0300
committerMataes <mataes2007@gmail.com>2018-05-16 21:12:31 +0300
commit1fc8e65dd319abf0bac6ce753bb87ecbabd8b177 (patch)
tree94aaf74e14515883aea9da6752ccacca6007fa47 /plugins/Db_autobackups/src/main.cpp
parentaba882ecf1f570400c301493725fcb31270e0fd5 (diff)
Flags, CrashDumper, CryptoPP, CSList, Db_autobackups, DbEditorPP: cmplugin adaptation
Diffstat (limited to 'plugins/Db_autobackups/src/main.cpp')
-rw-r--r--plugins/Db_autobackups/src/main.cpp10
1 files changed, 2 insertions, 8 deletions
diff --git a/plugins/Db_autobackups/src/main.cpp b/plugins/Db_autobackups/src/main.cpp
index 561e31dfeb..ceb612aac9 100644
--- a/plugins/Db_autobackups/src/main.cpp
+++ b/plugins/Db_autobackups/src/main.cpp
@@ -1,7 +1,7 @@
#include "stdafx.h"
+CMPlugin g_plugin;
int hLangpack;
-HINSTANCE g_hInstance;
HANDLE hFolder;
char g_szMirVer[100];
@@ -18,12 +18,6 @@ PLUGININFOEX pluginInfo = {
{ 0x81c220a6, 0x226, 0x4ad6, { 0xbf, 0xca, 0x21, 0x7b, 0x17, 0xa1, 0x60, 0x53 } }
};
-BOOL WINAPI DllMain(HINSTANCE hInstance, DWORD, LPVOID)
-{
- g_hInstance = hInstance;
- return TRUE;
-}
-
static INT_PTR ABService(WPARAM, LPARAM)
{
BackupStart(nullptr);
@@ -122,7 +116,7 @@ extern "C" __declspec(dllexport) int Load(void)
HookEvent(ME_SYSTEM_PRESHUTDOWN, PreShutdown);
HookEvent(ME_SYSTEM_MODULESLOADED, ModulesLoad);
- Icon_Register(g_hInstance, LPGEN("Database") "/" LPGEN("Database backups"), iconList, _countof(iconList));
+ Icon_Register(g_plugin.getInst(), LPGEN("Database") "/" LPGEN("Database backups"), iconList, _countof(iconList));
CreateServiceFunction(MS_AB_BACKUP, ABService);
CreateServiceFunction(MS_AB_SAVEAS, DBSaveAs);