From 5aca7788f891521104f8bed712672af236465cc1 Mon Sep 17 00:00:00 2001 From: Rozhuk Ivan Date: Wed, 12 Mar 2014 12:17:43 +0000 Subject: SetWindowLongPtr() and GetWindowLongPtr() multiple fixes for x64 git-svn-id: http://svn.miranda-ng.org/main/trunk@8571 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/NewAwaySysMod/src/GroupCheckbox.cpp | 2 +- plugins/NewAwaySysMod/src/Notification.cpp | 2 +- plugins/NewAwaySysMod/src/Properties.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'plugins/NewAwaySysMod/src') diff --git a/plugins/NewAwaySysMod/src/GroupCheckbox.cpp b/plugins/NewAwaySysMod/src/GroupCheckbox.cpp index 9586122006..aca2c68830 100644 --- a/plugins/NewAwaySysMod/src/GroupCheckbox.cpp +++ b/plugins/NewAwaySysMod/src/GroupCheckbox.cpp @@ -318,7 +318,7 @@ static int CALLBACK CheckboxWndProc(HWND hWnd, UINT Msg, WPARAM wParam, LPARAM l if (dat->hFont) DeleteObject(dat->hFont); - SetWindowLongPtr(hWnd, GWLP_USERDATA, NULL); + SetWindowLongPtr(hWnd, GWLP_USERDATA, 0); CallWindowProc(dat->OldWndProc, hWnd, Msg, wParam, lParam); delete dat; return 0; diff --git a/plugins/NewAwaySysMod/src/Notification.cpp b/plugins/NewAwaySysMod/src/Notification.cpp index 6f04dc0267..5e7b12eedc 100644 --- a/plugins/NewAwaySysMod/src/Notification.cpp +++ b/plugins/NewAwaySysMod/src/Notification.cpp @@ -54,7 +54,7 @@ static VOID CALLBACK ShowContactMenu(MCONTACT hContact) { POINT pt; HWND hMenuWnd = CreateWindowEx(WS_EX_TOOLWINDOW, _T("static"), _T(MOD_NAME)_T("_MenuWindow"), 0, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, HWND_DESKTOP, NULL, g_hInstance, NULL); - SetWindowLongPtr(hMenuWnd, GWLP_WNDPROC, (LONG)(WNDPROC)MenuWndProc); + SetWindowLongPtr(hMenuWnd, GWLP_WNDPROC, (LONG_PTR)(WNDPROC)MenuWndProc); HMENU hMenu = (HMENU)CallService(MS_CLIST_MENUBUILDCONTACT, hContact, 0); GetCursorPos(&pt); SetForegroundWindow(hMenuWnd); diff --git a/plugins/NewAwaySysMod/src/Properties.h b/plugins/NewAwaySysMod/src/Properties.h index 6e839ddd52..8edc9e4c5b 100644 --- a/plugins/NewAwaySysMod/src/Properties.h +++ b/plugins/NewAwaySysMod/src/Properties.h @@ -56,7 +56,7 @@ public: { _ASSERT(dat == (_CWndUserData*)GetWindowLongPtr(hWnd, GWLP_USERDATA)); if (!dat->MsgTree && !dat->CList) { - SetWindowLongPtr(hWnd, GWLP_USERDATA, NULL); + SetWindowLongPtr(hWnd, GWLP_USERDATA, 0); delete dat; // TODO: memory leak - this is never executed - fix it } } -- cgit v1.2.3