mirror of
https://github.com/reactos/reactos.git
synced 2025-04-21 12:40:33 +00:00
Only set text resource in DefWndProcA on WM_NCCREATE if passed and exists
See issue #4766 for more details. svn path=/trunk/; revision=42521
This commit is contained in:
parent
3786d6dd01
commit
0656aaaacd
1 changed files with 11 additions and 7 deletions
|
@ -1883,14 +1883,18 @@ DefWindowProcA(HWND hWnd,
|
|||
switch (Msg)
|
||||
{
|
||||
case WM_NCCREATE:
|
||||
{
|
||||
if (lParam)
|
||||
{
|
||||
LPCREATESTRUCTA cs = (LPCREATESTRUCTA)lParam;
|
||||
/* check for string, as static icons, bitmaps (SS_ICON, SS_BITMAP)
|
||||
* may have child window IDs instead of window name */
|
||||
|
||||
if (HIWORD(cs->lpszName))
|
||||
{
|
||||
DefSetText(hWnd, (PCWSTR)cs->lpszName, TRUE);
|
||||
|
||||
}
|
||||
Result = 1;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue