summaryrefslogtreecommitdiff
path: root/plugins/QuickContacts
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2013-03-30 17:32:39 +0000
committerGeorge Hazan <george.hazan@gmail.com>2013-03-30 17:32:39 +0000
commit109877a3c75cb290c55755dcfc88794d2453669d (patch)
tree3ede8b9170b2fc3f6f35dc2cea6742d44b19d631 /plugins/QuickContacts
parentfee8d991bdf4a59b563d1b92165ea0ed2f7bacb8 (diff)
MS_DB_EVENT_* services remained, but their calls removed
git-svn-id: http://svn.miranda-ng.org/main/trunk@4255 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/QuickContacts')
-rw-r--r--plugins/QuickContacts/src/quickcontacts.cpp17
1 files changed, 5 insertions, 12 deletions
diff --git a/plugins/QuickContacts/src/quickcontacts.cpp b/plugins/QuickContacts/src/quickcontacts.cpp
index 3bc7f4f355..2a653dbd21 100644
--- a/plugins/QuickContacts/src/quickcontacts.cpp
+++ b/plugins/QuickContacts/src/quickcontacts.cpp
@@ -217,18 +217,11 @@ int ModulesLoaded(WPARAM wParam, LPARAM lParam)
// handle of contact is set as window-userdata
int EventAdded(WPARAM wparam, LPARAM lparam)
{
- DBEVENTINFO dbei;
-
- ZeroMemory(&dbei,sizeof(dbei));
- dbei.cbSize=sizeof(dbei);
- dbei.cbBlob=0;
-
- CallService(MS_DB_EVENT_GET,lparam,(LPARAM)&dbei);
-
- if( !(dbei.flags & DBEF_SENT)
- || dbei.flags & DBEF_READ
- || !DBGetContactSettingByte(NULL, MODULE_NAME, "EnableLastSentTo", 0)
- || DBGetContactSettingWord(NULL, MODULE_NAME, "MsgTypeRec", TYPE_GLOBAL) != TYPE_GLOBAL)
+ DBEVENTINFO dbei = { sizeof(dbei) };
+ db_event_get((HANDLE)lparam, &dbei);
+ if ( !(dbei.flags & DBEF_SENT) || (dbei.flags & DBEF_READ)
+ || !DBGetContactSettingByte(NULL, MODULE_NAME, "EnableLastSentTo", 0)
+ || DBGetContactSettingWord(NULL, MODULE_NAME, "MsgTypeRec", TYPE_GLOBAL) != TYPE_GLOBAL)
return 0;
DBWriteContactSettingDword(NULL, MODULE_NAME, "LastSentTo", (DWORD)(HANDLE)wparam);