Commit cb25e250 authored by Alexandre Julliard's avatar Alexandre Julliard

Replace SendMessage16 by SendMessageW where possible.

parent e6533a6b
......@@ -12,13 +12,13 @@
struct tagWND;
extern LONG NC_HandleNCPaint( HWND hwnd , HRGN clip);
extern LONG NC_HandleNCActivate( struct tagWND *pwnd, WPARAM16 wParam );
extern LONG NC_HandleNCActivate( struct tagWND *pwnd, WPARAM wParam );
extern LONG NC_HandleNCCalcSize( struct tagWND *pWnd, RECT *winRect );
extern LONG NC_HandleNCHitTest( HWND hwnd, POINT pt );
extern LONG NC_HandleNCLButtonDown( struct tagWND* pWnd, WPARAM16 wParam, LPARAM lParam );
extern LONG NC_HandleNCLButtonDblClk( struct tagWND *pWnd, WPARAM16 wParam, LPARAM lParam);
extern LONG NC_HandleNCLButtonDown( struct tagWND* pWnd, WPARAM wParam, LPARAM lParam );
extern LONG NC_HandleNCLButtonDblClk( struct tagWND *pWnd, WPARAM wParam, LPARAM lParam);
extern LONG NC_HandleSysCommand( HWND hwnd, WPARAM wParam, POINT pt );
extern LONG NC_HandleSetCursor( HWND hwnd, WPARAM16 wParam, LPARAM lParam );
extern LONG NC_HandleSetCursor( HWND hwnd, WPARAM wParam, LPARAM lParam );
extern void NC_DrawSysButton( HWND hwnd, HDC hdc, BOOL down );
extern BOOL NC_DrawSysButton95( HWND hwnd, HDC hdc, BOOL down );
extern BOOL NC_GetSysPopupPos( struct tagWND* wndPtr, RECT* rect );
......
......@@ -30,7 +30,6 @@
#include "wine/winuser16.h"
#include "wine/winbase16.h"
#include "heap.h"
#include "message.h"
#include "user.h"
#include "clipboard.h"
#include "debugtools.h"
......@@ -411,8 +410,7 @@ static BOOL CLIPBOARD_RenderFormat(LPWINE_CLIPFORMAT lpFormat)
* data requested into the clipboard.
*/
TRACE("Sending WM_RENDERFORMAT message\n");
SendMessage16(hWndClipOwner,WM_RENDERFORMAT,
(WPARAM16)lpFormat->wFormatID,0L);
SendMessageW( hWndClipOwner, WM_RENDERFORMAT, (WPARAM)lpFormat->wFormatID, 0 );
}
else
{
......@@ -770,8 +768,7 @@ BOOL WINAPI CloseClipboard(void)
{
hWndClipWindow = 0;
if (bCBHasChanged && hWndViewer)
SendMessage16(hWndViewer, WM_DRAWCLIPBOARD, 0, 0L);
if (bCBHasChanged && hWndViewer) SendMessageW( hWndViewer, WM_DRAWCLIPBOARD, 0, 0 );
hClipLock = 0;
}
return TRUE;
......@@ -803,8 +800,7 @@ BOOL WINAPI EmptyClipboard(void)
/* destroy private objects */
if (hWndClipOwner)
SendMessage16(hWndClipOwner, WM_DESTROYCLIPBOARD, 0, 0L);
if (hWndClipOwner) SendMessageW( hWndClipOwner, WM_DESTROYCLIPBOARD, 0, 0 );
/* empty the cache */
CLIPBOARD_EmptyCache(TRUE);
......@@ -1368,8 +1364,7 @@ BOOL WINAPI ChangeClipboardChain(HWND hWnd, HWND hWndNext)
FIXME("(0x%04x, 0x%04x): stub?\n", hWnd, hWndNext);
if( hWndViewer )
bRet = !SendMessage16( hWndViewer, WM_CHANGECBCHAIN,
(WPARAM16)hWnd, (LPARAM)hWndNext);
bRet = !SendMessageW( hWndViewer, WM_CHANGECBCHAIN, (WPARAM)hWnd, (LPARAM)hWndNext );
else
WARN("hWndViewer is lost\n");
......
......@@ -26,11 +26,11 @@ static void DEFDLG_SetFocus( HWND hwndDlg, HWND hwndCtrl )
if (IsChild( hwndDlg, hwndPrev ))
{
if (SendMessage16( hwndPrev, WM_GETDLGCODE, 0, 0 ) & DLGC_HASSETSEL)
SendMessage16( hwndPrev, EM_SETSEL16, TRUE, MAKELONG( -1, 0 ) );
if (SendMessageW( hwndPrev, WM_GETDLGCODE, 0, 0 ) & DLGC_HASSETSEL)
SendMessageW( hwndPrev, EM_SETSEL, -1, 0 );
}
if (SendMessage16( hwndCtrl, WM_GETDLGCODE, 0, 0 ) & DLGC_HASSETSEL)
SendMessage16( hwndCtrl, EM_SETSEL16, FALSE, MAKELONG( 0, -1 ) );
if (SendMessageW( hwndCtrl, WM_GETDLGCODE, 0, 0 ) & DLGC_HASSETSEL)
SendMessageW( hwndCtrl, EM_SETSEL, 0, -1 );
SetFocus( hwndCtrl );
}
......@@ -77,7 +77,7 @@ static HWND DEFDLG_FindDefButton( HWND hwndDlg )
HWND hwndChild = GetWindow( hwndDlg, GW_CHILD );
while (hwndChild)
{
if (SendMessage16( hwndChild, WM_GETDLGCODE, 0, 0 ) & DLGC_DEFPUSHBUTTON)
if (SendMessageW( hwndChild, WM_GETDLGCODE, 0, 0 ) & DLGC_DEFPUSHBUTTON)
break;
hwndChild = GetWindow( hwndChild, GW_HWNDNEXT );
}
......@@ -94,7 +94,7 @@ static BOOL DEFDLG_SetDefButton( HWND hwndDlg, DIALOGINFO *dlgInfo,
HWND hwndNew )
{
if (hwndNew &&
!(SendMessage16(hwndNew, WM_GETDLGCODE, 0, 0 ) & DLGC_UNDEFPUSHBUTTON))
!(SendMessageW(hwndNew, WM_GETDLGCODE, 0, 0 ) & DLGC_UNDEFPUSHBUTTON))
return FALSE; /* Destination is not a push button */
if (dlgInfo->idResult) /* There's already a default pushbutton */
......
......@@ -2186,8 +2186,7 @@ HWND WINAPI GetNextDlgTabItem( HWND hwndDlg, HWND hwndCtrl,
* Helper function for DlgDirSelect*
*/
static BOOL DIALOG_DlgDirSelect( HWND hwnd, LPSTR str, INT len,
INT id, BOOL win32, BOOL unicode,
BOOL combo )
INT id, BOOL unicode, BOOL combo )
{
char *buffer, *ptr;
INT item, size;
......@@ -2196,33 +2195,15 @@ static BOOL DIALOG_DlgDirSelect( HWND hwnd, LPSTR str, INT len,
TRACE("%04x '%s' %d\n", hwnd, str, id );
if (!listbox) return FALSE;
if (win32)
{
item = SendMessageA(listbox, combo ? CB_GETCURSEL
: LB_GETCURSEL, 0, 0 );
if (item == LB_ERR) return FALSE;
size = SendMessageA(listbox, combo ? CB_GETLBTEXTLEN
: LB_GETTEXTLEN, 0, 0 );
if (size == LB_ERR) return FALSE;
}
else
{
item = SendMessageA(listbox, combo ? CB_GETCURSEL16
: LB_GETCURSEL16, 0, 0 );
if (item == LB_ERR) return FALSE;
size = SendMessageA(listbox, combo ? CB_GETLBTEXTLEN16
: LB_GETTEXTLEN16, 0, 0 );
if (size == LB_ERR) return FALSE;
}
if (!(buffer = SEGPTR_ALLOC( size+1 ))) return FALSE;
item = SendMessageA(listbox, combo ? CB_GETCURSEL : LB_GETCURSEL, 0, 0 );
if (item == LB_ERR) return FALSE;
size = SendMessageA(listbox, combo ? CB_GETLBTEXTLEN : LB_GETTEXTLEN, 0, 0 );
if (size == LB_ERR) return FALSE;
if (win32)
SendMessageA( listbox, combo ? CB_GETLBTEXT : LB_GETTEXT,
item, (LPARAM)buffer );
else
SendMessage16( listbox, combo ? CB_GETLBTEXT16 : LB_GETTEXT16,
item, (LPARAM)SEGPTR_GET(buffer) );
if (!(buffer = HeapAlloc( GetProcessHeap(), 0, size+1 ))) return FALSE;
SendMessageA( listbox, combo ? CB_GETLBTEXT : LB_GETTEXT, item, (LPARAM)buffer );
if ((ret = (buffer[0] == '['))) /* drive or directory */
{
......@@ -2246,7 +2227,7 @@ static BOOL DIALOG_DlgDirSelect( HWND hwnd, LPSTR str, INT len,
((LPWSTR)str)[len-1] = 0;
}
else lstrcpynA( str, ptr, len );
SEGPTR_FREE( buffer );
HeapFree( GetProcessHeap(), 0, buffer );
TRACE("Returning %d '%s'\n", ret, str );
return ret;
}
......@@ -2383,7 +2364,7 @@ BOOL16 WINAPI DlgDirSelectComboBox16( HWND16 hwnd, LPSTR str, INT16 id )
*/
BOOL16 WINAPI DlgDirSelectEx16( HWND16 hwnd, LPSTR str, INT16 len, INT16 id )
{
return DIALOG_DlgDirSelect( hwnd, str, len, id, FALSE, FALSE, FALSE );
return DlgDirSelectExA( hwnd, str, len, id );
}
......@@ -2392,7 +2373,7 @@ BOOL16 WINAPI DlgDirSelectEx16( HWND16 hwnd, LPSTR str, INT16 len, INT16 id )
*/
BOOL WINAPI DlgDirSelectExA( HWND hwnd, LPSTR str, INT len, INT id )
{
return DIALOG_DlgDirSelect( hwnd, str, len, id, TRUE, FALSE, FALSE );
return DIALOG_DlgDirSelect( hwnd, str, len, id, FALSE, FALSE );
}
......@@ -2401,7 +2382,7 @@ BOOL WINAPI DlgDirSelectExA( HWND hwnd, LPSTR str, INT len, INT id )
*/
BOOL WINAPI DlgDirSelectExW( HWND hwnd, LPWSTR str, INT len, INT id )
{
return DIALOG_DlgDirSelect( hwnd, (LPSTR)str, len, id, TRUE, TRUE, FALSE );
return DIALOG_DlgDirSelect( hwnd, (LPSTR)str, len, id, TRUE, FALSE );
}
......@@ -2411,7 +2392,7 @@ BOOL WINAPI DlgDirSelectExW( HWND hwnd, LPWSTR str, INT len, INT id )
BOOL16 WINAPI DlgDirSelectComboBoxEx16( HWND16 hwnd, LPSTR str, INT16 len,
INT16 id )
{
return DIALOG_DlgDirSelect( hwnd, str, len, id, FALSE, FALSE, TRUE );
return DlgDirSelectComboBoxExA( hwnd, str, len, id );
}
......@@ -2421,7 +2402,7 @@ BOOL16 WINAPI DlgDirSelectComboBoxEx16( HWND16 hwnd, LPSTR str, INT16 len,
BOOL WINAPI DlgDirSelectComboBoxExA( HWND hwnd, LPSTR str, INT len,
INT id )
{
return DIALOG_DlgDirSelect( hwnd, str, len, id, TRUE, FALSE, TRUE );
return DIALOG_DlgDirSelect( hwnd, str, len, id, FALSE, TRUE );
}
......@@ -2431,7 +2412,7 @@ BOOL WINAPI DlgDirSelectComboBoxExA( HWND hwnd, LPSTR str, INT len,
BOOL WINAPI DlgDirSelectComboBoxExW( HWND hwnd, LPWSTR str, INT len,
INT id)
{
return DIALOG_DlgDirSelect( hwnd, (LPSTR)str, len, id, TRUE, TRUE, TRUE );
return DIALOG_DlgDirSelect( hwnd, (LPSTR)str, len, id, TRUE, TRUE );
}
......
......@@ -1547,8 +1547,8 @@ LRESULT WINAPI DefFrameProc16( HWND16 hwnd, HWND16 hwndMDIClient,
case SC_CLOSE:
case SC_RESTORE:
if( ci->hwndChildMaximized )
return SendMessage16( ci->hwndChildMaximized, WM_SYSCOMMAND,
wParam, lParam);
return SendMessageW( ci->hwndChildMaximized, WM_SYSCOMMAND,
wParam, lParam);
}
}
else
......@@ -1565,13 +1565,12 @@ LRESULT WINAPI DefFrameProc16( HWND16 hwnd, HWND16 hwndMDIClient,
WIN_ReleaseWndPtr(wndPtr);
if( childHwnd )
SendMessage16(hwndMDIClient, WM_MDIACTIVATE,
(WPARAM16)childHwnd , 0L);
SendMessageW( hwndMDIClient, WM_MDIACTIVATE, (WPARAM)childHwnd, 0 );
}
break;
case WM_NCACTIVATE:
SendMessage16(hwndMDIClient, message, wParam, lParam);
SendMessageW(hwndMDIClient, message, wParam, lParam);
break;
case WM_SETTEXT:
......@@ -1744,7 +1743,7 @@ LRESULT WINAPI DefMDIChildProc16( HWND16 hwnd, UINT16 message,
goto END;
case WM_CLOSE:
SendMessage16(ci->self,WM_MDIDESTROY,(WPARAM16)hwnd,0L);
SendMessageW( ci->self, WM_MDIDESTROY, (WPARAM)hwnd, 0 );
retvalue = 0;
goto END;
......@@ -1782,8 +1781,8 @@ LRESULT WINAPI DefMDIChildProc16( HWND16 hwnd, UINT16 message,
case SC_MAXIMIZE:
if( ci->hwndChildMaximized == hwnd)
{
retvalue = SendMessage16( clientWnd->parent->hwndSelf,
message, wParam, lParam);
retvalue = SendMessageW( clientWnd->parent->hwndSelf,
message, wParam, lParam);
goto END;
}
tmpWnd = WIN_FindWndPtr(hwnd);
......@@ -1791,11 +1790,11 @@ LRESULT WINAPI DefMDIChildProc16( HWND16 hwnd, UINT16 message,
WIN_ReleaseWndPtr(tmpWnd);
break;
case SC_NEXTWINDOW:
SendMessage16( ci->self, WM_MDINEXT, 0, 0);
SendMessageW( ci->self, WM_MDINEXT, 0, 0);
retvalue = 0;
goto END;
case SC_PREVWINDOW:
SendMessage16( ci->self, WM_MDINEXT, 0, 1);
SendMessageW( ci->self, WM_MDINEXT, 0, 1);
retvalue = 0;
goto END;
}
......@@ -1838,12 +1837,12 @@ LRESULT WINAPI DefMDIChildProc16( HWND16 hwnd, UINT16 message,
if( hMaxChild)
{
SendMessage16( hMaxChild, WM_SETREDRAW, FALSE, 0L );
SendMessageW( hMaxChild, WM_SETREDRAW, FALSE, 0 );
MDI_RestoreFrameMenu( clientWnd->parent, hMaxChild);
ShowWindow16( hMaxChild, SW_SHOWNOACTIVATE);
SendMessage16( hMaxChild, WM_SETREDRAW, TRUE, 0L );
SendMessageW( hMaxChild, WM_SETREDRAW, TRUE, 0 );
}
TRACE("maximizing child %04x\n", hwnd );
......@@ -1868,7 +1867,7 @@ LRESULT WINAPI DefMDIChildProc16( HWND16 hwnd, UINT16 message,
HWND16 switchTo = MDI_GetWindow(clientWnd, hwnd, TRUE, WS_MINIMIZE);
if( switchTo )
SendMessage16( switchTo, WM_CHILDACTIVATE, 0, 0L);
SendMessageW( switchTo, WM_CHILDACTIVATE, 0, 0);
}
MDI_PostUpdate(clientWnd->hwndSelf, ci, SB_BOTH+1);
......@@ -1900,8 +1899,7 @@ LRESULT WINAPI DefMDIChildProc16( HWND16 hwnd, UINT16 message,
case WM_SYSCHAR:
if (wParam == '-')
{
SendMessage16(hwnd,WM_SYSCOMMAND,
(WPARAM16)SC_KEYMENU, (LPARAM)(DWORD)VK_SPACE);
SendMessageW(hwnd,WM_SYSCOMMAND, SC_KEYMENU, (LPARAM)(DWORD)VK_SPACE);
retvalue = 0;
goto END;
}
......@@ -2156,11 +2154,17 @@ HWND WINAPI CreateMDIWindowW(
*/
BOOL16 WINAPI TranslateMDISysAccel16( HWND16 hwndClient, LPMSG16 msg )
{
MSG msg32;
STRUCT32_MSG16to32(msg, &msg32);
/* MDICLIENTINFO is still the same for win32 and win16 ... */
return TranslateMDISysAccel(hwndClient, &msg32);
if (msg->message == WM_KEYDOWN || msg->message == WM_SYSKEYDOWN)
{
MSG msg32;
msg32.hwnd = msg->hwnd;
msg32.message = msg->message;
msg32.wParam = msg->wParam;
msg32.lParam = msg->lParam;
/* MDICLIENTINFO is still the same for win32 and win16 ... */
return TranslateMDISysAccel(hwndClient, &msg32);
}
return 0;
}
/**********************************************************************
......
......@@ -1693,7 +1693,7 @@ LONG NC_HandleNCPaint( HWND hwnd , HRGN clip)
*
* Handle a WM_NCACTIVATE message. Called from DefWindowProc().
*/
LONG NC_HandleNCActivate( WND *wndPtr, WPARAM16 wParam )
LONG NC_HandleNCActivate( WND *wndPtr, WPARAM wParam )
{
/* Lotus Notes draws menu descriptions in the caption of its main
* window. When it wants to restore original "system" view, it just
......@@ -1720,7 +1720,7 @@ LONG NC_HandleNCActivate( WND *wndPtr, WPARAM16 wParam )
*
* Handle a WM_SETCURSOR message. Called from DefWindowProc().
*/
LONG NC_HandleSetCursor( HWND hwnd, WPARAM16 wParam, LPARAM lParam )
LONG NC_HandleSetCursor( HWND hwnd, WPARAM wParam, LPARAM lParam )
{
if (hwnd != (HWND)wParam) return 0; /* Don't set the cursor for child windows */
......@@ -2052,7 +2052,7 @@ END:
*
* Handle a WM_NCLBUTTONDOWN message. Called from DefWindowProc().
*/
LONG NC_HandleNCLButtonDown( WND* pWnd, WPARAM16 wParam, LPARAM lParam )
LONG NC_HandleNCLButtonDown( WND* pWnd, WPARAM wParam, LPARAM lParam )
{
HWND hwnd = pWnd->hwndSelf;
......@@ -2062,7 +2062,7 @@ LONG NC_HandleNCLButtonDown( WND* pWnd, WPARAM16 wParam, LPARAM lParam )
hwnd = WIN_GetTopParent(hwnd);
if( WINPOS_SetActiveWindow(hwnd, TRUE, TRUE) || (GetActiveWindow() == hwnd) )
SendMessage16( pWnd->hwndSelf, WM_SYSCOMMAND, SC_MOVE + HTCAPTION, lParam );
SendMessageW( pWnd->hwndSelf, WM_SYSCOMMAND, SC_MOVE + HTCAPTION, lParam );
break;
case HTSYSMENU:
......@@ -2077,20 +2077,20 @@ LONG NC_HandleNCLButtonDown( WND* pWnd, WPARAM16 wParam, LPARAM lParam )
NC_DrawSysButton95( hwnd, hDC, TRUE );
ReleaseDC( hwnd, hDC );
}
SendMessage16( hwnd, WM_SYSCOMMAND, SC_MOUSEMENU + HTSYSMENU, lParam );
SendMessageW( hwnd, WM_SYSCOMMAND, SC_MOUSEMENU + HTSYSMENU, lParam );
}
break;
case HTMENU:
SendMessage16( hwnd, WM_SYSCOMMAND, SC_MOUSEMENU, lParam );
SendMessageW( hwnd, WM_SYSCOMMAND, SC_MOUSEMENU, lParam );
break;
case HTHSCROLL:
SendMessage16( hwnd, WM_SYSCOMMAND, SC_HSCROLL + HTHSCROLL, lParam );
SendMessageW( hwnd, WM_SYSCOMMAND, SC_HSCROLL + HTHSCROLL, lParam );
break;
case HTVSCROLL:
SendMessage16( hwnd, WM_SYSCOMMAND, SC_VSCROLL + HTVSCROLL, lParam );
SendMessageW( hwnd, WM_SYSCOMMAND, SC_VSCROLL + HTVSCROLL, lParam );
break;
case HTMINBUTTON:
......@@ -2115,7 +2115,7 @@ LONG NC_HandleNCLButtonDown( WND* pWnd, WPARAM16 wParam, LPARAM lParam )
case HTBOTTOMLEFT:
case HTBOTTOMRIGHT:
/* make sure hittest fits into 0xf and doesn't overlap with HTSYSMENU */
SendMessage16( hwnd, WM_SYSCOMMAND, SC_SIZE + wParam - 2, lParam);
SendMessageW( hwnd, WM_SYSCOMMAND, SC_SIZE + wParam - 2, lParam);
break;
case HTBORDER:
......@@ -2130,7 +2130,7 @@ LONG NC_HandleNCLButtonDown( WND* pWnd, WPARAM16 wParam, LPARAM lParam )
*
* Handle a WM_NCLBUTTONDBLCLK message. Called from DefWindowProc().
*/
LONG NC_HandleNCLButtonDblClk( WND *pWnd, WPARAM16 wParam, LPARAM lParam )
LONG NC_HandleNCLButtonDblClk( WND *pWnd, WPARAM wParam, LPARAM lParam )
{
/*
* if this is an icon, send a restore since we are handling
......@@ -2138,7 +2138,7 @@ LONG NC_HandleNCLButtonDblClk( WND *pWnd, WPARAM16 wParam, LPARAM lParam )
*/
if (pWnd->dwStyle & WS_MINIMIZE)
{
SendMessage16( pWnd->hwndSelf, WM_SYSCOMMAND, SC_RESTORE, lParam );
SendMessageW( pWnd->hwndSelf, WM_SYSCOMMAND, SC_RESTORE, lParam );
return 0;
}
......@@ -2147,24 +2147,21 @@ LONG NC_HandleNCLButtonDblClk( WND *pWnd, WPARAM16 wParam, LPARAM lParam )
case HTCAPTION:
/* stop processing if WS_MAXIMIZEBOX is missing */
if (pWnd->dwStyle & WS_MAXIMIZEBOX)
SendMessage16( pWnd->hwndSelf, WM_SYSCOMMAND,
(pWnd->dwStyle & WS_MAXIMIZE) ? SC_RESTORE : SC_MAXIMIZE,
lParam );
SendMessageW( pWnd->hwndSelf, WM_SYSCOMMAND,
(pWnd->dwStyle & WS_MAXIMIZE) ? SC_RESTORE : SC_MAXIMIZE, lParam );
break;
case HTSYSMENU:
if (!(GetClassWord(pWnd->hwndSelf, GCW_STYLE) & CS_NOCLOSE))
SendMessage16( pWnd->hwndSelf, WM_SYSCOMMAND, SC_CLOSE, lParam );
SendMessageW( pWnd->hwndSelf, WM_SYSCOMMAND, SC_CLOSE, lParam );
break;
case HTHSCROLL:
SendMessage16( pWnd->hwndSelf, WM_SYSCOMMAND, SC_HSCROLL + HTHSCROLL,
lParam );
SendMessageW( pWnd->hwndSelf, WM_SYSCOMMAND, SC_HSCROLL + HTHSCROLL, lParam );
break;
case HTVSCROLL:
SendMessage16( pWnd->hwndSelf, WM_SYSCOMMAND, SC_VSCROLL + HTVSCROLL,
lParam );
SendMessageW( pWnd->hwndSelf, WM_SYSCOMMAND, SC_VSCROLL + HTVSCROLL, lParam );
break;
}
return 0;
......
......@@ -203,7 +203,7 @@ BOOL WINAPI ExitWindowsEx( UINT flags, DWORD reserved )
{
/* Make sure that the window still exists */
if (!IsWindow( (*ppWnd)->hwndSelf )) continue;
if (!SendMessage16( (*ppWnd)->hwndSelf, WM_QUERYENDSESSION, 0, 0 ))
if (!SendMessageW( (*ppWnd)->hwndSelf, WM_QUERYENDSESSION, 0, 0 ))
break;
}
result = !(*ppWnd);
......@@ -213,7 +213,7 @@ BOOL WINAPI ExitWindowsEx( UINT flags, DWORD reserved )
for (ppWnd = list; i > 0; i--, ppWnd++)
{
if (!IsWindow( (*ppWnd)->hwndSelf )) continue;
SendMessage16( (*ppWnd)->hwndSelf, WM_ENDSESSION, result, 0 );
SendMessageW( (*ppWnd)->hwndSelf, WM_ENDSESSION, result, 0 );
}
WIN_ReleaseWinArray(list);
......
......@@ -2164,7 +2164,7 @@ BOOL WINAPI SetWindowTextW( HWND hwnd, LPCWSTR lpString )
*/
INT16 WINAPI GetWindowTextLength16( HWND16 hwnd )
{
return (INT16)SendMessage16( hwnd, WM_GETTEXTLENGTH, 0, 0 );
return (INT16)GetWindowTextLengthA( hwnd );
}
......@@ -2985,7 +2985,7 @@ BOOL WINAPI FlashWindow( HWND hWnd, BOOL bInvert )
{
HDC hDC = GetDC(hWnd);
if (!SendMessage16( hWnd, WM_ERASEBKGND, (WPARAM16)hDC, 0 ))
if (!SendMessageW( hWnd, WM_ERASEBKGND, (WPARAM16)hDC, 0 ))
wndPtr->flags |= WIN_NEEDS_ERASEBKGND;
ReleaseDC( hWnd, hDC );
......@@ -3005,7 +3005,7 @@ BOOL WINAPI FlashWindow( HWND hWnd, BOOL bInvert )
if (bInvert) wparam = !(wndPtr->flags & WIN_NCACTIVATED);
else wparam = (hWnd == GetActiveWindow());
SendMessage16( hWnd, WM_NCACTIVATE, wparam, (LPARAM)0 );
SendMessageW( hWnd, WM_NCACTIVATE, wparam, (LPARAM)0 );
WIN_ReleaseWndPtr(wndPtr);
return wparam;
}
......
......@@ -1543,8 +1543,8 @@ BOOL WINPOS_SetActiveWindow( HWND hWnd, BOOL fMouse, BOOL fChangeFocus)
PERQDATA_SetActiveWnd( pOldActiveQueue->pQData, 0 );
/* send palette messages */
if (hWnd && SendMessage16( hWnd, WM_QUERYNEWPALETTE, 0, 0L))
SendMessage16((HWND16)-1, WM_PALETTEISCHANGING, (WPARAM16)hWnd, 0L );
if (hWnd && SendMessageW( hWnd, WM_QUERYNEWPALETTE, 0, 0L))
SendMessageW( HWND_BROADCAST, WM_PALETTEISCHANGING, (WPARAM)hWnd, 0 );
/* if prev wnd is minimized redraw icon title */
if( IsIconic( hwndPrevActive ) ) WINPOS_RedrawIconTitle(hwndPrevActive);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment