diff options
author | MikalaiR <nikolay.romanovich@narod.ru> | 2015-04-18 14:31:06 +0000 |
---|---|---|
committer | MikalaiR <nikolay.romanovich@narod.ru> | 2015-04-18 14:31:06 +0000 |
commit | 0d9ca51da67752273947ae853b1cfc923e407627 (patch) | |
tree | 437ec80361a3682c5f54b4465d865b2300164f46 /protocols/SkypeWeb/src/skype_login.cpp | |
parent | 54f4449e9183407bd8cd09fdcb81f4e3d55ac3e5 (diff) |
SkypeWeb: Chats history loading fix.
git-svn-id: http://svn.miranda-ng.org/main/trunk@12912 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/SkypeWeb/src/skype_login.cpp')
-rw-r--r-- | protocols/SkypeWeb/src/skype_login.cpp | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/protocols/SkypeWeb/src/skype_login.cpp b/protocols/SkypeWeb/src/skype_login.cpp index e7df084f9c..dbd2108aff 100644 --- a/protocols/SkypeWeb/src/skype_login.cpp +++ b/protocols/SkypeWeb/src/skype_login.cpp @@ -108,6 +108,7 @@ void CSkypeProto::OnLoginSecond(const NETLIBHTTPREQUEST *response) void CSkypeProto::OnLoginSuccess()
{
TokenSecret = getStringA("TokenSecret");
+ Server = getStringA("registrationToken");
SendRequest(new CreateEndpointRequest(TokenSecret), &CSkypeProto::OnEndpointCreated);
PushRequest(new GetProfileRequest(TokenSecret), &CSkypeProto::LoadProfile);
PushRequest(new GetAvatarRequest(TokenSecret), &CSkypeProto::OnReceiveAvatar, NULL);
@@ -162,7 +163,7 @@ void CSkypeProto::OnEndpointCreated(const NETLIBHTTPREQUEST *response) if (response->resultCode != 201)
{
- PushRequest(new CreateEndpointRequest(TokenSecret, Server), &CSkypeProto::OnEndpointCreated);
+ SendRequest(new CreateEndpointRequest(TokenSecret, Server), &CSkypeProto::OnEndpointCreated);
return;
}
@@ -184,13 +185,16 @@ void CSkypeProto::OnSubscriptionsCreated(const NETLIBHTTPREQUEST *response) }
ptrA skypename(getStringA(SKYPE_SETTINGS_ID));
- PushRequest(new SendCapabilitiesRequest(RegToken, EndpointId, Server));
+ SendRequest(new SendCapabilitiesRequest(RegToken, EndpointId, Server));
SendRequest(new SetStatusRequest(RegToken, MirandaToSkypeStatus(m_iDesiredStatus), Server), &CSkypeProto::OnStatusChanged);
LIST<char> skypenames(1);
for (MCONTACT hContact = db_find_first(m_szModuleName); hContact; hContact = db_find_next(hContact, m_szModuleName))
- skypenames.insert(getStringA(hContact, SKYPE_SETTINGS_ID));
- PushRequest(new CreateContactsRequest(RegToken, skypenames, Server));
+ {
+ if (db_get_b(hContact, m_szModuleName, "ChatRoom", 0) == 0)
+ skypenames.insert(getStringA(hContact, SKYPE_SETTINGS_ID));
+ }
+ SendRequest(new CreateContactsRequest(RegToken, skypenames, Server));
for (int i = 0; i < skypenames.getCount(); i++)
mir_free(skypenames[i]);
skypenames.destroy();
|