- Rename WIN_Handle16 to HWDN_16 and make it a macro.
- Prepare user.dll for the change of HWND to a void*.
diff --git a/controls/listbox.c b/controls/listbox.c
index 4379645..3606508 100644
--- a/controls/listbox.c
+++ b/controls/listbox.c
@@ -32,6 +32,7 @@
#include "user.h"
#include "controls.h"
#include "wine/debug.h"
+#include "win.h"
WINE_DEFAULT_DEBUG_CHANNEL(listbox);
WINE_DECLARE_DEBUG_CHANNEL(combo);
@@ -106,7 +107,7 @@
#define SEND_NOTIFICATION(hwnd,descr,code) \
(SendMessageW( (descr)->owner, WM_COMMAND, \
- MAKEWPARAM( GetWindowLongA((hwnd),GWL_ID), (code)), (hwnd) ))
+ MAKEWPARAM( GetWindowLongA((hwnd),GWL_ID), (code)), (LPARAM)(hwnd) ))
#define ISWIN31 (LOWORD(GetVersion()) == 0x0a03)
@@ -2351,7 +2352,7 @@
{
caret = SendMessageW( descr->owner, WM_CHARTOITEM,
MAKEWPARAM(charW, descr->focus_item),
- hwnd );
+ (LPARAM)hwnd );
if (caret == -2) return 0;
}
if (caret == -1)
@@ -3012,7 +3013,7 @@
LPDRAGINFO16 dragInfo = MapSL( lParam );
dragInfo->l = LISTBOX_GetItemFromPoint( descr, dragInfo->pt.x,
dragInfo->pt.y );
- return SendMessage16( descr->owner, msg, wParam, lParam );
+ return SendMessage16( HWND_16(descr->owner), msg, wParam, lParam );
}
break;
diff --git a/controls/static.c b/controls/static.c
index cce770c..52251f4 100644
--- a/controls/static.c
+++ b/controls/static.c
@@ -417,7 +417,7 @@
dis.itemData = 0;
GetClientRect( hwnd, &dis.rcItem );
- SendMessageW( GetParent(hwnd), WM_CTLCOLORSTATIC, hdc, hwnd );
+ SendMessageW( GetParent(hwnd), WM_CTLCOLORSTATIC, hdc, (LPARAM)hwnd );
SendMessageW( GetParent(hwnd), WM_DRAWITEM, id, (LPARAM)&dis );
}
@@ -465,9 +465,11 @@
if ((style & SS_NOPREFIX) || ((style & SS_TYPEMASK) != SS_SIMPLE))
{
- hBrush = SendMessageW( GetParent(hwnd), WM_CTLCOLORSTATIC, hdc, hwnd );
+ hBrush = SendMessageW( GetParent(hwnd), WM_CTLCOLORSTATIC, hdc,
+ (LPARAM)hwnd );
if (!hBrush) /* did the app forget to call defwindowproc ? */
- hBrush = DefWindowProcW(GetParent(hwnd), WM_CTLCOLORSTATIC, hdc, hwnd);
+ hBrush = DefWindowProcW(GetParent(hwnd), WM_CTLCOLORSTATIC, hdc,
+ (LPARAM)hwnd);
FillRect( hdc, &rc, hBrush );
}
if (!IsWindowEnabled(hwnd)) SetTextColor(hdc, GetSysColor(COLOR_GRAYTEXT));
@@ -526,7 +528,7 @@
HICON hIcon;
GetClientRect( hwnd, &rc );
- hbrush = SendMessageW( GetParent(hwnd), WM_CTLCOLORSTATIC, hdc, hwnd );
+ hbrush = SendMessageW( GetParent(hwnd), WM_CTLCOLORSTATIC, hdc, (LPARAM)hwnd );
FillRect( hdc, &rc, hbrush );
if ((hIcon = GetWindowLongA( hwnd, HICON_GWL_OFFSET )))
DrawIcon( hdc, rc.left, rc.top, hIcon );
@@ -541,7 +543,7 @@
HBITMAP oldbitmap;
GetClientRect( hwnd, &rc );
- hbrush = SendMessageW( GetParent(hwnd), WM_CTLCOLORSTATIC, hdc, hwnd );
+ hbrush = SendMessageW( GetParent(hwnd), WM_CTLCOLORSTATIC, hdc, (LPARAM)hwnd );
FillRect( hdc, &rc, hbrush );
if ((hIcon = GetWindowLongA( hwnd, HICON_GWL_OFFSET )))