- Use internal function to validate menu handle. See CORE-11479 for more information.
svn path=/trunk/; revision=71704
+BOOL
+FASTCALL
+IntIsMenu(HMENU Menu)
+{
+ if (UserGetMenuObject(Menu)) return TRUE;
+ return FALSE;
+}
+
+
PMENU WINAPI
IntGetMenu(HWND hWnd)
{
PMENU WINAPI
IntGetMenu(HWND hWnd)
{
+BOOL FASTCALL IntIsMenu(HMENU);
+
PMENU FASTCALL
IntGetMenuObject(HMENU hMenu);
PMENU FASTCALL
IntGetMenuObject(HMENU hMenu);
#define HAS_THINFRAME(Style, ExStyle) \
(((Style) & WS_BORDER) || (!((Style) & (WS_CHILD | WS_POPUP))))
#define HAS_THINFRAME(Style, ExStyle) \
(((Style) & WS_BORDER) || (!((Style) & (WS_CHILD | WS_POPUP))))
-#define HAS_MENU(pWnd,style) ((((style) & (WS_CHILD | WS_POPUP)) != WS_CHILD) && pWnd->IDMenu)
+#define HAS_MENU(pWnd,style) ((((style) & (WS_CHILD | WS_POPUP)) != WS_CHILD) && IntIsMenu(UlongToHandle(pWnd->IDMenu)))
#define IntIsDesktopWindow(WndObj) \
(WndObj->spwndParent == NULL)
#define IntIsDesktopWindow(WndObj) \
(WndObj->spwndParent == NULL)