summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMikalaiR <nikolay.romanovich@narod.ru>2015-04-20 15:33:13 +0000
committerMikalaiR <nikolay.romanovich@narod.ru>2015-04-20 15:33:13 +0000
commit66a60a05bfcbefa4faa141caa895e7315e7ffa45 (patch)
treeb87625e1c53451d3a9e1b94f3219609e2ca30f0e
parente79b2d652e8a868b2605a24b1f3796b32e6ea0c9 (diff)
SkypeWeb: AssocMgr support part 2.
git-svn-id: http://svn.miranda-ng.org/main/trunk@12979 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
-rw-r--r--protocols/SkypeWeb/src/main.cpp2
-rw-r--r--protocols/SkypeWeb/src/skype_proto.h2
-rw-r--r--protocols/SkypeWeb/src/skype_utils.cpp5
3 files changed, 5 insertions, 4 deletions
diff --git a/protocols/SkypeWeb/src/main.cpp b/protocols/SkypeWeb/src/main.cpp
index 6aedb66382..80c8363e1a 100644
--- a/protocols/SkypeWeb/src/main.cpp
+++ b/protocols/SkypeWeb/src/main.cpp
@@ -89,7 +89,7 @@ int CSkypeProto::OnModulesLoaded(WPARAM, LPARAM)
{
if (ServiceExists(MS_ASSOCMGR_ADDNEWURLTYPE))
{
- CreateServiceFunction(SKYPE_PARSEURI, ParseSkypeURI);
+ CreateServiceFunction(SKYPE_PARSEURI, GlobalService<&CSkypeProto::ParseSkypeURIService>);
AssocMgr_AddNewUrlTypeT("skype:", TranslateT("Skype Link Protocol"), g_hInstance, IDI_SKYPE, SKYPE_PARSEURI, 0);
}
return 0;
diff --git a/protocols/SkypeWeb/src/skype_proto.h b/protocols/SkypeWeb/src/skype_proto.h
index 3e50d204a3..16aa9df60d 100644
--- a/protocols/SkypeWeb/src/skype_proto.h
+++ b/protocols/SkypeWeb/src/skype_proto.h
@@ -277,7 +277,7 @@ private:
char *SelfUrlToName(const char *url);
char *GetServerFromUrl(const char *url);
- static INT_PTR __cdecl CSkypeProto::ParseSkypeURI(WPARAM, LPARAM lParam);
+ INT_PTR __cdecl CSkypeProto::ParseSkypeURIService(WPARAM, LPARAM lParam);
template<INT_PTR(__cdecl CSkypeProto::*Service)(WPARAM, LPARAM)>
static INT_PTR __cdecl GlobalService(WPARAM wParam, LPARAM lParam)
diff --git a/protocols/SkypeWeb/src/skype_utils.cpp b/protocols/SkypeWeb/src/skype_utils.cpp
index 165a48cdf0..b1f929fad5 100644
--- a/protocols/SkypeWeb/src/skype_utils.cpp
+++ b/protocols/SkypeWeb/src/skype_utils.cpp
@@ -517,7 +517,7 @@ char *CSkypeProto::GetServerFromUrl(const char *url)
return ParseUrl(url, "://");
}
-INT_PTR __cdecl CSkypeProto::ParseSkypeURI(WPARAM w, LPARAM lParam)
+INT_PTR __cdecl CSkypeProto::ParseSkypeURIService(WPARAM, LPARAM lParam)
{
TCHAR *arg = (TCHAR *)lParam;
if (arg == NULL)
@@ -551,7 +551,8 @@ INT_PTR __cdecl CSkypeProto::ParseSkypeURI(WPARAM w, LPARAM lParam)
// no command or message command
if (!szCommand || (szCommand && !_tcsicmp(szCommand, _T("chat"))))
{
- //CallService(MS_MSG_SENDMESSAGE, (WPARAM)hContact, NULL);
+ MCONTACT hContact = AddContact(_T2A(szJid), true);
+ CallService(MS_MSG_SENDMESSAGE, (WPARAM)hContact, NULL);
return 0;
}