summaryrefslogtreecommitdiff
path: root/plugins/SmileyAdd
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2012-10-07 12:50:40 +0000
committerGeorge Hazan <george.hazan@gmail.com>2012-10-07 12:50:40 +0000
commitc6fb861d7159279b6ee4a4dd678d4693ee56bac6 (patch)
treedf911e6eaf7bd944081aae96f5df9c2ef84c2476 /plugins/SmileyAdd
parent95da57c8e9cf894adf3afae124a29d292b085c5e (diff)
death of old nasty clutch with MS_PROTO_ENUMPROTOCOLS & PROTOACCOUNT::type
git-svn-id: http://svn.miranda-ng.org/main/trunk@1799 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/SmileyAdd')
-rw-r--r--plugins/SmileyAdd/src/smileys.cpp45
1 files changed, 3 insertions, 42 deletions
diff --git a/plugins/SmileyAdd/src/smileys.cpp b/plugins/SmileyAdd/src/smileys.cpp
index 2f16cee51e..2cc8039052 100644
--- a/plugins/SmileyAdd/src/smileys.cpp
+++ b/plugins/SmileyAdd/src/smileys.cpp
@@ -994,50 +994,11 @@ void SmileyCategoryListType::AddAllProtocolsAsCategory(void)
if (lpcp == CALLSERVICE_NOTFOUND) lpcp = CP_ACP;
- PROTOCOLDESCRIPTOR **protoList;
PROTOACCOUNT **accList;
int protoCount;
-
- if (ProtoEnumAccounts(&protoCount, &accList) == CALLSERVICE_NOTFOUND || (protoCount > 0 && accList[0]->cbSize == 0))
- {
- CallService(MS_PROTO_ENUMPROTOCOLS, (WPARAM)&protoCount, (LPARAM)&protoList);
- for (int i = 0; i < protoCount; i++)
- {
- if (protoList[i]->type != PROTOTYPE_PROTOCOL) continue;
-
- if (IsSmileyProto(protoList[i]->szName))
- {
- const char* packnam = protoList[i]->szName;
- if (strcmp(packnam, "JABBER") == 0)
- packnam = "JGMail";
- else if (strstr(packnam, "SIP") != NULL)
- packnam = "MSN";
-
- char path[MAX_PATH];
- mir_snprintf(path, sizeof(path), "Smileys\\nova\\%s.msl", packnam);
-
- bkstring paths = A2T_SM(path), patha;
- pathToAbsolute(paths, patha);
-
- if (_taccess(patha.c_str(), 0) != 0)
- paths = defaultFile;
-
- char protoName[128];
- CallProtoService(protoList[i]->szName, PS_GETNAME, sizeof(protoName), (LPARAM)protoName);
-
-
- displayName = A2W_SM(protoName, lpcp);
-
- tname = A2T_SM(protoList[i]->szName);
- AddCategory(tname, displayName, smcProto, paths);
- }
- }
- }
- else
- {
- for (int i = 0; i < protoCount; i++)
- AddAccountAsCategory(accList[i], defaultFile);
- }
+ ProtoEnumAccounts(&protoCount, &accList);
+ for (int i = 0; i < protoCount; i++)
+ AddAccountAsCategory(accList[i], defaultFile);
HANDLE hContact = (HANDLE)CallService( MS_DB_CONTACT_FINDFIRST, 0, 0);
while (hContact != NULL)