diff options
author | George Hazan <george.hazan@gmail.com> | 2013-03-30 17:32:39 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2013-03-30 17:32:39 +0000 |
commit | 109877a3c75cb290c55755dcfc88794d2453669d (patch) | |
tree | 3ede8b9170b2fc3f6f35dc2cea6742d44b19d631 /plugins/Variables/src/parse_miranda.cpp | |
parent | fee8d991bdf4a59b563d1b92165ea0ed2f7bacb8 (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/Variables/src/parse_miranda.cpp')
-rw-r--r-- | plugins/Variables/src/parse_miranda.cpp | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/plugins/Variables/src/parse_miranda.cpp b/plugins/Variables/src/parse_miranda.cpp index 7216811be9..3a28fcde05 100644 --- a/plugins/Variables/src/parse_miranda.cpp +++ b/plugins/Variables/src/parse_miranda.cpp @@ -532,18 +532,18 @@ static HANDLE findDbEvent(HANDLE hContact, HANDLE hDbEvent, int flags) dbe.pBlob = NULL;
if (hContact != NULL) {
if ((flags & DBE_FIRST) && (flags & DBE_UNREAD)) {
- hDbEvent = (HANDLE)CallService(MS_DB_EVENT_FINDFIRSTUNREAD, (WPARAM)hContact, 0);
+ hDbEvent = db_event_firstUnread(hContact);
if (hDbEvent == NULL && (flags & DBE_READ))
- hDbEvent = (HANDLE)CallService(MS_DB_EVENT_FINDFIRST, (WPARAM)hContact, 0);
+ hDbEvent = db_event_first(hContact);
}
else if (flags & DBE_FIRST)
- hDbEvent = (HANDLE)CallService(MS_DB_EVENT_FINDFIRST, (WPARAM)hContact, 0);
+ hDbEvent = db_event_first(hContact);
else if (flags & DBE_LAST)
- hDbEvent = (HANDLE)CallService(MS_DB_EVENT_FINDLAST, (WPARAM)hContact, 0);
+ hDbEvent = db_event_last(hContact);
else if (flags & DBE_NEXT)
- hDbEvent = (HANDLE)CallService(MS_DB_EVENT_FINDNEXT, (WPARAM)hDbEvent, 0);
+ hDbEvent = db_event_next(hDbEvent);
else if (flags & DBE_PREV)
- hDbEvent = (HANDLE)CallService(MS_DB_EVENT_FINDPREV, (WPARAM)hDbEvent, 0);
+ hDbEvent = db_event_prev(hDbEvent);
}
else {
HANDLE hMatchEvent, hSearchEvent, hSearchContact;
@@ -556,7 +556,7 @@ static HANDLE findDbEvent(HANDLE hContact, HANDLE hDbEvent, int flags) do {
hSearchEvent = findDbEvent(hSearchContact, NULL, flags);
dbe.cbBlob = 0;
- if (!CallService(MS_DB_EVENT_GET, (WPARAM)hSearchEvent, (LPARAM)&dbe)) {
+ if (!db_event_get(hSearchEvent, &dbe)) {
if ((dbe.timestamp < matchTimestamp) || (matchTimestamp == 0)) {
hMatchEvent = hSearchEvent;
matchTimestamp = dbe.timestamp;
@@ -571,7 +571,7 @@ static HANDLE findDbEvent(HANDLE hContact, HANDLE hDbEvent, int flags) do {
hSearchEvent = findDbEvent(hSearchContact, NULL, flags);
dbe.cbBlob = 0;
- if (!CallService(MS_DB_EVENT_GET, (WPARAM)hSearchEvent, (LPARAM)&dbe)) {
+ if (!db_event_get(hSearchEvent, &dbe)) {
if ((dbe.timestamp > matchTimestamp) || (matchTimestamp == 0)) {
hMatchEvent = hSearchEvent;
matchTimestamp = dbe.timestamp;
@@ -583,13 +583,13 @@ static HANDLE findDbEvent(HANDLE hContact, HANDLE hDbEvent, int flags) }
else if (flags&DBE_NEXT) {
dbe.cbBlob = 0;
- if (!CallService(MS_DB_EVENT_GET, (WPARAM)hDbEvent, (LPARAM)&dbe)) {
+ if (!db_event_get(hDbEvent, &dbe)) {
priorTimestamp = dbe.timestamp;
hSearchContact = db_find_first();
do {
hSearchEvent = findDbEvent(hSearchContact, hDbEvent, flags);
dbe.cbBlob = 0;
- if (!CallService(MS_DB_EVENT_GET, (WPARAM)hSearchEvent, (LPARAM)&dbe)) {
+ if (!db_event_get(hSearchEvent, &dbe)) {
if (((dbe.timestamp < matchTimestamp) || (matchTimestamp == 0)) && (dbe.timestamp > priorTimestamp)) {
hMatchEvent = hSearchEvent;
matchTimestamp = dbe.timestamp;
@@ -601,13 +601,13 @@ static HANDLE findDbEvent(HANDLE hContact, HANDLE hDbEvent, int flags) }
}
else if (flags&DBE_PREV) {
- if (!CallService(MS_DB_EVENT_GET, (WPARAM)hDbEvent, (LPARAM)&dbe)) {
+ if (!db_event_get(hDbEvent, &dbe)) {
priorTimestamp = dbe.timestamp;
hSearchContact = db_find_first();
do {
hSearchEvent = findDbEvent(hSearchContact, hDbEvent, flags);
dbe.cbBlob = 0;
- if (!CallService(MS_DB_EVENT_GET, (WPARAM)hSearchEvent, (LPARAM)&dbe)) {
+ if (!db_event_get(hSearchEvent, &dbe)) {
if (((dbe.timestamp > matchTimestamp) || (matchTimestamp == 0)) && (dbe.timestamp < priorTimestamp)) {
hMatchEvent = hSearchEvent;
matchTimestamp = dbe.timestamp;
@@ -620,7 +620,7 @@ static HANDLE findDbEvent(HANDLE hContact, HANDLE hDbEvent, int flags) }
}
dbe.cbBlob = 0;
- if (CallService(MS_DB_EVENT_GET, (WPARAM)hDbEvent, (LPARAM)&dbe))
+ if (db_event_get(hDbEvent, &dbe))
bEventOk = FALSE;
else
bEventOk = isValidDbEvent(&dbe, flags);
@@ -698,9 +698,9 @@ static TCHAR *parseDbEvent(ARGUMENTSINFO *ai) DBEVENTINFO dbe = { 0 };
dbe.cbSize = sizeof(DBEVENTINFO);
- dbe.cbBlob = CallService(MS_DB_EVENT_GETBLOBSIZE, (WPARAM)hDbEvent, 0);
+ dbe.cbBlob = db_event_getBlobSize(hDbEvent);
dbe.pBlob = (PBYTE)mir_calloc(dbe.cbBlob);
- if (CallService(MS_DB_EVENT_GET, (WPARAM)hDbEvent, (LPARAM)&dbe)) {
+ if (db_event_get(hDbEvent, &dbe)) {
mir_free(dbe.pBlob);
return NULL;
}
|