Author: fireball Date: Fri Jul 17 22:34:31 2009 New Revision: 42019
URL: http://svn.reactos.org/svn/reactos?rev=42019&view=rev Log: - Add more missing defines to PSDK headers. - User32 almost compiles, but a lot of serious warnings are there.
Modified: branches/arwinss/reactos/dll/win32/user32/winproc.c branches/arwinss/reactos/dll/win32/user32/wsprintf.c branches/arwinss/reactos/include/psdk/wingdi.h branches/arwinss/reactos/include/psdk/winuser.h branches/arwinss/reactos/include/reactos/wine/winuser16.h
Modified: branches/arwinss/reactos/dll/win32/user32/winproc.c URL: http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/dll/win32/user32... ============================================================================== --- branches/arwinss/reactos/dll/win32/user32/winproc.c [iso-8859-1] (original) +++ branches/arwinss/reactos/dll/win32/user32/winproc.c [iso-8859-1] Fri Jul 17 22:34:31 2009 @@ -318,6 +318,7 @@ } #endif /* __i386__ */
+#ifndef __REACTOS__ static void RECT16to32( const RECT16 *from, RECT *to ) { to->left = from->left; @@ -441,6 +442,7 @@ to->szTitle = MapSL(from->szTitle); to->szClass = MapSL(from->szClass); } +#endif
static WPARAM map_wparam_char_WtoA( WPARAM wParam, DWORD len ) { @@ -497,6 +499,7 @@ }
/* call a 16-bit window procedure */ +#ifndef __REACTOS__ static LRESULT call_window_proc16( HWND16 hwnd, UINT16 msg, WPARAM16 wParam, LPARAM lParam, LRESULT *result, void *arg ) { @@ -617,6 +620,7 @@ if (!ptr) return 0; return alloc_win16_thunk( ptr ); } +#endif
/********************************************************************** @@ -1287,6 +1291,7 @@ /********************************************************************** * WINPROC_CallProc16To32A */ +#ifndef __REACTOS__ LRESULT WINPROC_CallProc16To32A( winproc_callback_t callback, HWND16 hwnd, UINT16 msg, WPARAM16 wParam, LPARAM lParam, LRESULT *result, void *arg ) { @@ -2179,6 +2184,7 @@ } return ret; } +#endif
/********************************************************************** @@ -2214,8 +2220,6 @@ call_window_proc( hwnd, msg, wParam, lParam, result, proc->procW ); else if (proc->procA) WINPROC_CallProcWtoA( call_window_proc, hwnd, msg, wParam, lParam, result, proc->procA ); - else - WINPROC_CallProcWtoA( call_window_proc_Ato16, hwnd, msg, wParam, lParam, result, proc->proc16 ); } else { @@ -2223,8 +2227,6 @@ call_window_proc( hwnd, msg, wParam, lParam, result, proc->procA ); else if (proc->procW) WINPROC_CallProcAtoW( call_window_proc, hwnd, msg, wParam, lParam, result, proc->procW, mapping ); - else - WINPROC_CallProc32ATo16( call_window_proc16, hwnd, msg, wParam, lParam, result, proc->proc16 ); } thread_info->recursion_count--; return TRUE; @@ -2234,6 +2236,7 @@ /********************************************************************** * CallWindowProc (USER.122) */ +#ifndef __REACTOS__ LRESULT WINAPI CallWindowProc16( WNDPROC16 func, HWND16 hwnd, UINT16 msg, WPARAM16 wParam, LPARAM lParam ) { @@ -2253,6 +2256,7 @@
return result; } +#endif
/********************************************************************** @@ -2298,8 +2302,6 @@ else if (proc->procW) WINPROC_CallProcAtoW( call_window_proc, hwnd, msg, wParam, lParam, &result, proc->procW, WMCHAR_MAP_CALLWINDOWPROC ); - else - WINPROC_CallProc32ATo16( call_window_proc16, hwnd, msg, wParam, lParam, &result, proc->proc16 ); return result; }
@@ -2323,8 +2325,6 @@ call_window_proc( hwnd, msg, wParam, lParam, &result, proc->procW ); else if (proc->procA) WINPROC_CallProcWtoA( call_window_proc, hwnd, msg, wParam, lParam, &result, proc->procA ); - else - WINPROC_CallProcWtoA( call_window_proc_Ato16, hwnd, msg, wParam, lParam, &result, proc->proc16 ); return result; }
@@ -2332,6 +2332,7 @@ /********************************************************************** * WINPROC_CallDlgProc16 */ +#ifndef __REACTOS__ INT_PTR WINPROC_CallDlgProc16( DLGPROC16 func, HWND16 hwnd, UINT16 msg, WPARAM16 wParam, LPARAM lParam ) { WINDOWPROC *proc; @@ -2362,6 +2363,7 @@ } return ret; } +#endif
/********************************************************************** @@ -2385,11 +2387,6 @@ proc->procW, WMCHAR_MAP_CALLWINDOWPROC ); SetWindowLongPtrW( hwnd, DWLP_MSGRESULT, result ); } - else - { - ret = WINPROC_CallProc32ATo16( call_dialog_proc16, hwnd, msg, wParam, lParam, &result, proc->proc16 ); - SetWindowLongPtrW( hwnd, DWLP_MSGRESULT, result ); - } return ret; }
@@ -2414,10 +2411,5 @@ ret = WINPROC_CallProcWtoA( call_dialog_proc, hwnd, msg, wParam, lParam, &result, proc->procA ); SetWindowLongPtrW( hwnd, DWLP_MSGRESULT, result ); } - else - { - ret = WINPROC_CallProcWtoA( call_dialog_proc_Ato16, hwnd, msg, wParam, lParam, &result, proc->proc16 ); - SetWindowLongPtrW( hwnd, DWLP_MSGRESULT, result ); - } return ret; }
Modified: branches/arwinss/reactos/dll/win32/user32/wsprintf.c URL: http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/dll/win32/user32... ============================================================================== --- branches/arwinss/reactos/dll/win32/user32/wsprintf.c [iso-8859-1] (original) +++ branches/arwinss/reactos/dll/win32/user32/wsprintf.c [iso-8859-1] Fri Jul 17 22:34:31 2009 @@ -37,6 +37,17 @@
WINE_DEFAULT_DEBUG_CHANNEL(string);
+#ifndef __ms_va_list +# if defined(__x86_64__) && defined (__GNUC__) +# define __ms_va_list __builtin_ms_va_list +# define __ms_va_start(list,arg) __builtin_ms_va_start(list,arg) +# define __ms_va_end(list) __builtin_ms_va_end(list) +# else +# define __ms_va_list va_list +# define __ms_va_start(list,arg) va_start(list,arg) +# define __ms_va_end(list) va_end(list) +# endif +#endif
#define WPRINTF_LEFTALIGN 0x0001 /* Align output on the left ('-' prefix) */ #define WPRINTF_PREFIX_HEX 0x0002 /* Prefix hex with 0x ('#' prefix) */
Modified: branches/arwinss/reactos/include/psdk/wingdi.h URL: http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/include/psdk/win... ============================================================================== --- branches/arwinss/reactos/include/psdk/wingdi.h [iso-8859-1] (original) +++ branches/arwinss/reactos/include/psdk/wingdi.h [iso-8859-1] Fri Jul 17 22:34:31 2009 @@ -69,6 +69,7 @@ #define DI_MASK 1 #define DI_NORMAL 3 #define DI_APPBANDING 1 +#define DI_NOMIRROR 0x0010 #define EMR_HEADER 1 #define EMR_POLYBEZIER 2 #define EMR_POLYGON 3
Modified: branches/arwinss/reactos/include/psdk/winuser.h URL: http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/include/psdk/win... ============================================================================== --- branches/arwinss/reactos/include/psdk/winuser.h [iso-8859-1] (original) +++ branches/arwinss/reactos/include/psdk/winuser.h [iso-8859-1] Fri Jul 17 22:34:31 2009 @@ -311,6 +311,7 @@ #define ES_RIGHT 2 #define ES_UPPERCASE 8 #define ES_WANTRETURN 4096 +#define ES_COMBO 0x00000200 /* Undocumented. Parent is a combobox */ #define LBS_DISABLENOSCROLL 4096 #define LBS_EXTENDEDSEL 0x800 #define LBS_HASSTRINGS 64 @@ -391,6 +392,7 @@ #define WS_EX_COMPOSITED 0x2000000 /* XP */ #define WS_EX_CONTEXTHELP 0x400 #define WS_EX_CONTROLPARENT 0x10000 +#define WS_EX_DRAGDETECT 0x00000002L #define WS_EX_DLGMODALFRAME 1 #define WS_EX_LAYERED 0x80000 /* w2k */ #define WS_EX_LAYOUTRTL 0x400000 /* w98, w2k */ @@ -869,6 +871,8 @@ #endif #define QS_SENDMESSAGE 64 #define QS_TIMER 16 +/* Extra (undocumented) queue wake bits - see "Undoc. Windows" */ +#define QS_SMRESULT 0x8000
#define USER_TIMER_MAXIMUM 2147483647 #define USER_TIMER_MINIMUM 10 @@ -1205,6 +1209,10 @@ #define SWP_NOSENDCHANGING 1024 #define SWP_DEFERERASE 8192 #define SWP_ASYNCWINDOWPOS 16384 +/* undocumented SWP flags - from SDK 3.1 */ +#define SWP_NOCLIENTSIZE 0x0800 +#define SWP_NOCLIENTMOVE 0x1000 +#define SWP_STATECHANGED 0x8000
#define HSHELL_WINDOWCREATED 1 #define HSHELL_WINDOWDESTROYED 2 @@ -1563,6 +1571,7 @@ #define WM_ACTIVATE 6 #define WM_SETFOCUS 7 #define WM_KILLFOCUS 8 +#define WM_SETVISIBLE 9 #define WM_ENABLE 10 #define WM_SETREDRAW 11 #define WM_SETTEXT 12 @@ -1619,6 +1628,7 @@ #define WM_NOTIFY 78 #define WM_INPUTLANGCHANGEREQUEST 80 #define WM_INPUTLANGCHANGE 81 +#define WM_ISACTIVEICON 0x0035 #define WM_TCARD 82 #define WM_HELP 83 #define WM_USERCHANGED 84 @@ -1656,6 +1666,7 @@ #define WM_NCXBUTTONDBLCLK 173 #endif /* (_WIN32_WINNT >= 0x0500) */
+#define WM_KEYF1 0x004d #define WM_KEYFIRST 256 #define WM_KEYDOWN 256 #define WM_KEYUP 257 @@ -1689,6 +1700,7 @@ #define WM_VSCROLL 277 #define WM_INITMENU 278 #define WM_INITMENUPOPUP 279 +#define WM_SYSTIMER 280 #define WM_MENUSELECT 287 #define WM_MENUCHAR 288 #define WM_ENTERIDLE 289 @@ -1708,6 +1720,14 @@ #endif /* _WIN32_WCE */ #endif /* (WINVER >= 0x0500) */
+ /* D&D messages */ +#define WM_DROPOBJECT 0x022A +#define WM_QUERYDROPOBJECT 0x022B +#define WM_BEGINDRAG 0x022C +#define WM_DRAGLOOP 0x022D +#define WM_DRAGSELECT 0x022E +#define WM_DRAGMOVE 0x022F + #define WM_CTLCOLORMSGBOX 306 #define WM_CTLCOLOREDIT 307 #define WM_CTLCOLORLISTBOX 308 @@ -1715,8 +1735,10 @@ #define WM_CTLCOLORDLG 310 #define WM_CTLCOLORSCROLLBAR 311 #define WM_CTLCOLORSTATIC 312 +#define WM_CTLCOLOR 25 #define WM_MOUSEFIRST 512 #define WM_MOUSEMOVE 512 +#define WM_LBTRACKPOINT 0x0131 #define WM_LBUTTONDOWN 513 #define WM_LBUTTONUP 514 #define WM_LBUTTONDBLCLK 515 @@ -1805,6 +1827,7 @@ #define WM_HOTKEY 786 #define WM_PRINT 791 #define WM_PRINTCLIENT 792 +#define WM_APPCOMMAND 793 #define WM_HANDHELDFIRST 856 #define WM_HANDHELDLAST 863 #define WM_AFXFIRST 864 @@ -1878,6 +1901,7 @@ #define CB_SETLOCALE 345 #define CB_SETTOPINDEX 348 #define CB_SHOWDROPDOWN 335 +#define CB_MSGMAX 0x0165 #define CBN_CLOSEUP 8 #define CBN_DBLCLK 2 #define CBN_DROPDOWN 7 @@ -1938,9 +1962,8 @@ #define EN_VSCROLL 1538 #define LB_ADDFILE 406 #define LB_ADDSTRING 384 -#ifdef _WINE -#define LB_CARETOFF 420 -#endif +#define LB_CARETON 0x01a3 +#define LB_CARETOFF 0x01a4 #define LB_DELETESTRING 386 #define LB_DIR 397 #define LB_FINDSTRING 399 @@ -3857,7 +3880,7 @@ HWND WINAPI CreateDialogIndirectParamW(HINSTANCE,LPCDLGTEMPLATE,HWND,DLGPROC,LPARAM); HWND WINAPI CreateDialogParamA(HINSTANCE,LPCSTR,HWND,DLGPROC,LPARAM); HWND WINAPI CreateDialogParamW(HINSTANCE,LPCWSTR,HWND,DLGPROC,LPARAM); -HICON WINAPI CreateIcon(HINSTANCE,int,int,BYTE,BYTE,const BYTE*,const BYTE*); +HICON WINAPI CreateIcon(HINSTANCE,INT,INT,BYTE,BYTE,LPCVOID,LPCVOID); HICON WINAPI CreateIconFromResource(PBYTE,DWORD,BOOL,DWORD); HICON WINAPI CreateIconFromResourceEx(PBYTE,DWORD,BOOL,DWORD,int,int,UINT); HICON WINAPI CreateIconIndirect(PICONINFO); @@ -3870,8 +3893,8 @@ HWND WINAPI CreateWindowExA(DWORD,LPCSTR,LPCSTR,DWORD,int,int,int,int,HWND,HMENU,HINSTANCE,LPVOID); HWND WINAPI CreateWindowExW(DWORD,LPCWSTR,LPCWSTR,DWORD,int,int,int,int,HWND,HMENU,HINSTANCE,LPVOID); #ifndef NOWINDOWSTATION -HWINSTA WINAPI CreateWindowStationA(LPSTR,DWORD,DWORD,LPSECURITY_ATTRIBUTES); -HWINSTA WINAPI CreateWindowStationW(LPWSTR,DWORD,DWORD,LPSECURITY_ATTRIBUTES); +HWINSTA WINAPI CreateWindowStationA(LPCSTR,DWORD,ACCESS_MASK,LPSECURITY_ATTRIBUTES); +HWINSTA WINAPI CreateWindowStationW(LPCWSTR,DWORD,ACCESS_MASK,LPSECURITY_ATTRIBUTES); #endif LRESULT WINAPI DefDlgProcA(HWND,UINT,WPARAM,LPARAM); LRESULT WINAPI DefDlgProcW(HWND,UINT,WPARAM,LPARAM); @@ -4016,7 +4039,7 @@ HDC WINAPI GetDC(HWND); HDC WINAPI GetDCEx(HWND,HRGN,DWORD); HWND WINAPI GetDesktopWindow(void); -long WINAPI GetDialogBaseUnits(void); +DWORD WINAPI GetDialogBaseUnits(void); int WINAPI GetDlgCtrlID(HWND); HWND WINAPI GetDlgItem(HWND,int); UINT WINAPI GetDlgItemInt(HWND,int,PBOOL,BOOL); @@ -4251,12 +4274,12 @@ BOOL WINAPI OemToCharW(LPCSTR,LPWSTR); BOOL WINAPI OffsetRect(LPRECT,int,int); BOOL WINAPI OpenClipboard(HWND); -HDESK WINAPI OpenDesktopA(LPSTR,DWORD,BOOL,DWORD); -HDESK WINAPI OpenDesktopW(LPWSTR,DWORD,BOOL,DWORD); +HDESK WINAPI OpenDesktopA(LPCSTR,DWORD,BOOL,DWORD); +HDESK WINAPI OpenDesktopW(LPCWSTR,DWORD,BOOL,DWORD); BOOL WINAPI OpenIcon(HWND); HDESK WINAPI OpenInputDesktop(DWORD,BOOL,DWORD); -HWINSTA WINAPI OpenWindowStationA(LPSTR,BOOL,DWORD); -HWINSTA WINAPI OpenWindowStationW(LPWSTR,BOOL,DWORD); +HWINSTA WINAPI OpenWindowStationA(LPCSTR,BOOL,DWORD); +HWINSTA WINAPI OpenWindowStationW(LPCWSTR,BOOL,DWORD); BOOL WINAPI PaintDesktop(HDC); BOOL WINAPI PeekMessageA(LPMSG,HWND,UINT,UINT,UINT); BOOL WINAPI PeekMessageW(LPMSG,HWND,UINT,UINT,UINT); @@ -4290,7 +4313,7 @@ BOOL WINAPI RegisterHotKey(HWND,int,UINT,UINT); BOOL WINAPI RegisterLogonProcess(DWORD,BOOL); #if (_WIN32_WINNT >= 0x0501) -BOOL WINAPI RegisterRawInputDevices(PCRAWINPUTDEVICE,UINT,UINT); +BOOL WINAPI RegisterRawInputDevices(PRAWINPUTDEVICE,UINT,UINT); #endif BOOL WINAPI RegisterShellHookWindow(HWND); UINT WINAPI RegisterWindowMessageA(LPCSTR); @@ -4413,10 +4436,10 @@ LONG WINAPI TabbedTextOutA(HDC,int,int,LPCSTR,int,int,LPINT,int); LONG WINAPI TabbedTextOutW(HDC,int,int,LPCWSTR,int,int,LPINT,int); WORD WINAPI TileWindows(HWND,UINT,LPCRECT,UINT,const HWND *); -int WINAPI ToAscii(UINT,UINT,PBYTE,LPWORD,UINT); -int WINAPI ToAsciiEx(UINT,UINT,PBYTE,LPWORD,UINT,HKL); -int WINAPI ToUnicode(UINT,UINT,PBYTE,LPWSTR,int,UINT); -int WINAPI ToUnicodeEx(UINT,UINT,PBYTE,LPWSTR,int,UINT,HKL); +int WINAPI ToAscii(UINT,UINT,const BYTE *,LPWORD,UINT); +int WINAPI ToAsciiEx(UINT,UINT,const BYTE *,LPWORD,UINT,HKL); +INT WINAPI ToUnicode(UINT,UINT,const BYTE *,LPWSTR,int,UINT); +INT WINAPI ToUnicodeEx(UINT,UINT,const BYTE *,LPWSTR,int,UINT,HKL); BOOL WINAPI TrackMouseEvent(LPTRACKMOUSEEVENT); BOOL WINAPI TrackPopupMenu(HMENU,UINT,int,int,int,HWND,LPCRECT); BOOL WINAPI TrackPopupMenuEx(HMENU,UINT,int,int,HWND,LPTPMPARAMS); @@ -4441,8 +4464,8 @@ BOOL WINAPI ValidateRect(HWND,LPCRECT); BOOL WINAPI ValidateRgn(HWND,HRGN); SHORT WINAPI VkKeyScanA(CHAR); -SHORT WINAPI VkKeyScanExA(CHAR,HKL); -SHORT WINAPI VkKeyScanExW(WCHAR,HKL); +WORD WINAPI VkKeyScanExA(CHAR,HKL); +WORD WINAPI VkKeyScanExW(WCHAR,HKL); SHORT WINAPI VkKeyScanW(WCHAR); DWORD WINAPI WaitForInputIdle(HANDLE,DWORD); BOOL WINAPI WaitMessage(void);
Modified: branches/arwinss/reactos/include/reactos/wine/winuser16.h URL: http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/include/reactos/... ============================================================================== --- branches/arwinss/reactos/include/reactos/wine/winuser16.h [iso-8859-1] (original) +++ branches/arwinss/reactos/include/reactos/wine/winuser16.h [iso-8859-1] Fri Jul 17 22:34:31 2009 @@ -47,6 +47,59 @@ WORD cmd; } ACCEL16, *LPACCEL16;
+ /* Windows */ + +typedef struct +{ + SEGPTR lpCreateParams; + HINSTANCE16 hInstance; + HMENU16 hMenu; + HWND16 hwndParent; + INT16 cy; + INT16 cx; + INT16 y; + INT16 x; + LONG style; + SEGPTR lpszName; + SEGPTR lpszClass; + DWORD dwExStyle; +} CREATESTRUCT16, *LPCREATESTRUCT16; + +typedef struct +{ + SEGPTR szClass; + SEGPTR szTitle; + HINSTANCE16 hOwner; + INT16 x; + INT16 y; + INT16 cx; + INT16 cy; + DWORD style; + LPARAM lParam; +} MDICREATESTRUCT16, *LPMDICREATESTRUCT16; + + /* WM_GETMINMAXINFO struct */ +typedef struct +{ + POINT16 ptReserved; + POINT16 ptMaxSize; + POINT16 ptMaxPosition; + POINT16 ptMinTrackSize; + POINT16 ptMaxTrackSize; +} MINMAXINFO16; + + /* WM_WINDOWPOSCHANGING/CHANGED struct */ +typedef struct tagWINDOWPOS16 +{ + HWND16 hwnd; + HWND16 hwndInsertAfter; + INT16 x; + INT16 y; + INT16 cx; + INT16 cy; + UINT16 flags; +} WINDOWPOS16, *LPWINDOWPOS16; + /* WM_NCCALCSIZE parameter structure */ typedef struct {