diff options
author | Alexander Lantsev <aunsane@gmail.com> | 2012-10-06 09:54:57 +0000 |
---|---|---|
committer | Alexander Lantsev <aunsane@gmail.com> | 2012-10-06 09:54:57 +0000 |
commit | 15dafd06973f1a3a49faeeb7b781bd11f9e011a5 (patch) | |
tree | 751ec084f31c5198fa2453bcad9bce2499ff6b55 /protocols/Skype/src/skype_utils.cpp | |
parent | e8fa894df94628c991f19a7c1642bac68fa069b1 (diff) |
- added part of contact info loading
git-svn-id: http://svn.miranda-ng.org/main/trunk@1790 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/Skype/src/skype_utils.cpp')
-rw-r--r-- | protocols/Skype/src/skype_utils.cpp | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/protocols/Skype/src/skype_utils.cpp b/protocols/Skype/src/skype_utils.cpp index f2a9d28461..f64c1973d2 100644 --- a/protocols/Skype/src/skype_utils.cpp +++ b/protocols/Skype/src/skype_utils.cpp @@ -1,5 +1,25 @@ #include "skype_proto.h" +int CSkypeProto::countriesCount;
+CountryListEntry* CSkypeProto::countryList; + +int CSkypeProto::GetCountryIdByName(const char* countryName) +{ + for (int i = 0; i < CSkypeProto::countriesCount; i++) + { + const char* country = CSkypeProto::countryList[i].szName; + if (strcmp(CSkypeProto::countryList[i].szName, countryName) == 0) + return CSkypeProto::countryList[i].id; + } + + return 0; +} + +char* CSkypeProto::GetCountryNameById(int countryId) +{ + return (char*)::CallService(MS_UTILS_GETCOUNTRYBYNUMBER, (WPARAM)countryId, NULL); +} + int CSkypeProto::CompareProtos(const CSkypeProto *p1, const CSkypeProto *p2)
{
return wcscmp(p1->m_tszUserName, p2->m_tszUserName);
|