summaryrefslogtreecommitdiff
path: root/plugins/Dbx_tree/Compatibility.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2012-07-04 12:37:38 +0000
committerGeorge Hazan <george.hazan@gmail.com>2012-07-04 12:37:38 +0000
commit88ec2ae53ddc811d08763b2fb3a0073b571a321c (patch)
tree8a2048209c9494d55ca8d565d1942833e8bff230 /plugins/Dbx_tree/Compatibility.cpp
parentfd97f5275ed5f18651c4cb7d7de397fbd5edf226 (diff)
these fixes aren't needed anymore
git-svn-id: http://svn.miranda-ng.org/main/trunk@755 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Dbx_tree/Compatibility.cpp')
-rw-r--r--plugins/Dbx_tree/Compatibility.cpp20
1 files changed, 4 insertions, 16 deletions
diff --git a/plugins/Dbx_tree/Compatibility.cpp b/plugins/Dbx_tree/Compatibility.cpp
index e0c34c8feb..38b8f92383 100644
--- a/plugins/Dbx_tree/Compatibility.cpp
+++ b/plugins/Dbx_tree/Compatibility.cpp
@@ -807,21 +807,8 @@ INT_PTR CompGetProfilePath(WPARAM cbBytes, LPARAM pszName)
return gDataBase->getProfilePath(cbBytes, reinterpret_cast<char*>(pszName));
}
-int OnPreShutdown(WPARAM, LPARAM)
-{
- DestroyHookableEvent(hEventDeletedEvent);
- DestroyHookableEvent(hEventAddedEvent);
- DestroyHookableEvent(hEventFilterAddedEvent);
- DestroyHookableEvent(hSettingChangeEvent);
- DestroyHookableEvent(hContactDeletedEvent);
- DestroyHookableEvent(hContactAddedEvent);
- return 0;
-}
-
bool CompatibilityRegister()
{
- HookEvent(ME_SYSTEM_PRESHUTDOWN, OnPreShutdown);
-
gCompServices[ 0] = CreateServiceFunction(MS_DB_CONTACT_GETCOUNT, CompGetContactCount);
gCompServices[ 1] = CreateServiceFunction(MS_DB_CONTACT_FINDFIRST, CompFindFirstContact);
gCompServices[ 2] = CreateServiceFunction(MS_DB_CONTACT_FINDNEXT, CompFindNextContact);
@@ -868,11 +855,12 @@ bool CompatibilityRegister()
hContactAddedEvent = CreateHookableEvent(ME_DB_CONTACT_ADDED);
return true;
}
-
bool CompatibilityUnRegister()
{
- for (int i = 0; i < SIZEOF(gCompServices); ++i)
+ int i;
+ for (i = 0; i < sizeof(gCompServices) / sizeof(gCompServices[0]); ++i)
+ {
DestroyServiceFunction(gCompServices[i]);
-
+ }
return true;
}