summaryrefslogtreecommitdiff
path: root/protocols/VKontakte/src/vk_thread.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2013-10-06 13:17:00 +0000
committerGeorge Hazan <george.hazan@gmail.com>2013-10-06 13:17:00 +0000
commit74bbe14fb8a018a65f89d28386eb3e88edfd0516 (patch)
tree8309b29c8d288e472955aa07defab7e5e3f1726b /protocols/VKontakte/src/vk_thread.cpp
parent91003eb7373b4cb9e340be5ecdbbb7884a5e973f (diff)
VK: async http requests
git-svn-id: http://svn.miranda-ng.org/main/trunk@6373 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/VKontakte/src/vk_thread.cpp')
-rw-r--r--protocols/VKontakte/src/vk_thread.cpp16
1 files changed, 12 insertions, 4 deletions
diff --git a/protocols/VKontakte/src/vk_thread.cpp b/protocols/VKontakte/src/vk_thread.cpp
index dea822ec83..71ee02c2a3 100644
--- a/protocols/VKontakte/src/vk_thread.cpp
+++ b/protocols/VKontakte/src/vk_thread.cpp
@@ -19,19 +19,27 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
void CVkProto::ShutdownSession()
{
+ if (m_hWorkerThread) {
+ m_bTerminated = true;
+ SetEvent(m_evRequestsQueue);
+ }
+
OnLoggedOut();
}
void CVkProto::OnLoggedOut()
{
+ m_hWorkerThread = 0;
+
ProtoBroadcastAck(NULL, ACKTYPE_STATUS, ACKRESULT_SUCCESS, (HANDLE)m_iStatus, ID_STATUS_OFFLINE);
m_iStatus = m_iDesiredStatus = ID_STATUS_OFFLINE;
}
-void CVkProto::WorkerThread(void*)
+void CVkProto::OnOAuthAuthorize(NETLIBHTTPREQUEST *reply)
{
- m_hWorkerThread = GetCurrentThreadId();
+}
- OnLoggedOut();
- m_hWorkerThread = 0;
+void CVkProto::RequestMyInfo()
+{
}
+