summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2014-02-02 20:26:12 +0000
committerGeorge Hazan <george.hazan@gmail.com>2014-02-02 20:26:12 +0000
commit50b1df91f2a061776ec14528abcef27b4117604c (patch)
treec7c225947ad6f556fbe1ca4e163d5e67ae9d9410 /plugins
parent3b7ef5348b728cbc916f5caa24938ff0581625cc (diff)
switch to modern helpers
git-svn-id: http://svn.miranda-ng.org/main/trunk@8018 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins')
-rw-r--r--plugins/Clist_mw/src/clistsettings.cpp13
-rw-r--r--plugins/RemovePersonalSettings/src/rps.cpp16
2 files changed, 2 insertions, 27 deletions
diff --git a/plugins/Clist_mw/src/clistsettings.cpp b/plugins/Clist_mw/src/clistsettings.cpp
index 7e6b081d80..ed3573d6d7 100644
--- a/plugins/Clist_mw/src/clistsettings.cpp
+++ b/plugins/Clist_mw/src/clistsettings.cpp
@@ -203,18 +203,7 @@ char *GetContactCachedProtocol(HANDLE hContact)
char *GetProtoForContact(HANDLE hContact)
{
- DBVARIANT dbv;
- DBCONTACTGETSETTING dbcgs;
- char name[32];
-
- dbv.type = DBVT_ASCIIZ;
- dbv.pszVal = name;
- dbv.cchVal = SIZEOF(name);
- dbcgs.pValue = &dbv;
- dbcgs.szModule = "Protocol";
- dbcgs.szSetting = "p";
- if (CallService(MS_DB_CONTACT_GETSETTINGSTATIC,(WPARAM)hContact,(LPARAM)&dbcgs)) return NULL;
- return mir_strdup(dbcgs.pValue->pszVal);
+ return mir_strdup(GetContactProto(hContact));
}
int GetStatusForContact(HANDLE hContact,char *szProto)
diff --git a/plugins/RemovePersonalSettings/src/rps.cpp b/plugins/RemovePersonalSettings/src/rps.cpp
index 181248d616..d1e8a698ea 100644
--- a/plugins/RemovePersonalSettings/src/rps.cpp
+++ b/plugins/RemovePersonalSettings/src/rps.cpp
@@ -616,21 +616,7 @@ void DeleteFileOrFolder(const char *name)
BOOL isMetaContact(HANDLE hContact)
{
- DBVARIANT dbv;
- DBCONTACTGETSETTING dbcgs;
- char name[32];
-
- dbv.type=DBVT_ASCIIZ;
- dbv.pszVal=name;
- dbv.cchVal=sizeof(name);
- dbcgs.pValue=&dbv;
- dbcgs.szModule="Protocol";
- dbcgs.szSetting="p";
-
- if(CallService(MS_DB_CONTACT_GETSETTINGSTATIC,(WPARAM)hContact,(LPARAM)&dbcgs))
- return FALSE;
-
- return strcmp(dbcgs.pValue->pszVal, METACONTACTS_PROTOCOL_NAME) == 0;
+ return lstrcmpA(GetContactProto(hContact), METACONTACTS_PROTOCOL_NAME) == 0;
}