[WIN32K] -Implement NtUserCalcMenuBar.

svn path=/trunk/; revision=74278
This commit is contained in:
Giannis Adamopoulos 2017-04-05 21:07:44 +00:00
parent 925499d1b6
commit 3fb8c7bc13
2 changed files with 48 additions and 14 deletions

View file

@ -5285,6 +5285,54 @@ IntSetMenu(
/* FUNCTIONS *****************************************************************/
/*
* @implemented
*/
/* http://www.cyber-ta.org/releases/malware-analysis/public/SOURCES/b47155634ccb2c30630da7e3666d3d07/b47155634ccb2c30630da7e3666d3d07.trace.html#NtUserGetIconSize */
DWORD
APIENTRY
NtUserCalcMenuBar(
HWND hwnd,
DWORD leftBorder,
DWORD rightBorder,
DWORD top,
LPRECT prc )
{
HDC hdc;
PWND Window;
RECT Rect;
DWORD ret;
UserEnterExclusive();
if(!(Window = UserGetWindowObject(hwnd)))
{
EngSetLastError(ERROR_INVALID_WINDOW_HANDLE);
UserLeave();
return 0;
}
hdc = UserGetDCEx(NULL, NULL, DCX_CACHE);
if (!hdc)
{
UserLeave();
return 0;
}
Rect.left = leftBorder;
Rect.right = Window->rcWindow.right - Window->rcWindow.left - rightBorder;
Rect.top = top;
Rect.bottom = 0;
ret = MENU_DrawMenuBar(hdc, &Rect, Window, TRUE);
UserReleaseDC( 0, hdc, FALSE );
UserLeave();
return ret;
}
/*
* @implemented
*/

View file

@ -862,20 +862,6 @@ NtUserTestForInteractiveUser(
return 0;
}
/* http://www.cyber-ta.org/releases/malware-analysis/public/SOURCES/b47155634ccb2c30630da7e3666d3d07/b47155634ccb2c30630da7e3666d3d07.trace.html#NtUserGetIconSize */
DWORD
APIENTRY
NtUserCalcMenuBar(
HWND hwnd,
DWORD x,
DWORD width, // Scale the edge thickness, offset?
DWORD y,
LPRECT prc )
{
ERR("hwnd %p, X %d, Width %d, Y %d, prc 0x%x\n",hwnd,x,width,y,prc);
return 0;
}
DWORD
APIENTRY
NtUserRemoteConnect(