--- controls/menu.c_or Thu May 17 12:28:36 2001 +++ controls/menu.c Sun May 20 02:48:17 2001 @@ -3023,12 +3023,15 @@ if ((menu = MENU_GetMenu( hMenu )) && (!menu->Height)) { /* app changed/recreated menu bar entries in WM_INITMENU Recalculate menu sizes else clicks will not work */ - RECT r; - HDC hdc = GetDCEx( hWnd, 0, DCX_CACHE | DCX_WINDOW ); - SelectObject( hdc, hMenuFont); - GetClientRect(hWnd, &r); /* probably too simple */ - MENU_MenuBarCalcSize( hdc, &r, menu, hWnd ); - ReleaseDC(hWnd, hdc); + RECT tmprect; + WND *wndPtr=WIN_FindWndPtr(hWnd); + if (wndPtr != NULL) { + tmprect=wndPtr->rectWindow; + NC_HandleNCCalcSize(wndPtr,&tmprect); + WIN_ReleaseWndPtr(wndPtr); + } else { + WARN("wndPtr is NULL"); + } } } return TRUE;