summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorKirill Volinsky <mataes2007@gmail.com>2015-05-11 14:23:10 +0000
committerKirill Volinsky <mataes2007@gmail.com>2015-05-11 14:23:10 +0000
commit7b2f41b2571dbc15abb77b5462b14473eabafcb2 (patch)
tree08808b8722793ae1c4aec86428b0bcc0595e218f /plugins
parent34906fa22948984c76b4c8a0eb0cdeae689266a8 (diff)
minus CreateThread
git-svn-id: http://svn.miranda-ng.org/main/trunk@13532 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins')
-rw-r--r--plugins/AvatarHistory/src/AvatarDlg.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/plugins/AvatarHistory/src/AvatarDlg.cpp b/plugins/AvatarHistory/src/AvatarDlg.cpp
index 2fc20eeaa1..1ddb14c113 100644
--- a/plugins/AvatarHistory/src/AvatarDlg.cpp
+++ b/plugins/AvatarHistory/src/AvatarDlg.cpp
@@ -21,7 +21,7 @@ Avatar History Plugin
#include "stdafx.h"
HGENMENU hMenu = NULL;
-DWORD WINAPI AvatarDialogThread(LPVOID param);
+void __cdecl AvatarDialogThread(void *param);
static INT_PTR CALLBACK AvatarDlgProc(HWND hwnd,UINT uMsg,WPARAM wParam,LPARAM lParam);
int ShowSaveDialog(HWND hwnd, TCHAR* fn,MCONTACT hContact = NULL);
@@ -75,7 +75,6 @@ int OpenAvatarDialog(MCONTACT hContact, char* fn)
return 0;
}
- DWORD dwId;
struct AvatarDialogData *avdlg = (struct AvatarDialogData*)malloc(sizeof(struct AvatarDialogData));
memset(avdlg, 0, sizeof(struct AvatarDialogData));
avdlg->hContact = hContact;
@@ -88,15 +87,14 @@ int OpenAvatarDialog(MCONTACT hContact, char* fn)
MultiByteToWideChar(CP_ACP, 0, fn, -1, avdlg->fn, SIZEOF(avdlg->fn));
}
- CloseHandle(CreateThread(NULL, 0, AvatarDialogThread, (LPVOID)avdlg, 0, &dwId));
+ CloseHandle(mir_forkthread(AvatarDialogThread, (void*)avdlg));
return 0;
}
-DWORD WINAPI AvatarDialogThread(LPVOID param)
+void __cdecl AvatarDialogThread(void *param)
{
struct AvatarDialogData* data = (struct AvatarDialogData*)param;
DialogBoxParam(hInst, MAKEINTRESOURCE(IDD_AVATARDLG), data->parent, AvatarDlgProc, (LPARAM)param);
- return 0;
}
void EnableDisableControls(HWND hwnd)