summaryrefslogtreecommitdiff
path: root/protocols/JabberG/src/jabber_svc.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2016-09-13 17:11:58 +0000
committerGeorge Hazan <george.hazan@gmail.com>2016-09-13 17:11:58 +0000
commitf51995e13679a37851baef8e7f52f2d993cbc7c1 (patch)
tree25ccd03cf2dc4b897cc0dc6fcbe4cc78ddb122c7 /protocols/JabberG/src/jabber_svc.cpp
parentfe1e8456d2488095f409a4f2d38b7251abdedccf (diff)
mode old database junk to die
git-svn-id: http://svn.miranda-ng.org/main/trunk@17291 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/JabberG/src/jabber_svc.cpp')
-rw-r--r--protocols/JabberG/src/jabber_svc.cpp58
1 files changed, 23 insertions, 35 deletions
diff --git a/protocols/JabberG/src/jabber_svc.cpp b/protocols/JabberG/src/jabber_svc.cpp
index 29b2cef6b5..9b9e75ff57 100644
--- a/protocols/JabberG/src/jabber_svc.cpp
+++ b/protocols/JabberG/src/jabber_svc.cpp
@@ -175,15 +175,15 @@ INT_PTR __cdecl CJabberProto::JabberGetAvatarInfo(WPARAM wParam, LPARAM lParam)
////////////////////////////////////////////////////////////////////////////////////////
// JabberGetEventTextChatStates - retrieves a chat state description from an event
-INT_PTR __cdecl CJabberProto::OnGetEventTextChatStates(WPARAM, LPARAM lParam)
+INT_PTR __cdecl CJabberProto::OnGetEventTextChatStates(WPARAM pEvent, LPARAM datatype)
{
- DBEVENTGETTEXT *pdbEvent = (DBEVENTGETTEXT *)lParam;
- if (pdbEvent->dbei->cbBlob > 0) {
- if (pdbEvent->dbei->pBlob[0] == JABBER_DB_EVENT_CHATSTATES_GONE) {
- if (pdbEvent->datatype == DBVT_WCHAR)
+ DBEVENTINFO *dbei = (DBEVENTINFO *)pEvent;
+ if (dbei->cbBlob > 0) {
+ if (dbei->pBlob[0] == JABBER_DB_EVENT_CHATSTATES_GONE) {
+ if (datatype == DBVT_WCHAR)
return (INT_PTR)mir_wstrdup(TranslateT("closed chat session"));
- else if (pdbEvent->datatype == DBVT_ASCIIZ)
- return (INT_PTR)mir_strdup(Translate("closed chat session"));
+
+ return (INT_PTR)mir_strdup(Translate("closed chat session"));
}
}
@@ -193,52 +193,40 @@ INT_PTR __cdecl CJabberProto::OnGetEventTextChatStates(WPARAM, LPARAM lParam)
////////////////////////////////////////////////////////////////////////////////////////
// OnGetEventTextPresence - retrieves presence state description from an event
-INT_PTR __cdecl CJabberProto::OnGetEventTextPresence(WPARAM, LPARAM lParam)
+INT_PTR __cdecl CJabberProto::OnGetEventTextPresence(WPARAM pEvent, LPARAM datatype)
{
- DBEVENTGETTEXT *pdbEvent = (DBEVENTGETTEXT *)lParam;
- if (pdbEvent->dbei->cbBlob > 0) {
- switch (pdbEvent->dbei->pBlob[0]) {
+ DBEVENTINFO *dbei = (DBEVENTINFO *)pEvent;
+ if (dbei->cbBlob > 0) {
+ switch (dbei->pBlob[0]) {
case JABBER_DB_EVENT_PRESENCE_SUBSCRIBE:
- if (pdbEvent->datatype == DBVT_WCHAR)
+ if (datatype == DBVT_WCHAR)
return (INT_PTR)mir_wstrdup(TranslateT("sent subscription request"));
- else if (pdbEvent->datatype == DBVT_ASCIIZ)
- return (INT_PTR)mir_strdup(Translate("sent subscription request"));
- break;
+ return (INT_PTR)mir_strdup(Translate("sent subscription request"));
case JABBER_DB_EVENT_PRESENCE_SUBSCRIBED:
- if (pdbEvent->datatype == DBVT_WCHAR)
+ if (datatype == DBVT_WCHAR)
return (INT_PTR)mir_wstrdup(TranslateT("approved subscription request"));
- else if (pdbEvent->datatype == DBVT_ASCIIZ)
- return (INT_PTR)mir_strdup(Translate("approved subscription request"));
- break;
+ return (INT_PTR)mir_strdup(Translate("approved subscription request"));
case JABBER_DB_EVENT_PRESENCE_UNSUBSCRIBE:
- if (pdbEvent->datatype == DBVT_WCHAR)
+ if (datatype == DBVT_WCHAR)
return (INT_PTR)mir_wstrdup(TranslateT("declined subscription"));
- else if (pdbEvent->datatype == DBVT_ASCIIZ)
- return (INT_PTR)mir_strdup(Translate("declined subscription"));
- break;
+ return (INT_PTR)mir_strdup(Translate("declined subscription"));
case JABBER_DB_EVENT_PRESENCE_UNSUBSCRIBED:
- if (pdbEvent->datatype == DBVT_WCHAR)
+ if (datatype == DBVT_WCHAR)
return (INT_PTR)mir_wstrdup(TranslateT("declined subscription"));
- else if (pdbEvent->datatype == DBVT_ASCIIZ)
- return (INT_PTR)mir_strdup(Translate("declined subscription"));
- break;
+ return (INT_PTR)mir_strdup(Translate("declined subscription"));
case JABBER_DB_EVENT_PRESENCE_ERROR:
- if (pdbEvent->datatype == DBVT_WCHAR)
+ if (datatype == DBVT_WCHAR)
return (INT_PTR)mir_wstrdup(TranslateT("sent error presence"));
- else if (pdbEvent->datatype == DBVT_ASCIIZ)
- return (INT_PTR)mir_strdup(Translate("sent error presence"));
- break;
+ return (INT_PTR)mir_strdup(Translate("sent error presence"));
default:
- if (pdbEvent->datatype == DBVT_WCHAR)
+ if (datatype == DBVT_WCHAR)
return (INT_PTR)mir_wstrdup(TranslateT("sent unknown presence type"));
- else if (pdbEvent->datatype == DBVT_ASCIIZ)
- return (INT_PTR)mir_strdup(Translate("sent unknown presence type"));
- break;
+ return (INT_PTR)mir_strdup(Translate("sent unknown presence type"));
}
}