mirror of
https://github.com/reactos/reactos.git
synced 2025-08-02 05:15:41 +00:00
- Started NtUserRegisterClassExWOW and now using the fnIDs. Nothing is used but the IDs. I tested with these changes for over 60 days.
- Implemented NtUserMessageCall, moved our first victim over to use it. This is for bug 2451. svn path=/trunk/; revision=34442
This commit is contained in:
parent
f07b8e70a7
commit
48885ed2c4
6 changed files with 48 additions and 59 deletions
|
@ -19,21 +19,21 @@ static const struct
|
|||
UINT ClsId;
|
||||
} g_SysClasses[] =
|
||||
{
|
||||
{ &DIALOG_builtin_class, CLASS_DIALOG },
|
||||
{ &POPUPMENU_builtin_class, CLASS_POPUPMENU },
|
||||
{ &COMBO_builtin_class, CLASS_COMBO },
|
||||
{ &COMBOLBOX_builtin_class, CLASS_COMBOLBOX },
|
||||
{ &DESKTOP_builtin_class, CLASS_DESKTOP },
|
||||
{ &MDICLIENT_builtin_class, CLASS_MDICLIENT },
|
||||
{ &DIALOG_builtin_class, FNID_DIALOG },
|
||||
{ &POPUPMENU_builtin_class, FNID_MENU },
|
||||
{ &COMBO_builtin_class, FNID_COMBOBOX },
|
||||
{ &COMBOLBOX_builtin_class, FNID_COMBOLBOX },
|
||||
{ &DESKTOP_builtin_class, FNID_DESKTOP },
|
||||
{ &MDICLIENT_builtin_class, FNID_MDICLIENT },
|
||||
#if 0
|
||||
{ &MENU_builtin_class, CLASS_MENU },
|
||||
{ &MENU_builtin_class, FNID_MENU },
|
||||
#endif
|
||||
{ &SCROLL_builtin_class, CLASS_SCROLL },
|
||||
{ &BUTTON_builtin_class, CLASS_BUTTON },
|
||||
{ &LISTBOX_builtin_class, CLASS_LISTBOX },
|
||||
{ &EDIT_builtin_class, CLASS_EDIT },
|
||||
{ &ICONTITLE_builtin_class, CLASS_ICONTITLE },
|
||||
{ &STATIC_builtin_class, CLASS_STATIC },
|
||||
{ &SCROLL_builtin_class, FNID_SCROLLBAR },
|
||||
{ &BUTTON_builtin_class, FNID_BUTTON },
|
||||
{ &LISTBOX_builtin_class, FNID_LISTBOX },
|
||||
{ &EDIT_builtin_class, FNID_EDIT },
|
||||
{ &ICONTITLE_builtin_class, FNID_ICONTITLE },
|
||||
{ &STATIC_builtin_class, FNID_STATIC },
|
||||
};
|
||||
|
||||
BOOL WINAPI RegisterSystemControls(VOID)
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
/* $Id$
|
||||
*
|
||||
/*
|
||||
* PROJECT: ReactOS user32.dll
|
||||
* COPYRIGHT: GPL - See COPYING in the top level directory
|
||||
* FILE: dll/win32/user32/windows/class.c
|
||||
|
@ -816,6 +815,17 @@ cleanup:
|
|||
return SmallIcon;
|
||||
}
|
||||
|
||||
|
||||
ATOM STDCALL
|
||||
RegisterClassExWOWW(WNDCLASSEXW *lpwcx,
|
||||
LPDWORD pdwWowData,
|
||||
WORD fnID,
|
||||
DWORD dwFlags)
|
||||
{
|
||||
RTL_ATOM Atom = 0;
|
||||
return (ATOM)Atom;
|
||||
}
|
||||
|
||||
/*
|
||||
* @implemented
|
||||
*/
|
||||
|
|
|
@ -1410,21 +1410,7 @@ User32DefWindowProc(HWND hWnd,
|
|||
|
||||
case WM_SHOWWINDOW:
|
||||
{
|
||||
LONG Style;
|
||||
INT Ret = 0;
|
||||
|
||||
if (!lParam) return 0;
|
||||
Style = GetWindowLongW(hWnd, GWL_STYLE);
|
||||
if ((Style & WS_VISIBLE) && wParam) return 0;
|
||||
if (!(Style & WS_VISIBLE) && !wParam) return 0;
|
||||
if (!GetWindow(hWnd, GW_OWNER)) return 0;
|
||||
Ret = NtUserCallTwoParam((DWORD) hWnd, (DWORD) wParam, TWOPARAM_ROUTINE_ROS_SHOWWINDOW);
|
||||
if(Ret)
|
||||
{
|
||||
if( Ret == -1) return 0;
|
||||
return Ret;
|
||||
}
|
||||
ShowWindow(hWnd, wParam ? SW_SHOWNOACTIVATE : SW_HIDE);
|
||||
NtUserMessageCall( hWnd, Msg, wParam, lParam, 0, NUMC_DEFWINDOWPROC, FALSE);
|
||||
break;
|
||||
}
|
||||
|
||||
|
|
|
@ -22,6 +22,13 @@ typedef struct _REGISTER_SYSCLASS
|
|||
UINT ClassId;
|
||||
} REGISTER_SYSCLASS, *PREGISTER_SYSCLASS;
|
||||
|
||||
typedef struct _CLSMENUNAME
|
||||
{
|
||||
LPSTR pszClientAnsiMenuName;
|
||||
LPWSTR pwszClientUnicodeMenuName;
|
||||
PUNICODE_STRING pusMenuName;
|
||||
} CLSMENUNAME, *PCLSMENUNAME;
|
||||
|
||||
typedef struct _USER_OBJHDR
|
||||
{
|
||||
/* This is the common header for all user handle objects */
|
||||
|
@ -78,7 +85,7 @@ typedef struct _WINDOWCLASS
|
|||
INT ClsExtra;
|
||||
INT WndExtra;
|
||||
PVOID Dce;
|
||||
DWORD fnID;
|
||||
DWORD fnID; // New ClassId
|
||||
HINSTANCE hInstance;
|
||||
HANDLE hIcon; /* FIXME - Use pointer! */
|
||||
HANDLE hIconSm; /* FIXME - Use pointer! */
|
||||
|
@ -93,23 +100,7 @@ typedef struct _WINDOWCLASS
|
|||
UINT System : 1;
|
||||
UINT Global : 1;
|
||||
UINT MenuNameIsString : 1;
|
||||
|
||||
#define CLASS_DEFAULT 0x0
|
||||
#define CLASS_DESKTOP 0x1
|
||||
#define CLASS_DIALOG 0x2
|
||||
#define CLASS_POPUPMENU 0x3
|
||||
#define CLASS_COMBO 0x4
|
||||
#define CLASS_COMBOLBOX 0x5
|
||||
#define CLASS_MDICLIENT 0x6
|
||||
#define CLASS_MENU 0x7
|
||||
#define CLASS_SCROLL 0x8
|
||||
#define CLASS_BUTTON 0x9
|
||||
#define CLASS_LISTBOX 0xA
|
||||
#define CLASS_EDIT 0xB
|
||||
#define CLASS_ICONTITLE 0xC
|
||||
#define CLASS_STATIC 0xD
|
||||
UINT ClassId : 4;
|
||||
|
||||
UINT NotUsed : 27;
|
||||
} WINDOWCLASS, *PWINDOWCLASS;
|
||||
|
||||
typedef struct _WINDOW
|
||||
|
@ -1734,7 +1725,8 @@ NtUserMapVirtualKeyEx( UINT keyCode,
|
|||
UINT transType,
|
||||
DWORD keyboardId,
|
||||
HKL dwhkl );
|
||||
|
||||
// Look like fnID's
|
||||
#define NUMC_DEFWINDOWPROC 0x029E
|
||||
#define NUMC_SENDMESSAGE 0x02B0
|
||||
// Kernel has option to use TO or normal msg send, based on type of msg.
|
||||
#define NUMC_SENDMESSAGEWTOOPTION 0x02B1
|
||||
|
@ -1963,16 +1955,16 @@ NtUserRedrawWindow
|
|||
UINT flags
|
||||
);
|
||||
|
||||
HWINSTA
|
||||
RTL_ATOM
|
||||
NTAPI
|
||||
NtUserRegisterClassExWOW(
|
||||
CONST WNDCLASSEXW* lpwcx,
|
||||
BOOL bUnicodeClass,
|
||||
WNDPROC wpExtra,
|
||||
DWORD dwUnknown4,
|
||||
WNDCLASSEXW* lpwcx,
|
||||
PUNICODE_STRING pustrClassName,
|
||||
PUNICODE_STRING pustrCNVersion,
|
||||
PCLSMENUNAME pClassMenuName,
|
||||
DWORD fnID,
|
||||
DWORD dwUnknown6,
|
||||
DWORD dwUnknown7);
|
||||
DWORD Flags,
|
||||
LPDWORD pWow);
|
||||
|
||||
BOOL
|
||||
NTAPI
|
||||
|
@ -2490,7 +2482,7 @@ NTAPI
|
|||
NtUserUnregisterClass(
|
||||
PUNICODE_STRING ClassNameOrAtom,
|
||||
HINSTANCE hInstance,
|
||||
DWORD Unknown);
|
||||
PCLSMENUNAME pClassMenuName);
|
||||
|
||||
BOOL
|
||||
NTAPI
|
||||
|
@ -2668,7 +2660,6 @@ typedef struct tagKMDDELPARAM
|
|||
#define TWOPARAM_ROUTINE_GETSYSCOLORBRUSHES 0xfffd0063
|
||||
#define TWOPARAM_ROUTINE_GETSYSCOLORPENS 0xfffd0064
|
||||
#define TWOPARAM_ROUTINE_GETSYSCOLORS 0xfffd0065
|
||||
#define TWOPARAM_ROUTINE_ROS_SHOWWINDOW 0x1000
|
||||
#define TWOPARAM_ROUTINE_ROS_ISACTIVEICON 0x1001
|
||||
#define TWOPARAM_ROUTINE_ROS_NCDESTROY 0x1002
|
||||
#define TWOPARAM_ROUTINE_ROS_REGSYSCLASSES 0x1003
|
||||
|
|
|
@ -5,6 +5,8 @@
|
|||
#define SWP_NOCLIENTMOVE 0x0800
|
||||
#define SWP_NOCLIENTSIZE 0x1000
|
||||
|
||||
#define WIN_NEEDS_SHOW_OWNEDPOPUP (0x00000140)
|
||||
|
||||
#define IntPtInWindow(WndObject,x,y) \
|
||||
((x) >= (WndObject)->Wnd->WindowRect.left && \
|
||||
(x) < (WndObject)->Wnd->WindowRect.right && \
|
||||
|
|
|
@ -697,8 +697,8 @@ NtUserMenuInfo 3
|
|||
NtUserMenuItemInfo 5
|
||||
NtUserMonitorFromPoint 3
|
||||
NtUserMonitorFromRect 2
|
||||
NtUserMonitorFromWindow 2
|
||||
NtUserRegisterClassEx 6
|
||||
NtUserMonitorFromWindow 2
|
||||
NtUserSendMessage 5
|
||||
NtUserSendMessageTimeout 8
|
||||
NtUserSendNotifyMessage 4
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue