ReactOS.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
List overview
Download
Ros-diffs
June 2005
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
ros-diffs@reactos.org
22 participants
649 discussions
Start a n
N
ew thread
[navaraf] 16099: Cleanup header usage in USER32.
by navaraf@svn.reactos.com
Cleanup header usage in USER32. Modified: trunk/reactos/lib/user32/controls/button.c Modified: trunk/reactos/lib/user32/controls/combo.c Modified: trunk/reactos/lib/user32/controls/edit.c Modified: trunk/reactos/lib/user32/controls/listbox.c Modified: trunk/reactos/lib/user32/controls/regcontrol.c Modified: trunk/reactos/lib/user32/controls/scrollbar.c Modified: trunk/reactos/lib/user32/controls/static.c Modified: trunk/reactos/lib/user32/include/user32.h Modified: trunk/reactos/lib/user32/misc/dde.c Modified: trunk/reactos/lib/user32/misc/desktop.c Modified: trunk/reactos/lib/user32/misc/display.c Modified: trunk/reactos/lib/user32/misc/dllmain.c Modified: trunk/reactos/lib/user32/misc/exit.c Modified: trunk/reactos/lib/user32/misc/exticon.c Modified: trunk/reactos/lib/user32/misc/misc.c Modified: trunk/reactos/lib/user32/misc/object.c Modified: trunk/reactos/lib/user32/misc/resources.c Modified: trunk/reactos/lib/user32/misc/strpool.c Modified: trunk/reactos/lib/user32/misc/stubs.c Modified: trunk/reactos/lib/user32/misc/timer.c Modified: trunk/reactos/lib/user32/misc/winhelp.c Modified: trunk/reactos/lib/user32/misc/winsta.c Modified: trunk/reactos/lib/user32/misc/wsprintf.c Modified: trunk/reactos/lib/user32/windows/accel.c Modified: trunk/reactos/lib/user32/windows/bitmap.c Modified: trunk/reactos/lib/user32/windows/caret.c Modified: trunk/reactos/lib/user32/windows/class.c Modified: trunk/reactos/lib/user32/windows/clipboard.c Modified: trunk/reactos/lib/user32/windows/cursor.c Modified: trunk/reactos/lib/user32/windows/dc.c Modified: trunk/reactos/lib/user32/windows/defwnd.c Modified: trunk/reactos/lib/user32/windows/dialog.c Modified: trunk/reactos/lib/user32/windows/draw.c Modified: trunk/reactos/lib/user32/windows/font.c Modified: trunk/reactos/lib/user32/windows/hook.c Modified: trunk/reactos/lib/user32/windows/icon.c Modified: trunk/reactos/lib/user32/windows/input.c Modified: trunk/reactos/lib/user32/windows/mdi.c Modified: trunk/reactos/lib/user32/windows/menu.c Modified: trunk/reactos/lib/user32/windows/message.c Modified: trunk/reactos/lib/user32/windows/messagebox.c Modified: trunk/reactos/lib/user32/windows/nonclient.c Modified: trunk/reactos/lib/user32/windows/paint.c Modified: trunk/reactos/lib/user32/windows/prop.c Modified: trunk/reactos/lib/user32/windows/rect.c Modified: trunk/reactos/lib/user32/windows/text.c Modified: trunk/reactos/lib/user32/windows/window.c Modified: trunk/reactos/lib/user32/windows/winpos.c _____ Modified: trunk/reactos/lib/user32/controls/button.c --- trunk/reactos/lib/user32/controls/button.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/controls/button.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -19,11 +19,8 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -#ifndef __USE_W32API -#define __USE_W32API -#endif - -#include "user32.h" +#define __WINE__ +#include <user32.h> #include <stdarg.h> #include <string.h> #include <stdlib.h> _____ Modified: trunk/reactos/lib/user32/controls/combo.c --- trunk/reactos/lib/user32/controls/combo.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/controls/combo.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -20,7 +20,8 @@ * FIXME: roll up in Netscape 3.01. */ -#include "user32.h" +#define __WINE__ +#include <user32.h> #include <stdarg.h> #include <string.h> _____ Modified: trunk/reactos/lib/user32/controls/edit.c --- trunk/reactos/lib/user32/controls/edit.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/controls/edit.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -36,11 +36,8 @@ * */ -#ifndef __USE_W32API -#define __USE_W32API -#endif - -#include "user32.h" +#define __WINE__ +#include <user32.h> #include <stdarg.h> #include <string.h> #include <stdlib.h> _____ Modified: trunk/reactos/lib/user32/controls/listbox.c --- trunk/reactos/lib/user32/controls/listbox.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/controls/listbox.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -17,8 +17,9 @@ * License along with this library; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -#include "user32.h" -#define NDEBUG + +#define __WINE__ +#include <user32.h> #include <string.h> #include <stdlib.h> #include "controls.h" _____ Modified: trunk/reactos/lib/user32/controls/regcontrol.c --- trunk/reactos/lib/user32/controls/regcontrol.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/controls/regcontrol.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -9,9 +9,7 @@ * NOTES: Adapted from Wine */ -#include "user32.h" -#include <wchar.h> -#include "win32k/ntuser.h" +#include <user32.h> static void RegisterBuiltinClass(const struct builtin_class_descr *Descr) { _____ Modified: trunk/reactos/lib/user32/controls/scrollbar.c --- trunk/reactos/lib/user32/controls/scrollbar.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/controls/scrollbar.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -30,13 +30,8 @@ /* INCLUDES *******************************************************************/ -#include "user32.h" -#include <debug.h> -#include <draw.h> -#include <stdlib.h> -#include <string.h> +#include <user32.h> #include <oleacc.h> -#include <rosrtl/minmax.h> /* GLOBAL VARIABLES ***********************************************************/ @@ -655,7 +650,11 @@ return si.nMin; } - Pos = RtlRosMax(0, Pos - ScrollBarInfo->dxyLineButton); + Pos = Pos - ScrollBarInfo->dxyLineButton; + if (Pos < 0) + { + Pos = 0; + } if (Pixels < Pos) { Pos = Pixels; _____ Modified: trunk/reactos/lib/user32/controls/static.c --- trunk/reactos/lib/user32/controls/static.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/controls/static.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -18,7 +18,7 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -#include "user32.h" +#include <user32.h> #ifndef __REACTOS__ WINE_DEFAULT_DEBUG_CHANNEL(static); _____ Modified: trunk/reactos/lib/user32/include/user32.h --- trunk/reactos/lib/user32/include/user32.h 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/include/user32.h 2005-06-19 18:06:53 UTC (rev 16099) @@ -4,12 +4,34 @@ * FILE: include/user32.h * PURPOSE: Global user32 definitions */ + +#ifndef USER32_H +#define USER32_H + +#include <ctype.h> +#include <stdio.h> +#include <limits.h> #include <windows.h> +#include <windowsx.h> #define NTOS_MODE_USER #include <ntos.h> #include <win32k/win32k.h> - +#include <win32k/callback.h> +#include "accel.h" +#include "cursor.h" +#ifndef __WINE__ +#include "debug.h" +#endif +#include "draw.h" +#include "menu.h" +#include "message.h" #include "regcontrol.h" +#include "resource.h" +#include "scroll.h" +#include "strpool.h" +#include "window.h" +#include "winpos.h" +#include "winsta.h" extern HINSTANCE User32Instance; @@ -131,3 +153,4 @@ #define NtUserEnableProcessWindowGhosting(bEnable) \ NtUserCallOneParam((DWORD)bEnable, ONEPARAM_ROUTINE_ENABLEPROCWNDGHSTING) +#endif /* USER32_H */ _____ Modified: trunk/reactos/lib/user32/misc/dde.c --- trunk/reactos/lib/user32/misc/dde.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/misc/dde.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -22,10 +22,6 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -#ifndef __USE_W32API -#define __USE_W32API -#endif - #include "wine/config.h" #include "wine/port.h" _____ Modified: trunk/reactos/lib/user32/misc/desktop.c --- trunk/reactos/lib/user32/misc/desktop.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/misc/desktop.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -9,14 +9,9 @@ * 06-06-2001 CSH Created */ -#include "user32.h" -#include "winsta.h" -#include <string.h> -#include <debug.h> +#include <user32.h> #include <rosrtl/devmode.h> #include <rosrtl/logfont.h> -#include <malloc.h> -#include <math.h> /* * @implemented _____ Modified: trunk/reactos/lib/user32/misc/display.c --- trunk/reactos/lib/user32/misc/display.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/misc/display.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,11 +28,8 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" +#include <user32.h> #include <rosrtl/devmode.h> -#include <win32k/ntuser.h> -#define NDEBUG -#include <debug.h> /* FUNCTIONS *****************************************************************/ _____ Modified: trunk/reactos/lib/user32/misc/dllmain.c --- trunk/reactos/lib/user32/misc/dllmain.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/misc/dllmain.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -1,12 +1,5 @@ -#include "user32.h" -#include "menu.h" -#include "message.h" -#include "accel.h" -#include "strpool.h" -#include <win32k/callback.h> +#include <user32.h> -#include <debug.h> - /* FIXME: Belongs to some header. */ WINBOOL STDCALL GdiDllInitialize(HANDLE, DWORD, LPVOID); _____ Modified: trunk/reactos/lib/user32/misc/exit.c --- trunk/reactos/lib/user32/misc/exit.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/misc/exit.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -7,7 +7,7 @@ * PROGRAMMER: Eric Kohl (ekohl(a)rz-online.de) */ -#include "user32.h" +#include <user32.h> #include <ntdll/csr.h> /* _____ Modified: trunk/reactos/lib/user32/misc/exticon.c --- trunk/reactos/lib/user32/misc/exticon.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/misc/exticon.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -22,15 +22,6 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -/* Remove this once w32api conversion is done */ -#ifndef __USE_W32API -#define __USE_W32API -#define _WIN32_IE 0x600 -#define _WIN32_WINNT 0x501 -#define WINVER 0x501 -#define __need_offsetof -#endif /* __USE_W32API */ - #include <stdarg.h> #include <string.h> #include <stdlib.h> /* abs() */ _____ Modified: trunk/reactos/lib/user32/misc/misc.c --- trunk/reactos/lib/user32/misc/misc.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/misc/misc.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,8 +28,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <debug.h> +#include <user32.h> #include <ntdll/csr.h> /* FUNCTIONS *****************************************************************/ _____ Modified: trunk/reactos/lib/user32/misc/object.c --- trunk/reactos/lib/user32/misc/object.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/misc/object.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,8 +28,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <debug.h> +#include <user32.h> /* FUNCTIONS *****************************************************************/ _____ Modified: trunk/reactos/lib/user32/misc/resources.c --- trunk/reactos/lib/user32/misc/resources.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/misc/resources.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -1,5 +1,4 @@ -#include "user32.h" -#include <string.h> +#include <user32.h> /* FIXME: Currently IsBadWritePtr is implemented using VirtualQuery which does not seem to work properly for stack address space. */ _____ Modified: trunk/reactos/lib/user32/misc/strpool.c --- trunk/reactos/lib/user32/misc/strpool.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/misc/strpool.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -1,8 +1,6 @@ // strpool.c -#include "user32.h" -#include <strpool.h> -#include <string.h> +#include <user32.h> typedef struct tagHEAP_STRING_POOLA { _____ Modified: trunk/reactos/lib/user32/misc/stubs.c --- trunk/reactos/lib/user32/misc/stubs.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/misc/stubs.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -10,10 +10,7 @@ * 08-F05-2001 CSH Created */ -#include "user32.h" -#include <debug.h> -#include <string.h> -#include <mmsystem.h> +#include <user32.h> #ifdef __USE_W32API typedef PVOID LPIMEPROW, LPIMEPROA; #endif _____ Modified: trunk/reactos/lib/user32/misc/timer.c --- trunk/reactos/lib/user32/misc/timer.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/misc/timer.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,8 +28,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <debug.h> +#include <user32.h> /* FUNCTIONS *****************************************************************/ _____ Modified: trunk/reactos/lib/user32/misc/winhelp.c --- trunk/reactos/lib/user32/misc/winhelp.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/misc/winhelp.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,9 +28,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <string.h> -#include <debug.h> +#include <user32.h> /* WinHelp internal structure */ typedef struct _____ Modified: trunk/reactos/lib/user32/misc/winsta.c --- trunk/reactos/lib/user32/misc/winsta.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/misc/winsta.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -9,10 +9,8 @@ * 04-06-2001 CSH Created */ -#include "user32.h" -#include <debug.h> +#include <user32.h> - /* * @implemented */ _____ Modified: trunk/reactos/lib/user32/misc/wsprintf.c --- trunk/reactos/lib/user32/misc/wsprintf.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/misc/wsprintf.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -31,11 +31,7 @@ * NOTES: Adapted from Wine */ -#include "user32.h" -#include <stdarg.h> -#include <string.h> -#include <stdio.h> -#include "strpool.h" +#include <user32.h> #define WPRINTF_LEFTALIGN 0x0001 /* Align output on the left ('-' prefix) */ #define WPRINTF_PREFIX_HEX 0x0002 /* Prefix hex with 0x ('#' prefix) */ _____ Modified: trunk/reactos/lib/user32/windows/accel.c --- trunk/reactos/lib/user32/windows/accel.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/accel.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -29,9 +29,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include "accel.h" -#include <win32k/ntuser.h> +#include <user32.h> /* this is the 8 byte accel struct used in Win32 resources (internal only) */ typedef struct _____ Modified: trunk/reactos/lib/user32/windows/bitmap.c --- trunk/reactos/lib/user32/windows/bitmap.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/bitmap.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,10 +28,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <string.h> -#include <debug.h> -#include <stdlib.h> +#include <user32.h> /*forward declerations... actualy in user32\windows\icon.c but usful here****/ HICON ICON_CreateCursorFromData(HDC hDC, PVOID ImageData, ICONIMAGE* IconImage, int cxDesired, int cyDesired, int xHotspot, int yHotspot); _____ Modified: trunk/reactos/lib/user32/windows/caret.c --- trunk/reactos/lib/user32/windows/caret.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/caret.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,8 +28,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <debug.h> +#include <user32.h> /* FUNCTIONS *****************************************************************/ _____ Modified: trunk/reactos/lib/user32/windows/class.c --- trunk/reactos/lib/user32/windows/class.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/class.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -9,14 +9,8 @@ * 09-05-2001 CSH Created */ -#include "user32.h" -#include <string.h> -#include <stdlib.h> -#include <debug.h> -#include <window.h> -#include <strpool.h> +#include <user32.h> - static BOOL GetClassInfoExCommon( HINSTANCE hInst, LPCWSTR lpszClass, _____ Modified: trunk/reactos/lib/user32/windows/clipboard.c --- trunk/reactos/lib/user32/windows/clipboard.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/clipboard.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,10 +28,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <strpool.h> -#define NDEBUG -#include <debug.h> +#include <user32.h> /* FUNCTIONS *****************************************************************/ _____ Modified: trunk/reactos/lib/user32/windows/cursor.c --- trunk/reactos/lib/user32/windows/cursor.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/cursor.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,9 +28,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <string.h> -#include <debug.h> +#include <user32.h> #undef CopyCursor HBITMAP _____ Modified: trunk/reactos/lib/user32/windows/dc.c --- trunk/reactos/lib/user32/windows/dc.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/dc.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,8 +28,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <debug.h> +#include <user32.h> /* FUNCTIONS *****************************************************************/ _____ Modified: trunk/reactos/lib/user32/windows/defwnd.c --- trunk/reactos/lib/user32/windows/defwnd.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/defwnd.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -11,18 +11,8 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <windowsx.h> -#include <window.h> -#include <string.h> -#include <cursor.h> -#include <menu.h> -#include <scroll.h> -#include <winpos.h> +#include <user32.h> -#define NDEBUG -#include <debug.h> - #ifndef WM_SETVISIBLE #define WM_SETVISIBLE 9 #endif _____ Modified: trunk/reactos/lib/user32/windows/dialog.c --- trunk/reactos/lib/user32/windows/dialog.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/dialog.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -31,13 +31,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <string.h> -#include <stdio.h> -#include <stdlib.h> -#include <ctype.h> -#include <limits.h> -#include <debug.h> +#include <user32.h> /* MACROS/DEFINITIONS ********************************************************/ @@ -1235,24 +1229,6 @@ #undef SENDMSG } -/* Hack - We dont define this anywhere and we shouldn't - * Its only used to port buggy WINE code in to our buggy code. - * Make it go away - sedwards - */ -/* strdup macros */ -/* DO NOT USE IT!! it will go away soon */ -inline static LPSTR HEAP_strdupWtoA( HANDLE heap, DWORD flags, LPCWSTR str ) -{ - LPSTR ret; - INT len; - - if (!str) return NULL; - len = WideCharToMultiByte( CP_ACP, 0, str, -1, NULL, 0, NULL, NULL ); - ret = RtlAllocateHeap(GetProcessHeap(), flags, len ); - if(ret) WideCharToMultiByte( CP_ACP, 0, str, -1, ret, len, NULL, NULL ); - return ret; -} - /********************************************************************** * DIALOG_DlgDirListW * @@ -1263,11 +1239,14 @@ { if (spec) { - LPSTR specA = HEAP_strdupWtoA( GetProcessHeap(), 0, spec ); - INT ret = DIALOG_DlgDirList( hDlg, specA, idLBox, idStatic, - attrib, combo ); + LPSTR specA; + INT ret; + + HEAP_strdupWtoA ( &specA, spec, lstrlenW(spec) ); + ret = DIALOG_DlgDirList( hDlg, specA, idLBox, idStatic, + attrib, combo ); MultiByteToWideChar( CP_ACP, 0, specA, -1, spec, 0x7fffffff ); - HeapFree( GetProcessHeap(), 0, specA ); + HEAP_free( specA ); return ret; } return DIALOG_DlgDirList( hDlg, NULL, idLBox, idStatic, attrib, combo ); _____ Modified: trunk/reactos/lib/user32/windows/draw.c --- trunk/reactos/lib/user32/windows/draw.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/draw.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,17 +28,7 @@ /* INCLUDES *******************************************************************/ -#ifndef __USE_W32API -#define __USE_W32API -#define _WIN32_WINNT 0x0500 -#define WINVER 0x0500 -#endif - -#include <windows.h> -#include <string.h> -#include <wine/unicode.h> #include <user32.h> -#include <debug.h> /* GLOBALS *******************************************************************/ @@ -1388,7 +1378,7 @@ if (unicode) nCount = lstrlenW((WCHAR*)lpData); else - nCount = strlen((CHAR*)lpData); + nCount = lstrlenA((CHAR*)lpData); } if (! nWidth || ! nHeight) @@ -1545,9 +1535,9 @@ if((opcode == DST_TEXT || opcode == DST_PREFIXTEXT) && !len) /* The string is '\0' terminated */ { if(unicode) - len = strlenW((LPWSTR)lp); + len = lstrlenW((LPWSTR)lp); else - len = strlen((LPSTR)lp); + len = lstrlenA((LPSTR)lp); } /* Find out what size the image has if not given by caller */ _____ Modified: trunk/reactos/lib/user32/windows/font.c --- trunk/reactos/lib/user32/windows/font.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/font.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,9 +28,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <string.h> -#include <debug.h> +#include <user32.h> /* FUNCTIONS *****************************************************************/ _____ Modified: trunk/reactos/lib/user32/windows/hook.c --- trunk/reactos/lib/user32/windows/hook.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/hook.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,10 +28,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <win32k/callback.h> -#define NDEBUG -#include <debug.h> +#include <user32.h> /* FUNCTIONS *****************************************************************/ _____ Modified: trunk/reactos/lib/user32/windows/icon.c --- trunk/reactos/lib/user32/windows/icon.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/icon.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,10 +28,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <string.h> -#include <stdlib.h> -#include <debug.h> +#include <user32.h> /* FUNCTIONS *****************************************************************/ _____ Modified: trunk/reactos/lib/user32/windows/input.c --- trunk/reactos/lib/user32/windows/input.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/input.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,9 +28,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <debug.h> -#include <wchar.h> +#include <user32.h> /* FUNCTIONS *****************************************************************/ _____ Modified: trunk/reactos/lib/user32/windows/mdi.c --- trunk/reactos/lib/user32/windows/mdi.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/mdi.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -80,6 +80,8 @@ * */ +#define __WINE__ + #include <stdlib.h> #include <stdarg.h> #include <stdio.h> _____ Modified: trunk/reactos/lib/user32/windows/menu.c --- trunk/reactos/lib/user32/windows/menu.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/menu.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -33,18 +33,9 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <ctype.h> -#include <string.h> -#include <draw.h> -#include <window.h> -#include <strpool.h> -#include <win32k/callback.h> +#include <user32.h> #include "../controls/controls.h" -#define NDEBUG -#include <debug.h> - /* internal popup menu window messages */ #define MM_SETMENUHANDLE (WM_USER + 0) #define MM_GETMENUHANDLE (WM_USER + 1) _____ Modified: trunk/reactos/lib/user32/windows/message.c --- trunk/reactos/lib/user32/windows/message.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/message.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -8,11 +8,7 @@ * 06-06-2001 CSH Created */ -#include "user32.h" -#include <string.h> -#include <debug.h> -#include <win32k/callback.h> -#include <message.h> +#include <user32.h> /* DDE message exchange * _____ Modified: trunk/reactos/lib/user32/windows/messagebox.c --- trunk/reactos/lib/user32/windows/messagebox.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/messagebox.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -31,15 +31,8 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <string.h> -#include <stdio.h> -#include <stdlib.h> -#include <debug.h> -#include "resource.h" +#include <user32.h> -#include <mmsystem.h> - /* DEFINES *******************************************************************/ #define MSGBOX_IDICON (1088) _____ Modified: trunk/reactos/lib/user32/windows/nonclient.c --- trunk/reactos/lib/user32/windows/nonclient.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/nonclient.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -30,25 +30,8 @@ #define __REACTOS__ */ -/* - * Use w32api headers - */ -/* -#define __USE_W32API -#define _WIN32_WINNT 0x0501 -*/ - -#include <windows.h> -#include <windowsx.h> -#include <string.h> -#include <menu.h> -#include <winpos.h> #include <user32.h> -#include "window.h" -#define NDEBUG -#include <debug.h> - #define HAS_DLGFRAME(Style, ExStyle) \ (((ExStyle) & WS_EX_DLGMODALFRAME) || \ (((Style) & WS_DLGFRAME) && (!((Style) & (WS_THICKFRAME | WS_MINIMIZE))))) _____ Modified: trunk/reactos/lib/user32/windows/paint.c --- trunk/reactos/lib/user32/windows/paint.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/paint.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,10 +28,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <resource.h> -#define NDEBUG -#include <debug.h> +#include <user32.h> static HBRUSH FrameBrushes[13]; static HBITMAP hHatch; _____ Modified: trunk/reactos/lib/user32/windows/prop.c --- trunk/reactos/lib/user32/windows/prop.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/prop.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,9 +28,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <strpool.h> -#include <debug.h> +#include <user32.h> typedef struct _PROPLISTITEM { _____ Modified: trunk/reactos/lib/user32/windows/rect.c --- trunk/reactos/lib/user32/windows/rect.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/rect.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,8 +28,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <debug.h> +#include <user32.h> /* FUNCTIONS *****************************************************************/ _____ Modified: trunk/reactos/lib/user32/windows/text.c --- trunk/reactos/lib/user32/windows/text.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/text.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -28,11 +28,8 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <ctype.h> -#include <debug.h> +#include <user32.h> - /* FUNCTIONS *****************************************************************/ static WORD _____ Modified: trunk/reactos/lib/user32/windows/window.c --- trunk/reactos/lib/user32/windows/window.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/window.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -11,13 +11,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <window.h> -#include <string.h> -#include <strpool.h> -#include <win32k/callback.h> -#define NDEBUG -#include <debug.h> +#include <user32.h> BOOL ControlsInitialized = FALSE; _____ Modified: trunk/reactos/lib/user32/windows/winpos.c --- trunk/reactos/lib/user32/windows/winpos.c 2005-06-19 17:34:05 UTC (rev 16098) +++ trunk/reactos/lib/user32/windows/winpos.c 2005-06-19 18:06:53 UTC (rev 16099) @@ -11,12 +11,7 @@ /* INCLUDES ******************************************************************/ -#include "user32.h" -#include <window.h> -#include <win32k/callback.h> -#include <window.h> -#define NDEBUG -#include <debug.h> +#include <user32.h> /* FUNCTIONS *****************************************************************/
19 years, 6 months
1
0
0
0
[navaraf] 16098: Remove duplicate header.
by navaraf@svn.reactos.com
Remove duplicate header. Deleted: trunk/reactos/include/lsass/ntsecapi.h _____ Deleted: trunk/reactos/include/lsass/ntsecapi.h --- trunk/reactos/include/lsass/ntsecapi.h 2005-06-19 17:27:44 UTC (rev 16097) +++ trunk/reactos/include/lsass/ntsecapi.h 2005-06-19 17:34:05 UTC (rev 16098) @@ -1,32 +0,0 @@ -/* $Id$ - * - * COPYRIGHT: See COPYING in the top level directory - * PROJECT: ReactOS system libraries - * FILE: include/lsass/ntsecpai.h - * PURPOSE: LSASS API declarations - * UPDATE HISTORY: - * Created 05/08/00 - */ - -#ifndef __INCLUDE_LSASS_NTSECAPI_H -#define __INCLUDE_LSASS_NTSECAPI_H - -#define SECURITY_LOGON_INTERACTIVE (2) -#define SECURITY_LOGON_NETWORK (3) -#define SECURITY_LOGON_BATCH (4) -#define SECURITY_LOGON_SERVICE (5) -#define SECURITY_LOGON_PROXY (6) -#define SECURITY_LOGON_UNLOCK (7) - -typedef ULONG SECURITY_LOGON_TYPE; - -typedef struct _LSA_STRING -{ - USHORT Length; - USHORT MaximumLength; - PWSTR Buffer; -} LSA_STRING, *PLSA_STRING; - -typedef ULONG LSA_OPERATIONAL_MODE, *PLSA_OPERATIONAL_MODE; - -#endif /* __INCLUDE_LSASS_NTSECAPI_H */
19 years, 6 months
1
0
0
0
[navaraf] 16097: (Re)move USER32 headers from include/user32.
by navaraf@svn.reactos.com
(Re)move USER32 headers from include/user32. Deleted: trunk/reactos/include/user32/ Added: trunk/reactos/include/win32k/callback.h Modified: trunk/reactos/lib/user32/controls/button.c Modified: trunk/reactos/lib/user32/controls/combo.c Modified: trunk/reactos/lib/user32/controls/edit.c Modified: trunk/reactos/lib/user32/controls/icontitle.c Modified: trunk/reactos/lib/user32/controls/listbox.c Modified: trunk/reactos/lib/user32/controls/regcontrol.c Modified: trunk/reactos/lib/user32/controls/scrollbar.c Modified: trunk/reactos/lib/user32/controls/static.c Added: trunk/reactos/lib/user32/include/accel.h Added: trunk/reactos/lib/user32/include/regcontrol.h Modified: trunk/reactos/lib/user32/include/user32.h Modified: trunk/reactos/lib/user32/include/window.h Modified: trunk/reactos/lib/user32/misc/dllmain.c Modified: trunk/reactos/lib/user32/windows/accel.c Modified: trunk/reactos/lib/user32/windows/class.c Modified: trunk/reactos/lib/user32/windows/defwnd.c Modified: trunk/reactos/lib/user32/windows/dialog.c Modified: trunk/reactos/lib/user32/windows/hook.c Modified: trunk/reactos/lib/user32/windows/mdi.c Modified: trunk/reactos/lib/user32/windows/menu.c Modified: trunk/reactos/lib/user32/windows/message.c Modified: trunk/reactos/lib/user32/windows/nonclient.c Modified: trunk/reactos/lib/user32/windows/window.c Modified: trunk/reactos/lib/user32/windows/winpos.c Modified: trunk/reactos/subsys/win32k/include/dce.h Modified: trunk/reactos/subsys/win32k/w32k.h _____ Copied: trunk/reactos/include/win32k/callback.h (from rev 16096, trunk/reactos/include/user32/callback.h) _____ Modified: trunk/reactos/lib/user32/controls/button.c --- trunk/reactos/lib/user32/controls/button.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/controls/button.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -29,7 +29,6 @@ #include <stdlib.h> #include "controls.h" -#include "user32/regcontrol.h" #include "wine/unicode.h" #include "wine/debug.h" _____ Modified: trunk/reactos/lib/user32/controls/combo.c --- trunk/reactos/lib/user32/controls/combo.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/controls/combo.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -29,7 +29,6 @@ #include <stdlib.h> #include <stdio.h> #include "controls.h" -#include "user32/regcontrol.h" #include "wine/debug.h" #include "wine/unicode.h" _____ Modified: trunk/reactos/lib/user32/controls/edit.c --- trunk/reactos/lib/user32/controls/edit.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/controls/edit.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -45,7 +45,6 @@ #include <string.h> #include <stdlib.h> #include "controls.h" -#include "user32/regcontrol.h" #include "wine/unicode.h" #include "wine/debug.h" _____ Modified: trunk/reactos/lib/user32/controls/icontitle.c --- trunk/reactos/lib/user32/controls/icontitle.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/controls/icontitle.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -19,7 +19,6 @@ */ #include "user32.h" -#include "user32/regcontrol.h" #include "controls.h" #include "wine/unicode.h" _____ Modified: trunk/reactos/lib/user32/controls/listbox.c --- trunk/reactos/lib/user32/controls/listbox.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/controls/listbox.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -22,7 +22,6 @@ #include <string.h> #include <stdlib.h> #include "controls.h" -#include "user32/regcontrol.h" #include "wine/debug.h" #ifdef __REACTOS__ _____ Modified: trunk/reactos/lib/user32/controls/regcontrol.c --- trunk/reactos/lib/user32/controls/regcontrol.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/controls/regcontrol.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -11,7 +11,6 @@ #include "user32.h" #include <wchar.h> -#include "user32/regcontrol.h" #include "win32k/ntuser.h" static void RegisterBuiltinClass(const struct builtin_class_descr *Descr) _____ Modified: trunk/reactos/lib/user32/controls/scrollbar.c --- trunk/reactos/lib/user32/controls/scrollbar.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/controls/scrollbar.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -36,7 +36,6 @@ #include <stdlib.h> #include <string.h> #include <oleacc.h> -#include <user32/regcontrol.h> #include <rosrtl/minmax.h> /* GLOBAL VARIABLES ***********************************************************/ _____ Modified: trunk/reactos/lib/user32/controls/static.c --- trunk/reactos/lib/user32/controls/static.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/controls/static.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -19,7 +19,6 @@ */ #include "user32.h" -#include "user32/regcontrol.h" #ifndef __REACTOS__ WINE_DEFAULT_DEBUG_CHANNEL(static); _____ Copied: trunk/reactos/lib/user32/include/accel.h (from rev 16096, trunk/reactos/include/user32/accel.h) _____ Copied: trunk/reactos/lib/user32/include/regcontrol.h (from rev 16096, trunk/reactos/include/user32/regcontrol.h) _____ Modified: trunk/reactos/lib/user32/include/user32.h --- trunk/reactos/lib/user32/include/user32.h 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/include/user32.h 2005-06-19 17:27:44 UTC (rev 16097) @@ -9,6 +9,8 @@ #include <ntos.h> #include <win32k/win32k.h> +#include "regcontrol.h" + extern HINSTANCE User32Instance; typedef struct _USER32_THREAD_DATA _____ Modified: trunk/reactos/lib/user32/include/window.h --- trunk/reactos/lib/user32/include/window.h 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/include/window.h 2005-06-19 17:27:44 UTC (rev 16097) @@ -5,7 +5,6 @@ * PURPOSE: Window management definitions */ #include <windows.h> -#include <user32/wininternal.h> extern COLORREF SysColors[]; extern HPEN SysPens[]; _____ Modified: trunk/reactos/lib/user32/misc/dllmain.c --- trunk/reactos/lib/user32/misc/dllmain.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/misc/dllmain.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -1,15 +1,11 @@ -#include <windows.h> +#include "user32.h" +#include "menu.h" +#include "message.h" +#include "accel.h" +#include "strpool.h" +#include <win32k/callback.h> + #include <debug.h> -#include <ddk/ntddk.h> -#include <user32/callback.h> -#include <user32/accel.h> -#include <window.h> -#include <menu.h> -#include <message.h> -#define _WIN32K_KAPI_H -#include <user32.h> -#include <strpool.h> -#include <roscfg.h> /* FIXME: Belongs to some header. */ WINBOOL STDCALL GdiDllInitialize(HANDLE, DWORD, LPVOID); _____ Modified: trunk/reactos/lib/user32/windows/accel.c --- trunk/reactos/lib/user32/windows/accel.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/windows/accel.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -30,7 +30,7 @@ /* INCLUDES ******************************************************************/ #include "user32.h" -#include <user32/accel.h> +#include "accel.h" #include <win32k/ntuser.h> /* this is the 8 byte accel struct used in Win32 resources (internal only) */ _____ Modified: trunk/reactos/lib/user32/windows/class.c --- trunk/reactos/lib/user32/windows/class.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/windows/class.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -15,7 +15,6 @@ #include <debug.h> #include <window.h> #include <strpool.h> -#include <user32/regcontrol.h> static BOOL GetClassInfoExCommon( _____ Modified: trunk/reactos/lib/user32/windows/defwnd.c --- trunk/reactos/lib/user32/windows/defwnd.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/windows/defwnd.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -14,7 +14,6 @@ #include "user32.h" #include <windowsx.h> #include <window.h> -#include <user32/wininternal.h> #include <string.h> #include <cursor.h> #include <menu.h> _____ Modified: trunk/reactos/lib/user32/windows/dialog.c --- trunk/reactos/lib/user32/windows/dialog.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/windows/dialog.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -39,9 +39,6 @@ #include <limits.h> #include <debug.h> -#include "user32/regcontrol.h" -#include "../controls/controls.h" - /* MACROS/DEFINITIONS ********************************************************/ #define DF_END 0x0001 _____ Modified: trunk/reactos/lib/user32/windows/hook.c --- trunk/reactos/lib/user32/windows/hook.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/windows/hook.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -29,7 +29,7 @@ /* INCLUDES ******************************************************************/ #include "user32.h" -#include <user32/callback.h> +#include <win32k/callback.h> #define NDEBUG #include <debug.h> _____ Modified: trunk/reactos/lib/user32/windows/mdi.c --- trunk/reactos/lib/user32/windows/mdi.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/windows/mdi.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -91,7 +91,7 @@ #include "wingdi.h" #include "winuser.h" #include "wine/unicode.h" -#include "user32/regcontrol.h" +#include "user32.h" #include <winnls.h> #include "wine/debug.h" #include "dlgs.h" _____ Modified: trunk/reactos/lib/user32/windows/menu.c --- trunk/reactos/lib/user32/windows/menu.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/windows/menu.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -39,8 +39,7 @@ #include <draw.h> #include <window.h> #include <strpool.h> -#include <user32/callback.h> -#include "user32/regcontrol.h" +#include <win32k/callback.h> #include "../controls/controls.h" #define NDEBUG _____ Modified: trunk/reactos/lib/user32/windows/message.c --- trunk/reactos/lib/user32/windows/message.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/windows/message.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -11,7 +11,7 @@ #include "user32.h" #include <string.h> #include <debug.h> -#include <user32/callback.h> +#include <win32k/callback.h> #include <message.h> /* DDE message exchange _____ Modified: trunk/reactos/lib/user32/windows/nonclient.c --- trunk/reactos/lib/user32/windows/nonclient.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/windows/nonclient.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -43,7 +43,6 @@ #include <string.h> #include <menu.h> #include <winpos.h> -#include <user32/wininternal.h> #include <user32.h> #include "window.h" _____ Modified: trunk/reactos/lib/user32/windows/window.c --- trunk/reactos/lib/user32/windows/window.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/windows/window.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -15,8 +15,7 @@ #include <window.h> #include <string.h> #include <strpool.h> -#include <user32/callback.h> -#include <user32/regcontrol.h> +#include <win32k/callback.h> #define NDEBUG #include <debug.h> _____ Modified: trunk/reactos/lib/user32/windows/winpos.c --- trunk/reactos/lib/user32/windows/winpos.c 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/lib/user32/windows/winpos.c 2005-06-19 17:27:44 UTC (rev 16097) @@ -13,9 +13,7 @@ #include "user32.h" #include <window.h> -#include <user32/callback.h> -#include <user32/regcontrol.h> -#include <user32/wininternal.h> +#include <win32k/callback.h> #include <window.h> #define NDEBUG #include <debug.h> _____ Modified: trunk/reactos/subsys/win32k/include/dce.h --- trunk/reactos/subsys/win32k/include/dce.h 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/subsys/win32k/include/dce.h 2005-06-19 17:27:44 UTC (rev 16097) @@ -5,7 +5,6 @@ typedef struct tagDCE *PDCE; -#include <user32/wininternal.h> #include <include/window.h> typedef HANDLE HDCE; @@ -36,6 +35,14 @@ HANDLE Self; } DCE; /* PDCE already declared at top of file */ +/* internal DCX flags */ +#define DCX_DCEEMPTY 0x00000800 +#define DCX_DCEBUSY 0x00001000 +#define DCX_DCEDIRTY 0x00002000 +#define DCX_WINDOWPAINT 0x00020000 +#define DCX_KEEPCLIPRGN 0x00040000 +#define DCX_NOCLIPCHILDREN 0x00080000 + #define DCEOBJ_AllocDCE() \ ((HDCE) GDIOBJ_AllocObj (GDI_OBJECT_TYPE_DCE)) #define DCEOBJ_FreeDCE(hDCE) GDIOBJ_FreeObj((HGDIOBJ)hDCE, GDI_OBJECT_TYPE_DCE) _____ Modified: trunk/reactos/subsys/win32k/w32k.h --- trunk/reactos/subsys/win32k/w32k.h 2005-06-19 16:30:52 UTC (rev 16096) +++ trunk/reactos/subsys/win32k/w32k.h 2005-06-19 17:27:44 UTC (rev 16097) @@ -16,6 +16,7 @@ #include <ddk/ntddmou.h> #include <win32k/win32k.h> +#include <win32k/callback.h> #include <csrss/csrss.h> #include <internal/ntoskrnl.h> @@ -33,7 +34,6 @@ #include <windowsx.h> #include <rosrtl/string.h> -#include <user32/callback.h> #include <include/ssec.h> #include <include/accelerator.h>
19 years, 6 months
1
0
0
0
[navaraf] 16096: Remove duplicate headers.
by navaraf@svn.reactos.com
Remove duplicate headers. Deleted: trunk/reactos/include/nspapi.h Deleted: trunk/reactos/include/serviceinfo.h _____ Deleted: trunk/reactos/include/nspapi.h --- trunk/reactos/include/nspapi.h 2005-06-19 15:40:47 UTC (rev 16095) +++ trunk/reactos/include/nspapi.h 2005-06-19 16:30:52 UTC (rev 16096) @@ -1,91 +0,0 @@ -#ifndef _NSPAPI_H -#define _NSPAPI_H -#if __GNUC__ >=3 -#pragma GCC system_header -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -#define NS_ALL 0 - -#define NS_SAP 1 -#define NS_NDS 2 -#define NS_PEER_BROWSE 3 - -#define NS_TCPIP_LOCAL 10 -#define NS_TCPIP_HOSTS 11 -#define NS_DNS 12 -#define NS_NETBT 13 -#define NS_WINS 14 - -#define NS_NBP 20 - -#define NS_MS 30 -#define NS_STDA 31 -#define NS_NTDS 32 - -#define NS_X500 40 -#define NS_NIS 41 -#define NS_NISPLUS 42 - -#define NS_WRQ 50 - -#define SERVICE_REGISTER 1 -#define SERVICE_DEREGISTER 2 -#define SERVICE_FLUSH 3 -#define SERVICE_FLAG_HARD 0x00000002 - -#ifndef RC_INVOKED - -#if defined (_WINSOCK_H) || defined (_WINSOCK2_H) /* needed for LPSOCKADDR */ -#ifndef __CSADDR_T_DEFINED /* also in winsock2.h, but not in winsock.h */ -#define __CSADDR_T_DEFINED -typedef struct _SOCKET_ADDRESS { - LPSOCKADDR lpSockaddr; - INT iSockaddrLength; -} SOCKET_ADDRESS,*PSOCKET_ADDRESS,*LPSOCKET_ADDRESS; -typedef struct _CSADDR_INFO { - SOCKET_ADDRESS LocalAddr; - SOCKET_ADDRESS RemoteAddr; - INT iSocketType; - INT iProtocol; -} CSADDR_INFO,*PCSADDR_INFO,*LPCSADDR_INFO; -#endif -#endif - -#ifndef __BLOB_T_DEFINED /* also in wtypes.h and winsock2.h */ -#define __BLOB_T_DEFINED -typedef struct _BLOB { - ULONG cbSize; - BYTE *pBlobData; -} BLOB,*PBLOB,*LPBLOB; -#endif - -#include <serviceinfo.h> - -typedef void *LPSERVICE_ASYNC_INFO; -INT WINAPI SetServiceA(DWORD,DWORD,DWORD,LPSERVICE_INFOA,LPSERVICE_ASYNC_INFO,LPDWO RD); -INT WINAPI SetServiceW(DWORD,DWORD,DWORD,LPSERVICE_INFOW,LPSERVICE_ASYNC_INFO,LPDWO RD); -INT WINAPI GetAddressByNameA(DWORD,LPGUID,LPSTR,LPINT,DWORD,LPSERVICE_ASYNC_INFO,LP VOID,LPDWORD,LPSTR,LPDWORD); -INT WINAPI GetAddressByNameW(DWORD,LPGUID,LPWSTR,LPINT,DWORD,LPSERVICE_ASYNC_INFO,L PVOID,LPDWORD,LPWSTR,LPDWORD); - -#ifdef UNICODE -typedef SERVICE_INFOW SERVICE_INFO, *LPSERVICE_INFO; -#define _SERVICE_INFO SERVICE_INFOW -#define SetService SetServiceW -#define GetAddressByName GetAddressByNameW -#else -typedef SERVICE_INFOA SERVICE_INFO, *LPSERVICE_INFO; -#define _SERVICE_INFO SERVICE_INFOA -#define SetService SetServiceA -#define GetAddressByName GetAddressByNameA -#endif - -#endif /* RC_INVOKED */ - -#ifdef __cplusplus -} -#endif -#endif /* _NSPAPI_H */ _____ Deleted: trunk/reactos/include/serviceinfo.h --- trunk/reactos/include/serviceinfo.h 2005-06-19 15:40:47 UTC (rev 16095) +++ trunk/reactos/include/serviceinfo.h 2005-06-19 16:30:52 UTC (rev 16096) @@ -1,40 +0,0 @@ -#ifndef _SERVICE_INFO_H -#define _SERVICE_INFO_H - -typedef struct _SERVICE_ADDRESS { - DWORD dwAddressType; - DWORD dwAddressFlags; - DWORD dwAddressLength; - DWORD dwPrincipalLength; - BYTE *lpAddress; - BYTE *lpPrincipal; -} SERVICE_ADDRESS; -typedef struct _SERVICE_ADDRESSES { - DWORD dwAddressCount; - SERVICE_ADDRESS Addresses[1]; -} SERVICE_ADDRESSES, *PSERVICE_ADDRESSES, *LPSERVICE_ADDRESSES; -typedef struct _SERVICE_INFOA { - LPGUID lpServiceType; - LPSTR lpServiceName; - LPSTR lpComment; - LPSTR lpLocale; - DWORD dwDisplayHint; - DWORD dwVersion; - DWORD dwTime; - LPSTR lpMachineName; - LPSERVICE_ADDRESSES lpServiceAddress; - BLOB ServiceSpecificInfo; -} SERVICE_INFOA, *LPSERVICE_INFOA; -typedef struct _SERVICE_INFOW { - LPGUID lpServiceType; - LPWSTR lpServiceName; - LPWSTR lpComment; - LPWSTR lpLocale; - DWORD dwDisplayHint; - DWORD dwVersion; - DWORD dwTime; - LPWSTR lpMachineName; - LPSERVICE_ADDRESSES lpServiceAddress; - BLOB ServiceSpecificInfo; -} SERVICE_INFOW, *LPSERVICE_INFOW; -#endif/*SERVICE_INFO_H*/
19 years, 6 months
1
0
0
0
[navaraf] 16095: Better header redefiniton guards.
by navaraf@svn.reactos.com
Better header redefiniton guards. Modified: trunk/reactos/drivers/usb/cromwell/linux/linux_wrapper.h _____ Modified: trunk/reactos/drivers/usb/cromwell/linux/linux_wrapper.h --- trunk/reactos/drivers/usb/cromwell/linux/linux_wrapper.h 2005-06-19 15:27:10 UTC (rev 16094) +++ trunk/reactos/drivers/usb/cromwell/linux/linux_wrapper.h 2005-06-19 15:40:47 UTC (rev 16095) @@ -37,9 +37,18 @@ typedef int spinlock_t; typedef int atomic_t; #ifndef STANDALONE +#ifndef _MODE_T_ +#define _MODE_T_ typedef int mode_t; +#endif +#ifndef _PID_T_ +#define _PID_T_ typedef int pid_t; +#endif +#ifndef _SSIZE_T_ +#define _SSIZE_T_ typedef int ssize_t; +#endif #endif typedef int irqreturn_t;
19 years, 6 months
1
0
0
0
[navaraf] 16094: - Add definition of DRIVE_LAYOUT_INFORMATION_EX.
by navaraf@svn.reactos.com
- Add definition of DRIVE_LAYOUT_INFORMATION_EX. - Move CLS defintions from winddk.h to ntnls.h. - Move EVENT_TRACE_HEADER defintion from winddk.h to evntrace.h. Added: trunk/reactos/include/evntrace.h Modified: trunk/reactos/include/ntos.h Modified: trunk/reactos/ntoskrnl/include/ntoskrnl.h Modified: trunk/reactos/w32api/include/ddk/ntdddisk.h Added: trunk/reactos/w32api/include/ddk/ntnls.h Modified: trunk/reactos/w32api/include/ddk/winddk.h _____ Added: trunk/reactos/include/evntrace.h --- trunk/reactos/include/evntrace.h 2005-06-19 14:15:39 UTC (rev 16093) +++ trunk/reactos/include/evntrace.h 2005-06-19 15:27:10 UTC (rev 16094) @@ -0,0 +1,43 @@ +#ifndef ENVTRACE_H +#define ENVTRACE_H + +typedef struct _EVENT_TRACE_HEADER +{ + USHORT Size; + union { + USHORT FieldTypeFlags; + struct { + UCHAR HeaderType; + UCHAR MarkerFlags; + }; + }; + union { + ULONG Version; + struct { + UCHAR Type; + UCHAR Level; + USHORT Version; + } Class; + }; + ULONG ThreadId; + ULONG ProcessId; + LARGE_INTEGER TimeStamp; + union { + GUID Guid; + ULONGLONG GuidPtr; + }; + union { + struct { + ULONG ClientContext; + ULONG Flags; + }; + struct { + ULONG KernelTime; + ULONG UserTime; + }; + ULONG64 ProcessorTime; + }; +} EVENT_TRACE_HEADER, *PEVENT_TRACE_HEADER; + +#endif /* ENVTRACE_H */ + _____ Modified: trunk/reactos/include/ntos.h --- trunk/reactos/include/ntos.h 2005-06-19 14:15:39 UTC (rev 16093) +++ trunk/reactos/include/ntos.h 2005-06-19 15:27:10 UTC (rev 16094) @@ -10,6 +10,8 @@ #include <windows.h> #include <ddk/ntddk.h> #include <ddk/ntifs.h> +#include <ddk/ntnls.h> +#include <evntrace.h> #include "ntos/types.h" #include "ntos/cdrom.h" #include "ntos/console.h" @@ -51,6 +53,8 @@ #else /* Assume kernel mode */ #include <ddk/ntddk.h> #include <ddk/ntifs.h> +#include <ddk/ntnls.h> +#include <evntrace.h> #include "ntos/types.h" #include "ntos/cdrom.h" #include "ntos/console.h" _____ Modified: trunk/reactos/ntoskrnl/include/ntoskrnl.h --- trunk/reactos/ntoskrnl/include/ntoskrnl.h 2005-06-19 14:15:39 UTC (rev 16093) +++ trunk/reactos/ntoskrnl/include/ntoskrnl.h 2005-06-19 15:27:10 UTC (rev 16094) @@ -74,7 +74,8 @@ #include <napi/teb.h> #include <napi/win32.h> - +#ifndef TAG #define TAG(A, B, C, D) (ULONG)(((A)<<0) + ((B)<<8) + ((C)<<16) + ((D)<<24)) +#endif #endif /* INCLUDE_NTOSKRNL_H */ _____ Modified: trunk/reactos/w32api/include/ddk/ntdddisk.h --- trunk/reactos/w32api/include/ddk/ntdddisk.h 2005-06-19 14:15:39 UTC (rev 16093) +++ trunk/reactos/w32api/include/ddk/ntdddisk.h 2005-06-19 15:27:10 UTC (rev 16094) @@ -379,6 +379,16 @@ ULONG MaxPartitionCount; } DRIVE_LAYOUT_INFORMATION_GPT, *PDRIVE_LAYOUT_INFORMATION_GPT; +typedef struct _DRIVE_LAYOUT_INFORMATION_EX { + ULONG PartitionStyle; + ULONG PartitionCount; + union { + DRIVE_LAYOUT_INFORMATION_MBR Mbr; + DRIVE_LAYOUT_INFORMATION_GPT Gpt; + }; + PARTITION_INFORMATION_EX PartitionEntry[1]; +} DRIVE_LAYOUT_INFORMATION_EX, *PDRIVE_LAYOUT_INFORMATION_EX; + typedef struct _FORMAT_EX_PARAMETERS { MEDIA_TYPE MediaType; ULONG StartCylinderNumber; _____ Added: trunk/reactos/w32api/include/ddk/ntnls.h --- trunk/reactos/w32api/include/ddk/ntnls.h 2005-06-19 14:15:39 UTC (rev 16093) +++ trunk/reactos/w32api/include/ddk/ntnls.h 2005-06-19 15:27:10 UTC (rev 16094) @@ -0,0 +1,52 @@ +/* + * ntddmou.h + * + * Structures and definitions for NLS data types. + * + * This file is part of the w32api package. + * + * Contributors: + * Created by Alex Ionescu <alex(a)relsoft.net> + * + * THIS SOFTWARE IS NOT COPYRIGHTED + * + * This source code is offered for use in the public domain. You may + * use, modify or distribute it freely. + * + * This code is distributed in the hope that it will be useful but + * WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY + * DISCLAIMED. This includes but is not limited to warranties of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * + */ + +#ifndef __NTNLS_H +#define __NTNLS_H + +#define MAXIMUM_LEADBYTES 12 + +typedef struct _CPTABLEINFO +{ + USHORT CodePage; + USHORT MaximumCharacterSize; + USHORT DefaultChar; + USHORT UniDefaultChar; + USHORT TransDefaultChar; + USHORT TransUniDefaultChar; + USHORT DBCSCodePage; + UCHAR LeadByte[MAXIMUM_LEADBYTES]; + PUSHORT MultiByteTable; + PVOID WideCharTable; + PUSHORT DBCSRanges; + PUSHORT DBCSOffsets; +} CPTABLEINFO, *PCPTABLEINFO; + +typedef struct _NLSTABLEINFO +{ + CPTABLEINFO OemTableInfo; + CPTABLEINFO AnsiTableInfo; + PUSHORT UpperCaseTable; + PUSHORT LowerCaseTable; +} NLSTABLEINFO, *PNLSTABLEINFO; + +#endif /* __NTNLS_H */ _____ Modified: trunk/reactos/w32api/include/ddk/winddk.h --- trunk/reactos/w32api/include/ddk/winddk.h 2005-06-19 14:15:39 UTC (rev 16093) +++ trunk/reactos/w32api/include/ddk/winddk.h 2005-06-19 15:27:10 UTC (rev 16094) @@ -179,11 +179,6 @@ typedef struct _DEVICE_HANDLER_OBJECT *PDEVICE_HANDLER_OBJECT; typedef struct _BUS_HANDLER *PBUS_HANDLER; typedef struct _ADAPTER_OBJECT *PADAPTER_OBJECT; -typedef struct _DRIVE_LAYOUT_INFORMATION; -typedef struct _DRIVE_LAYOUT_INFORMATION_EX *PDRIVE_LAYOUT_INFORMATION_EX; -typedef struct _NAMED_PIPE_CREATE_PARAMETERS *PNAMED_PIPE_CREATE_PARAMETERS; -typedef struct _MAILSLOT_CREATE_PARAMETERS *PMAILSLOT_CREATE_PARAMETERS; -typedef struct _FILE_GET_QUOTA_INFORMATION *PFILE_GET_QUOTA_INFORMATION; /* Constants */ #define MAXIMUM_PROCESSORS 32 @@ -747,21 +742,21 @@ #define PNP_DEVICE_RESOURCE_REQUIREMENTS_CHANGED 0x00000010 #define PNP_DEVICE_NOT_DISABLEABLE 0x00000020 -typedef enum _PNP_VETO_TYPE +typedef enum _PNP_VETO_TYPE { - PNP_VetoTypeUnknown, - PNP_VetoLegacyDevice, - PNP_VetoPendingClose, - PNP_VetoWindowsApp, - PNP_VetoWindowsService, - PNP_VetoOutstandingOpen, - PNP_VetoDevice, - PNP_VetoDriver, - PNP_VetoIllegalDeviceRequest, - PNP_VetoInsufficientPower, - PNP_VetoNonDisableable, - PNP_VetoLegacyDriver, - PNP_VetoInsufficientRights + PNP_VetoTypeUnknown, + PNP_VetoLegacyDevice, + PNP_VetoPendingClose, + PNP_VetoWindowsApp, + PNP_VetoWindowsService, + PNP_VetoOutstandingOpen, + PNP_VetoDevice, + PNP_VetoDriver, + PNP_VetoIllegalDeviceRequest, + PNP_VetoInsufficientPower, + PNP_VetoNonDisableable, + PNP_VetoLegacyDriver, + PNP_VetoInsufficientRights } PNP_VETO_TYPE, *PPNP_VETO_TYPE; typedef struct _TARGET_DEVICE_CUSTOM_NOTIFICATION { @@ -847,46 +842,7 @@ (DDKAPI *PDEVICE_CHANGE_COMPLETE_CALLBACK)( IN PVOID Context); -/* WMI, should go in a WMI header... */ -typedef struct _EVENT_TRACE_HEADER -{ - USHORT Size; - union { - USHORT FieldTypeFlags; - struct { - UCHAR HeaderType; - UCHAR MarkerFlags; - }; - }; - union { - ULONG Version; - struct { - UCHAR Type; - UCHAR Level; - USHORT Version; - } Class; - }; - ULONG ThreadId; - ULONG ProcessId; - LARGE_INTEGER TimeStamp; - union { - GUID Guid; - ULONGLONG GuidPtr; - }; - union { - struct { - ULONG ClientContext; - ULONG Flags; - }; - struct { - ULONG KernelTime; - ULONG UserTime; - }; - ULONG64 ProcessorTime; - }; -} EVENT_TRACE_HEADER, *PEVENT_TRACE_HEADER; - /* ** System structures */ @@ -900,33 +856,6 @@ #define DUPLICATE_SAME_ATTRIBUTES 0x00000004 /* end winnt.h */ -/* Nls Info (ntnls.h) */ -#define MAXIMUM_LEADBYTES 12 - -typedef struct _CPTABLEINFO -{ - USHORT CodePage; - USHORT MaximumCharacterSize; - USHORT DefaultChar; - USHORT UniDefaultChar; - USHORT TransDefaultChar; - USHORT TransUniDefaultChar; - USHORT DBCSCodePage; - UCHAR LeadByte[MAXIMUM_LEADBYTES]; - PUSHORT MultiByteTable; - PVOID WideCharTable; - PUSHORT DBCSRanges; - PUSHORT DBCSOffsets; -} CPTABLEINFO, *PCPTABLEINFO; - -typedef struct _NLSTABLEINFO -{ - CPTABLEINFO OemTableInfo; - CPTABLEINFO AnsiTableInfo; - PUSHORT UpperCaseTable; - PUSHORT LowerCaseTable; -} NLSTABLEINFO, *PNLSTABLEINFO; - typedef struct _OBJECT_NAME_INFORMATION { UNICODE_STRING Name; } OBJECT_NAME_INFORMATION, *POBJECT_NAME_INFORMATION; @@ -3156,19 +3085,21 @@ USHORT ShareAccess; ULONG POINTER_ALIGNMENT EaLength; } Create; + /* FIXME: CreatePipe and CreateMailslot aren't defined in official + * DDK/IFS headers. */ struct { PIO_SECURITY_CONTEXT SecurityContext; ULONG Options; USHORT Reserved; USHORT ShareAccess; - PNAMED_PIPE_CREATE_PARAMETERS Parameters; + struct _NAMED_PIPE_CREATE_PARAMETERS *Parameters; } CreatePipe; struct { PIO_SECURITY_CONTEXT SecurityContext; ULONG Options; USHORT Reserved; USHORT ShareAccess; - PMAILSLOT_CREATE_PARAMETERS Parameters; + struct _MAILSLOT_CREATE_PARAMETERS *Parameters; } CreateMailslot; struct { ULONG Length; @@ -3263,7 +3194,7 @@ struct { ULONG Length; PSID StartSid; - PFILE_GET_QUOTA_INFORMATION SidList; + struct _FILE_GET_QUOTA_INFORMATION *SidList; ULONG SidListLength; } QueryQuota; struct {
19 years, 6 months
1
0
0
0
[hpoussin] 16093: Implement IRP_MN_QUERY_DEVICE_RELATIONS for USB hubs
by hpoussin@svn.reactos.com
Implement IRP_MN_QUERY_DEVICE_RELATIONS for USB hubs Implement IRP_MN_QUERY_ID for devices enumerated by USB hubs Modified: trunk/reactos/drivers/usb/cromwell/hub/fdo.c Modified: trunk/reactos/drivers/usb/cromwell/hub/pdo.c Modified: trunk/reactos/drivers/usb/cromwell/hub/usbhub.h _____ Modified: trunk/reactos/drivers/usb/cromwell/hub/fdo.c --- trunk/reactos/drivers/usb/cromwell/hub/fdo.c 2005-06-19 14:12:59 UTC (rev 16092) +++ trunk/reactos/drivers/usb/cromwell/hub/fdo.c 2005-06-19 14:15:39 UTC (rev 16093) @@ -10,8 +10,6 @@ #define NDEBUG #include "usbhub.h" -extern struct usb_driver hub_driver; - #define IO_METHOD_FROM_CTL_CODE(ctlCode) (ctlCode&0x00000003) static VOID @@ -47,6 +45,147 @@ } } +static NTSTATUS +UsbhubFdoQueryBusRelations( + IN PDEVICE_OBJECT DeviceObject, + OUT PDEVICE_RELATIONS* pDeviceRelations) +{ + PHUB_DEVICE_EXTENSION DeviceExtension; + PDEVICE_RELATIONS DeviceRelations; + PDEVICE_OBJECT Pdo; + PHUB_DEVICE_EXTENSION PdoExtension; + struct usb_device* dev; + ULONG i; + ULONG Children = 0; + ULONG NeededSize; + NTSTATUS Status; + CHAR Buffer[3][40]; + + DeviceExtension = (PHUB_DEVICE_EXTENSION)DeviceObject->DeviceExtension; + dev = DeviceExtension->dev; + + /* Create PDOs that are missing */ + for (i = 0; i < USB_MAXCHILDREN; i++) + { + if (dev->children[i] == NULL) + { + /* No child device at this place */ + continue; + } + Children++; + if (DeviceExtension->Children[i] != NULL) + { + /* PDO already exists */ + continue; + } + /* Need to create the PDO */ + Status = IoCreateDevice( + DeviceObject->DriverObject, + sizeof(HUB_DEVICE_EXTENSION), + NULL, /* Device name */ + FILE_DEVICE_CONTROLLER, + FILE_AUTOGENERATED_DEVICE_NAME, + FALSE, + &DeviceExtension->Children[i]); + if (!NT_SUCCESS(Status)) + { + DPRINT("Usbhub: IoCreateDevice() failed with status 0x%08lx\n", Status); + return Status; + } + + Pdo = DeviceExtension->Children[i]; + Pdo->Flags |= DO_BUS_ENUMERATED_DEVICE; + + PdoExtension = Pdo->DeviceExtension; + RtlZeroMemory(PdoExtension, sizeof(HUB_DEVICE_EXTENSION)); + + PdoExtension->IsFDO = FALSE; + PdoExtension->dev = dev->children[i]; + + RtlInitUnicodeString( + &PdoExtension->DeviceDescription, + L"USB device"); /* FIXME */ + + sprintf(Buffer[0], "%lu", i + 1); + Status = UsbhubInitMultiSzString( + &PdoExtension->InstanceId, + Buffer[0], NULL); + if (!NT_SUCCESS(Status)) + goto ByeBye; + + /* FIXME: what if it is a multiple-interface usb device? */ + sprintf(Buffer[0], "USB\\Vid_%04x&Pid_%04x&Rev_%04x", + PdoExtension->dev->descriptor.idVendor, + PdoExtension->dev->descriptor.idProduct, + 0 /* FIXME: need to put the revision */); + sprintf(Buffer[1], "USB\\Vid_%04x&Pid_%04x", + PdoExtension->dev->descriptor.idVendor, + PdoExtension->dev->descriptor.idProduct); + Status = UsbhubInitMultiSzString( + &PdoExtension->HardwareIds, + Buffer[0], Buffer[1], NULL); + if (!NT_SUCCESS(Status)) + goto ByeBye; + + Status = UsbhubInitMultiSzString( + &PdoExtension->DeviceId, + Buffer[1], NULL); + if (!NT_SUCCESS(Status)) + goto ByeBye; + + /* FIXME: what if it is a multiple-interface usb device? */ + sprintf(Buffer[0], "USB\\Class_%02x&SubClass_%02x&Prot_%02x", + PdoExtension->dev->descriptor.bDeviceClass, + PdoExtension->dev->descriptor.bDeviceSubClass, + PdoExtension->dev->descriptor.bDeviceProtocol); + sprintf(Buffer[1], "USB\\Class_%02x&SubClass_%02x", + PdoExtension->dev->descriptor.bDeviceClass, + PdoExtension->dev->descriptor.bDeviceSubClass); + sprintf(Buffer[2], "USB\\Class_%02x", + PdoExtension->dev->descriptor.bDeviceClass); + Status = UsbhubInitMultiSzString( + &PdoExtension->CompatibleIds, + Buffer[0], Buffer[1], Buffer[2], NULL); + if (!NT_SUCCESS(Status)) + goto ByeBye; + + Pdo->Flags &= ~DO_DEVICE_INITIALIZING; + } + + /* Fill returned structure */ + NeededSize = sizeof(DEVICE_RELATIONS); + if (Children > 1) + NeededSize += (Children - 1) * sizeof(PDEVICE_OBJECT); + DeviceRelations = (PDEVICE_RELATIONS)ExAllocatePool( + PagedPool, + NeededSize); + if (!DeviceRelations) + return STATUS_INSUFFICIENT_RESOURCES; + DeviceRelations->Count = Children; + Children = 0; + for (i = 0; i < USB_MAXCHILDREN; i++) + { + if (DeviceExtension->Children[i]) + { + ObReferenceObject(DeviceExtension->Children[i]); + DeviceRelations->Objects[Children++] = DeviceExtension->Children[i]; + } + } + ASSERT(Children == DeviceRelations->Count); + + *pDeviceRelations = DeviceRelations; + return STATUS_SUCCESS; + +ByeBye: + RtlFreeUnicodeString(&PdoExtension->DeviceDescription); + RtlFreeUnicodeString(&PdoExtension->DeviceId); + RtlFreeUnicodeString(&PdoExtension->InstanceId); + RtlFreeUnicodeString(&PdoExtension->HardwareIds); + RtlFreeUnicodeString(&PdoExtension->CompatibleIds); + IoDeleteDevice(Pdo); + return Status; +} + NTSTATUS STDCALL UsbhubPnpFdo( IN PDEVICE_OBJECT DeviceObject, @@ -62,35 +201,37 @@ switch (MinorFunction) { - case IRP_MN_START_DEVICE: + case IRP_MN_START_DEVICE: /* 0x0 */ { DPRINT("Usbhub: IRP_MJ_PNP / IRP_MN_START_DEVICE\n"); Status = ForwardIrpAndWait(DeviceObject, Irp); - //if (NT_SUCCESS(Status) && NT_SUCCESS(Irp->IoStatus.Status)) - // Status = OHCD_PnPStartDevice(DeviceObject, Irp); break; } - case IRP_MN_REMOVE_DEVICE: - //case IRP_MN_QUERY_REMOVE_DEVICE: - //case IRP_MN_CANCEL_REMOVE_DEVICE: - case IRP_MN_SURPRISE_REMOVAL: - - case IRP_MN_STOP_DEVICE: + case IRP_MN_QUERY_DEVICE_RELATIONS: /* (optional) 0x7 */ { - DPRINT("Usbhub: IRP_MJ_PNP / IRP_MN_STOP_DEVICE\n"); - Status = ForwardIrpAndWait(DeviceObject, Irp); - if (NT_SUCCESS(Status) && NT_SUCCESS(Irp->IoStatus.Status)) - Status = STATUS_SUCCESS; - IoDeleteDevice(DeviceObject); // just delete device for now + switch (IrpSp->Parameters.QueryDeviceRelations.Type) + { + case BusRelations: + { + PDEVICE_RELATIONS DeviceRelations; + DPRINT("Usbhub: IRP_MJ_PNP / IRP_MN_QUERY_DEVICE_RELATIONS / BusRelations\n"); + Status = UsbhubFdoQueryBusRelations(DeviceObject, &DeviceRelations); + Information = (ULONG_PTR)DeviceRelations; + break; + } + case RemovalRelations: + { + DPRINT1("Usbhub: IRP_MJ_PNP / IRP_MN_QUERY_DEVICE_RELATIONS / RemovalRelations\n"); + return ForwardIrpAndForget(DeviceObject, Irp); + } + default: + DPRINT1("Usbhub: IRP_MJ_PNP / IRP_MN_QUERY_DEVICE_RELATIONS / Unknown type 0x%lx\n", + IrpSp->Parameters.QueryDeviceRelations.Type); + return ForwardIrpAndForget(DeviceObject, Irp); + } break; } - case IRP_MN_QUERY_STOP_DEVICE: - case IRP_MN_CANCEL_STOP_DEVICE: - { - Status = STATUS_SUCCESS; - break; - } default: { @@ -104,11 +245,6 @@ return Status; } -static inline struct device *hubdev (struct usb_device *dev) -{ - return &dev->actconfig->interface [0].dev; -} - NTSTATUS UsbhubDeviceControlFdo( IN PDEVICE_OBJECT DeviceObject, @@ -147,7 +283,7 @@ NodeInformation->NodeType = UsbHub; RtlCopyMemory( &NodeInformation->u.HubInformation.HubDescriptor, - ((struct usb_hub *)usb_get_intfdata(to_usb_interface(hubdev(dev))))->descriptor, + ((struct usb_hub *)usb_get_intfdata(to_usb_interface(&dev->actconfig->interface[0].dev))) ->descriptor, sizeof(USB_HUB_DESCRIPTOR)); NodeInformation->u.HubInformation.HubIsBusPowered = TRUE; /* FIXME */ Information = sizeof(USB_NODE_INFORMATION); @@ -189,17 +325,24 @@ ConnectionInformation = (PUSB_NODE_CONNECTION_INFORMATION)BufferOut; DPRINT1("Usbhub: IOCTL_USB_GET_NODE_CONNECTION_INFORMATION partially implemented\n"); dev = ((PHUB_DEVICE_EXTENSION)DeviceObject->DeviceExtension)->dev; - ConnectionInformation->ConnectionIndex = 0; /* FIXME */ + dev = dev->children[ConnectionInformation->ConnectionIndex = 0]; + if (dev == NULL) + { + /* No device connected to this port */ + RtlZeroMemory(ConnectionInformation, sizeof(USB_NODE_CONNECTION_INFORMATION)); + Status = STATUS_SUCCESS; + break; + } RtlCopyMemory( &ConnectionInformation->DeviceDescriptor, &dev->descriptor, sizeof(USB_DEVICE_DESCRIPTOR)); ConnectionInformation->CurrentConfigurationValue = 0; /* FIXME */ - ConnectionInformation->LowSpeed = TRUE; /* FIXME */ - ConnectionInformation->DeviceIsHub = TRUE; - RtlZeroMemory(&ConnectionInformation->DeviceAddress, sizeof(ConnectionInformation->DeviceAddress)); /* FIXME */ + ConnectionInformation->LowSpeed = dev->speed == USB_SPEED_LOW || dev->speed == USB_SPEED_FULL; + ConnectionInformation->DeviceIsHub = dev->descriptor.bDeviceClass == USB_CLASS_HUB; + ConnectionInformation->DeviceAddress = dev->devnum; RtlZeroMemory(&ConnectionInformation->NumberOfOpenPipes, sizeof(ConnectionInformation->NumberOfOpenPipes)); /* FIXME */ - RtlZeroMemory(&ConnectionInformation->ConnectionStatus, sizeof(ConnectionInformation->ConnectionStatus)); /* FIXME */ + ConnectionInformation->ConnectionStatus = DeviceConnected; RtlZeroMemory(&ConnectionInformation->PipeList, sizeof(ConnectionInformation->PipeList)); /* FIXME */ /*for (i = 0; i < 32; i++) { _____ Modified: trunk/reactos/drivers/usb/cromwell/hub/pdo.c --- trunk/reactos/drivers/usb/cromwell/hub/pdo.c 2005-06-19 14:12:59 UTC (rev 16092) +++ trunk/reactos/drivers/usb/cromwell/hub/pdo.c 2005-06-19 14:15:39 UTC (rev 16093) @@ -8,10 +8,9 @@ */ //#define NDEBUG +#include <stdio.h> #include "usbhub.h" -extern struct usb_driver hub_driver; - #define IO_METHOD_FROM_CTL_CODE(ctlCode) (ctlCode&0x00000003) NTSTATUS @@ -44,6 +43,59 @@ return Status; } +static NTSTATUS +UsbhubPdoQueryId( + IN PDEVICE_OBJECT DeviceObject, + IN PIRP Irp, + OUT ULONG_PTR* Information) +{ + PHUB_DEVICE_EXTENSION DeviceExtension; + ULONG IdType; + PUNICODE_STRING SourceString; + UNICODE_STRING String; + NTSTATUS Status; + + IdType = IoGetCurrentIrpStackLocation(Irp)->Parameters.QueryId.IdType; + DeviceExtension = (PHUB_DEVICE_EXTENSION)DeviceObject->DeviceExtension; + RtlInitUnicodeString(&String, NULL); + + switch (IdType) + { + case BusQueryDeviceID: + { + DPRINT("Usbhub: IRP_MJ_PNP / IRP_MN_QUERY_ID / BusQueryDeviceID\n"); + SourceString = &DeviceExtension->DeviceId; + break; + } + case BusQueryHardwareIDs: + { + DPRINT("Usbhub: IRP_MJ_PNP / IRP_MN_QUERY_ID / BusQueryHardwareIDs\n"); + SourceString = &DeviceExtension->HardwareIds; + break; + } + case BusQueryCompatibleIDs: + DPRINT("Usbhub: IRP_MJ_PNP / IRP_MN_QUERY_ID / BusQueryCompatibleIDs\n"); + SourceString = &DeviceExtension->CompatibleIds; + break; + case BusQueryInstanceID: + { + DPRINT("Usbhub: IRP_MJ_PNP / IRP_MN_QUERY_ID / BusQueryInstanceID\n"); + SourceString = &DeviceExtension->InstanceId; + break; + } + default: + DPRINT1("Usbhub: IRP_MJ_PNP / IRP_MN_QUERY_ID / unknown query id type 0x%lx\n", IdType); + return STATUS_NOT_SUPPORTED; + } + + Status = UsbhubDuplicateUnicodeString( + &String, + SourceString, + PagedPool); + *Information = (ULONG_PTR)String.Buffer; + return Status; +} + NTSTATUS STDCALL UsbhubPnpPdo( IN PDEVICE_OBJECT DeviceObject, @@ -59,6 +111,11 @@ switch (MinorFunction) { + case IRP_MN_QUERY_ID: /* 0x13 */ + { + Status = UsbhubPdoQueryId(DeviceObject, Irp, &Information); + break; + } default: { /* We can't forward request to the lower driver, because _____ Modified: trunk/reactos/drivers/usb/cromwell/hub/usbhub.h --- trunk/reactos/drivers/usb/cromwell/hub/usbhub.h 2005-06-19 14:12:59 UTC (rev 16092) +++ trunk/reactos/drivers/usb/cromwell/hub/usbhub.h 2005-06-19 14:15:39 UTC (rev 16093) @@ -19,6 +19,15 @@ BOOLEAN IsFDO; struct usb_device* dev; PDEVICE_OBJECT LowerDevice; + + PDEVICE_OBJECT Children[USB_MAXCHILDREN]; + + /* Fields valid only when IsFDO == FALSE */ + UNICODE_STRING DeviceDescription; // REG_SZ + UNICODE_STRING DeviceId; // REG_SZ + UNICODE_STRING InstanceId; // REG_SZ + UNICODE_STRING HardwareIds; // REG_MULTI_SZ + UNICODE_STRING CompatibleIds; // REG_MULTI_SZ } HUB_DEVICE_EXTENSION, *PHUB_DEVICE_EXTENSION; /* createclose.c */
19 years, 6 months
1
0
0
0
[greatlrd] 16092: revert my lattes change some part of head did break
by greatlrd@svn.reactos.com
revert my lattes change some part of head did break sorry all. Modified: trunk/reactos/include/ddk/ddrawi.h _____ Modified: trunk/reactos/include/ddk/ddrawi.h --- trunk/reactos/include/ddk/ddrawi.h 2005-06-19 12:41:22 UTC (rev 16091) +++ trunk/reactos/include/ddk/ddrawi.h 2005-06-19 14:12:59 UTC (rev 16092) @@ -1325,83 +1325,7 @@ } DDHAL_WAITFORVERTICALBLANKDATA; -/********************************************************************** *********/ -/* DdGetDriverInfo need also _DDRAWI_DIRECTDRAW_GBL for ULONG_PTR dwContext */ -/********************************************************************** *********/ -typedef struct _DDRAWI_DIRECTDRAW_GBL -{ - DWORD dwRefCnt; - DWORD dwFlags; - FLATPTR fpPrimaryOrig; - DDCORECAPS ddCaps; - DWORD dwInternal1; - DWORD dwUnused1[9]; - LPDDHAL_CALLBACKS lpDDCBtmp; - LPDDRAWI_DDRAWSURFACE_INT dsList; - LPDDRAWI_DDRAWPALETTE_INT palList; - LPDDRAWI_DDRAWCLIPPER_INT clipperList; - LPDDRAWI_DIRECTDRAW_GBL lp16DD; - DWORD dwMaxOverlays; - DWORD dwCurrOverlays; - DWORD dwMonitorFrequency; - DDCORECAPS ddHELCaps; - DWORD dwUnused2[50]; - DDCOLORKEY ddckCKDestOverlay; - DDCOLORKEY ddckCKSrcOverlay; - VIDMEMINFO vmiData; - LPVOID lpDriverHandle; - LPDDRAWI_DIRECTDRAW_LCL lpExclusiveOwner; - DWORD dwModeIndex; - DWORD dwModeIndexOrig; - DWORD dwNumFourCC; - DWORD FAR *lpdwFourCC; - DWORD dwNumModes; - LPDDHALMODEINFO lpModeInfo; - PROCESS_LIST plProcessList; - DWORD dwSurfaceLockCount; - DWORD dwAliasedLockCnt; - ULONG_PTR dwReserved3; - ULONG_PTR hDD; - char cObsolete[12]; - DWORD dwReserved1; - DWORD dwReserved2; - DBLNODE dbnOverlayRoot; - volatile LPWORD lpwPDeviceFlags; - DWORD dwPDevice; - DWORD dwWin16LockCnt; - DWORD dwUnused3; - DWORD hInstance; - DWORD dwEvent16; - DWORD dwSaveNumModes; - ULONG_PTR lpD3DGlobalDriverData; - ULONG_PTR lpD3DHALCallbacks; - DDCORECAPS ddBothCaps; - LPDDVIDEOPORTCAPS lpDDVideoPortCaps; - LPDDRAWI_DDVIDEOPORT_INT dvpList; - ULONG_PTR lpD3DHALCallbacks2; - RECT rectDevice; - DWORD cMonitors; - LPVOID gpbmiSrc; - LPVOID gpbmiDest; - LPHEAPALIASINFO phaiHeapAliases; - ULONG_PTR hKernelHandle; - ULONG_PTR pfnNotifyProc; - LPDDKERNELCAPS lpDDKernelCaps; - LPDDNONLOCALVIDMEMCAPS lpddNLVCaps; - LPDDNONLOCALVIDMEMCAPS lpddNLVHELCaps; - LPDDNONLOCALVIDMEMCAPS lpddNLVBothCaps; - ULONG_PTR lpD3DExtendedCaps; - DWORD dwDOSBoxEvent; - RECT rectDesktop; - char cDriverName[MAX_DRIVER_NAME]; - ULONG_PTR lpD3DHALCallbacks3; - DWORD dwNumZPixelFormats; - LPDDPIXELFORMAT lpZPixelFormats; - LPDDRAWI_DDMOTIONCOMP_INT mcList; - DWORD hDDVxd; - DDSCAPSEX ddsCapsMore; -} DDRAWI_DIRECTDRAW_GBL; #ifdef __cplusplus
19 years, 6 months
1
0
0
0
[chorns] 16091: Count only scheduled time when running performance tests
by chorns@svn.reactos.com
Count only scheduled time when running performance tests Modified: trunk/reactos/regtests/regtests/regtests.c Modified: trunk/reactos/regtests/regtests/regtests.def Modified: trunk/reactos/regtests/shared/regtests.c Modified: trunk/reactos/regtests/shared/regtests.h Modified: trunk/reactos/subsys/win32k/tests/stubs.xml Modified: trunk/reactos/subsys/win32k/tests/tests/DIB_24BPP_ColorFill-performance. c Modified: trunk/reactos/tools/rbuild/testsupportcode.cpp _____ Modified: trunk/reactos/regtests/regtests/regtests.c --- trunk/reactos/regtests/regtests/regtests.c 2005-06-19 12:14:31 UTC (rev 16090) +++ trunk/reactos/regtests/regtests/regtests.c 2005-06-19 12:41:22 UTC (rev 16091) @@ -98,3 +98,27 @@ { return GetCurrentThread(); } + +BOOL STDCALL +_GetThreadContext(HANDLE hThread, LPCONTEXT lpContext) +{ + return GetThreadContext(hThread, lpContext); +} + +DWORD STDCALL +_SuspendThread(HANDLE hThread) +{ + return SuspendThread(hThread); +} + +DWORD STDCALL +_ResumeThread(HANDLE hThread) +{ + return ResumeThread(hThread); +} + +VOID STDCALL +_Sleep(DWORD dwMilliseconds) +{ + return Sleep(dwMilliseconds); +} _____ Modified: trunk/reactos/regtests/regtests/regtests.def --- trunk/reactos/regtests/regtests/regtests.def 2005-06-19 12:14:31 UTC (rev 16090) +++ trunk/reactos/regtests/regtests/regtests.def 2005-06-19 12:41:22 UTC (rev 16091) @@ -14,3 +14,7 @@ _SetThreadPriority@8 _GetCurrentProcess@0 _GetCurrentThread@0 +_GetThreadContext@8 +_SuspendThread@4 +_ResumeThread@4 +_Sleep@4 _____ Modified: trunk/reactos/regtests/shared/regtests.c --- trunk/reactos/regtests/shared/regtests.c 2005-06-19 12:14:31 UTC (rev 16090) +++ trunk/reactos/regtests/shared/regtests.c 2005-06-19 12:41:22 UTC (rev 16091) @@ -24,6 +24,9 @@ TestOutputRoutine OutputRoutine; _PTEST Test; LPSTR TestName; + DWORD Result; + char Buffer[5000]; + DWORD Time; } PERFORM_TEST_ARGS; int _Result; @@ -38,13 +41,11 @@ } char* -FormatExecutionTime(char *buffer, LPFILETIME time) +FormatExecutionTime(char *buffer, ULONG milliseconds) { - ULONG milliseconds = time->dwLowDateTime / 10000; - sprintf(buffer, - "%ldms", - milliseconds); + "%ldms", + milliseconds); return buffer; } @@ -52,58 +53,150 @@ PerformTest(PVOID _arg) { PERFORM_TEST_ARGS *Args = (PERFORM_TEST_ARGS *)_arg; - TestOutputRoutine OutputRoutine = Args->OutputRoutine; _PTEST Test = Args->Test; - LPSTR TestName = Args->TestName; - HANDLE hThread; - FILETIME time; - FILETIME ExecutionTime; - char OutputBuffer[5000]; - char Buffer[5000]; - char Format[100]; - hThread = _GetCurrentThread(); - _SetThreadPriority(hThread, THREAD_PRIORITY_IDLE); + _SetThreadPriority(_GetCurrentThread(), THREAD_PRIORITY_IDLE); - memset(Buffer, 0, sizeof(Buffer)); - + memset(Args->Buffer, 0, sizeof(Args->Buffer)); + _SEH_TRY { _Result = TS_OK; - _Buffer = Buffer; + _Buffer = Args->Buffer; (Test->Routine)(TESTCMD_RUN); + Args->Result = _Result; } _SEH_HANDLE { - _Result = TS_FAILED; - sprintf(Buffer, "due to exception 0x%lx", _SEH_GetExceptionCode()); + Args->Result = TS_FAILED; + sprintf(Args->Buffer, "due to exception 0x%lx", _SEH_GetExceptionCode()); } _SEH_END; + return 1; +} - if (_Result == TS_OK) - { - if (!_GetThreadTimes(hThread, - &time, - &time, - &time, - &ExecutionTime)) +BOOL +IsContextChanged(LPCONTEXT context1, LPCONTEXT context2) +{ + return memcmp(context1, context2, sizeof(CONTEXT)) != 0; +} + +VOID +ControlNormalTest(HANDLE hThread, + PERFORM_TEST_ARGS *Args, + DWORD TimeOut) +{ + FILETIME time; + FILETIME executionTime; + DWORD status; + + status = _WaitForSingleObject(hThread, TimeOut); + if (status == WAIT_TIMEOUT) + { + _TerminateThread(hThread, 0); + Args->Result = TS_TIMEDOUT; + } + status = _GetThreadTimes(hThread, + &time, + &time, + &time, + &executionTime); + Args->Time = executionTime.dwLowDateTime / 10000; +} + +VOID +ControlPerformanceTest(HANDLE hThread, + PERFORM_TEST_ARGS *Args, + DWORD TimeOut) +{ + DWORD status; + CONTEXT lastContext; + CONTEXT currentContext; + + ZeroMemory(&lastContext, sizeof(CONTEXT)); + lastContext.ContextFlags = CONTEXT_FULL; + ZeroMemory(¤tContext, sizeof(CONTEXT)); + currentContext.ContextFlags = CONTEXT_FULL; + + do { + _Sleep(1); + + if (_SuspendThread(hThread) == -1) + break; + + if (_GetThreadContext(hThread, ¤tContext) == 0) + break; + + if (IsContextChanged(¤tContext, &lastContext)) + Args->Time++; + + if (_ResumeThread(hThread) == -1) + break; + + if (Args->Time >= TimeOut) { - ExecutionTime.dwLowDateTime = 0; - ExecutionTime.dwHighDateTime = 0; + _TerminateThread(hThread, 0); + Args->Result = TS_TIMEDOUT; + break; } + + status = _WaitForSingleObject(hThread, 0); + if (status == WAIT_OBJECT_0 || status == WAIT_FAILED) + break; + + lastContext = currentContext; + } while (TRUE); +} + +VOID +DisplayResult(PERFORM_TEST_ARGS* Args, + LPSTR OutputBuffer) +{ + char Buffer[5000]; + char Format[100]; + + if (Args->Result == TS_OK) + { sprintf(OutputBuffer, "[%s] Success [%s]\n", - TestName, + Args->TestName, FormatExecutionTime(Format, - &ExecutionTime)); + Args->Time)); } + else if (Args->Result == TS_TIMEDOUT) + { + sprintf(OutputBuffer, + "[%s] Timed out [%s]\n", + Args->TestName, + FormatExecutionTime(Format, + Args->Time)); + } else - sprintf(OutputBuffer, "[%s] Failed (%s)\n", TestName, Buffer); + sprintf(OutputBuffer, "[%s] Failed (%s)\n", Args->TestName, Buffer); - if (OutputRoutine != NULL) - (*OutputRoutine)(OutputBuffer); + if (Args->OutputRoutine != NULL) + (*Args->OutputRoutine)(OutputBuffer); else - DbgPrint(OutputBuffer); - return 1; + DbgPrint(OutputBuffer); } VOID +ControlTest(HANDLE hThread, + PERFORM_TEST_ARGS *Args, + DWORD TestType, + DWORD TimeOut) +{ + switch (TestType) + { + case TT_NORMAL: + ControlNormalTest(hThread, Args, TimeOut); + break; + case TT_PERFORMANCE: + ControlPerformanceTest(hThread, Args, TimeOut); + break; + default: + printf("Unknown test type %ld\n", TestType); + break; + } +} + +VOID PerformTests(TestOutputRoutine OutputRoutine, LPSTR TestName) { PLIST_ENTRY CurrentEntry; @@ -113,11 +206,13 @@ HANDLE hThread; char OutputBuffer[1024]; char Name[200]; + DWORD TestType; DWORD TimeOut; Args.OutputRoutine = OutputRoutine; Args.TestName = Name; - + Args.Time = 0; + CurrentEntry = AllTests.Flink; for (; CurrentEntry != &AllTests; CurrentEntry = NextEntry) { @@ -141,40 +236,34 @@ if ((TestName != NULL) && (_stricmp(Name, TestName) != 0)) continue; + TestType = TT_NORMAL; + _Result = TS_OK; + _Buffer = (char *)&TestType; + (Current->Routine)(TESTCMD_TESTTYPE); + if (_Result != TS_OK) + TestType = TT_NORMAL; + /* Get timeout for test */ TimeOut = 0; _Result = TS_OK; _Buffer = (char *)&TimeOut; (Current->Routine)(TESTCMD_TIMEOUT); if (_Result != TS_OK || TimeOut == INFINITE) - TimeOut = 5000; + TimeOut = 5000; - /* Run test in thread */ + /* Run test in a separate thread */ hThread = _CreateThread(NULL, 0, PerformTest, (PVOID)&Args, 0, NULL); if (hThread == NULL) - sprintf(OutputBuffer, - "[%s] Failed (CreateThread() failed: %d)\n", - Name, (unsigned int)_GetLastError()); - else if (_WaitForSingleObject(hThread, TimeOut) == WAIT_TIMEOUT) { - if (!_TerminateThread(hThread, 0)) - sprintf(OutputBuffer, - "[%s] Failed (timed out after %dms; TerminateThread() failed: %d)\n", - Name, (int)TimeOut, (unsigned int)_GetLastError()); - else - sprintf(OutputBuffer, "[%s] Failed (timed out after %dms)\n", Name, (int)TimeOut); - _CloseHandle(hThread); + printf("[%s] Failed (CreateThread() failed: %ld)\n", + Name, + _GetLastError()); + Args.Result = TS_FAILED; } else - { - _CloseHandle(hThread); - continue; - } + ControlTest(hThread, &Args, TestType, TimeOut); - if (OutputRoutine != NULL) - (*OutputRoutine)(OutputBuffer); - else - DbgPrint(OutputBuffer); + DisplayResult(&Args, OutputBuffer); } } _____ Modified: trunk/reactos/regtests/shared/regtests.h --- trunk/reactos/regtests/shared/regtests.h 2005-06-19 12:14:31 UTC (rev 16090) +++ trunk/reactos/regtests/shared/regtests.h 2005-06-19 12:41:22 UTC (rev 16091) @@ -16,10 +16,16 @@ /* Valid values for Command parameter of TestRoutine */ #define TESTCMD_RUN 0 /* Buffer contains information about what failed */ -#define TESTCMD_TESTNAME 1 /* Buffer contains description of test */ -#define TESTCMD_TIMEOUT 2 /* Buffer contains timeout for test (DWORD, default is 5000 ms) */ +#define TESTCMD_TESTTYPE 1 /* Buffer contains type of test */ +#define TESTCMD_TESTNAME 2 /* Buffer contains description of test */ +#define TESTCMD_TIMEOUT 3 /* Buffer contains timeout for test (DWORD, default is 5000 ms) */ +/* Test types */ +#define TT_NORMAL 0 +#define TT_PERFORMANCE 1 + /* Valid values for return values of TestRoutine */ +#define TS_TIMEDOUT -2 #define TS_EXCEPTION -1 #define TS_OK 0 #define TS_FAILED 1 @@ -28,7 +34,7 @@ extern char *_Buffer; /* Macros to simplify tests */ -#define _DispatcherTimeout(FunctionName, TestName, TimeOut) \ +#define _DispatcherTypeTimeout(FunctionName, TestName, TestType, TimeOut) \ void \ FunctionName(int Command) \ { \ @@ -37,6 +43,9 @@ case TESTCMD_RUN: \ RunTest(); \ break; \ + case TESTCMD_TESTTYPE: \ + *(PDWORD)_Buffer = (DWORD)TestType; \ + break; \ case TESTCMD_TESTNAME: \ strcpy(_Buffer, TestName); \ break; \ @@ -49,8 +58,15 @@ } \ } -#define _Dispatcher(FunctionName, TestName) _DispatcherTimeout(FunctionName, TestName, 5000) +#define _DispatcherTimeout(FunctionName, TestName, TimeOut) \ + _DispatcherTypeTimeout(FunctionName, TestName, TT_NORMAL, TimeOut) +#define _DispatcherType(FunctionName, TestName, TestType) \ + _DispatcherTypeTimeout(FunctionName, TestName, TestType, 5000) + +#define _Dispatcher(FunctionName, TestName) \ + _DispatcherTimeout(FunctionName, TestName, 5000) + static inline void AppendAssertion(char *message) { @@ -211,7 +227,19 @@ HANDLE STDCALL _GetCurrentThread(); +BOOL STDCALL +_GetThreadContext(HANDLE hThread, LPCONTEXT lpContext); +DWORD STDCALL +_SuspendThread(HANDLE hThread); + +DWORD STDCALL +_ResumeThread(HANDLE hThread); + +VOID STDCALL +_Sleep(DWORD dwMilliseconds); + + static inline PCHAR FrameworkGetExportedFunctionNameInternal(_PAPI_DESCRIPTION ApiDescription) { _____ Modified: trunk/reactos/subsys/win32k/tests/stubs.xml --- trunk/reactos/subsys/win32k/tests/stubs.xml 2005-06-19 12:14:31 UTC (rev 16090) +++ trunk/reactos/subsys/win32k/tests/stubs.xml 2005-06-19 12:41:22 UTC (rev 16091) @@ -136,6 +136,8 @@ <symbol>ObReferenceObjectByName@32</symbol> <symbol>HalQueryDisplayOwnership@0</symbol> <symbol>IoDeviceObjectType</symbol> + <symbol>@KfReleaseSpinLock@8</symbol> + <symbol>@KfAcquireSpinLock@4</symbol> </component> <component name="freetype.dll"> <symbol>FT_Init_FreeType</symbol> _____ Modified: trunk/reactos/subsys/win32k/tests/tests/DIB_24BPP_ColorFill-performance. c --- trunk/reactos/subsys/win32k/tests/tests/DIB_24BPP_ColorFill-performance. c 2005-06-19 12:14:31 UTC (rev 16090) +++ trunk/reactos/subsys/win32k/tests/tests/DIB_24BPP_ColorFill-performance. c 2005-06-19 12:41:22 UTC (rev 16091) @@ -31,7 +31,7 @@ UINT i; SetupSurface(&surface, &rect); - for (i = 0; i < 1000; i++) + for (i = 0; i < 10000; i++) { BOOLEAN success = DIB_24BPP_ColorFill(&surface, &rect, color); _AssertTrue(success); @@ -41,4 +41,4 @@ CleanupSurface(&surface); } -_Dispatcher(Dib_24bpp_colorfill_performanceTest, "DIB_24BPP_ColorFill performance") +_DispatcherType(Dib_24bpp_colorfill_performanceTest, "DIB_24BPP_ColorFill performance", TT_PERFORMANCE) _____ Modified: trunk/reactos/tools/rbuild/testsupportcode.cpp --- trunk/reactos/tools/rbuild/testsupportcode.cpp 2005-06-19 12:14:31 UTC (rev 16090) +++ trunk/reactos/tools/rbuild/testsupportcode.cpp 2005-06-19 12:41:22 UTC (rev 16091) @@ -364,8 +364,9 @@ s = s + sprintf ( s, " LPSTR lpszCmdParam,\n" ); s = s + sprintf ( s, " int nCmdShow)\n" ); s = s + sprintf ( s, "{\n" ); - s = s + sprintf ( s, " _SetPriorityClass(_GetCurrentProcess(), IDLE_PRIORITY_CLASS);\n" ); - s = s + sprintf ( s, " InitializeTests();\n" ); + s = s + sprintf ( s, " _SetPriorityClass(_GetCurrentProcess(), HIGH_PRIORITY_CLASS);\n" ); + s = s + sprintf ( s, " _SetThreadPriority(_GetCurrentThread(), THREAD_PRIORITY_TIME_CRITICAL);\n" ); + s = s + sprintf ( s, " InitializeTests();\n" ); s = s + sprintf ( s, " RegisterTests();\n" ); s = s + sprintf ( s, " SetupOnce();\n" ); s = s + sprintf ( s, " PerformTests(ConsoleWrite, NULL);\n" );
19 years, 6 months
1
0
0
0
[greatlrd] 16090: add struct DDRAWI_DIRECTDRAW_GBL
by greatlrd@svn.reactos.com
add struct DDRAWI_DIRECTDRAW_GBL Modified: trunk/reactos/include/ddk/ddrawi.h _____ Modified: trunk/reactos/include/ddk/ddrawi.h --- trunk/reactos/include/ddk/ddrawi.h 2005-06-19 12:13:57 UTC (rev 16089) +++ trunk/reactos/include/ddk/ddrawi.h 2005-06-19 12:14:31 UTC (rev 16090) @@ -1324,6 +1324,86 @@ LPDDHAL_WAITFORVERTICALBLANK WaitForVerticalBlank; // PRIVATE: ptr to callback } DDHAL_WAITFORVERTICALBLANKDATA; + +/********************************************************************** *********/ +/* DdGetDriverInfo need also _DDRAWI_DIRECTDRAW_GBL for ULONG_PTR dwContext */ +/********************************************************************** *********/ + +typedef struct _DDRAWI_DIRECTDRAW_GBL +{ + DWORD dwRefCnt; + DWORD dwFlags; + FLATPTR fpPrimaryOrig; + DDCORECAPS ddCaps; + DWORD dwInternal1; + DWORD dwUnused1[9]; + LPDDHAL_CALLBACKS lpDDCBtmp; + LPDDRAWI_DDRAWSURFACE_INT dsList; + LPDDRAWI_DDRAWPALETTE_INT palList; + LPDDRAWI_DDRAWCLIPPER_INT clipperList; + LPDDRAWI_DIRECTDRAW_GBL lp16DD; + DWORD dwMaxOverlays; + DWORD dwCurrOverlays; + DWORD dwMonitorFrequency; + DDCORECAPS ddHELCaps; + DWORD dwUnused2[50]; + DDCOLORKEY ddckCKDestOverlay; + DDCOLORKEY ddckCKSrcOverlay; + VIDMEMINFO vmiData; + LPVOID lpDriverHandle; + LPDDRAWI_DIRECTDRAW_LCL lpExclusiveOwner; + DWORD dwModeIndex; + DWORD dwModeIndexOrig; + DWORD dwNumFourCC; + DWORD FAR *lpdwFourCC; + DWORD dwNumModes; + LPDDHALMODEINFO lpModeInfo; + PROCESS_LIST plProcessList; + DWORD dwSurfaceLockCount; + DWORD dwAliasedLockCnt; + ULONG_PTR dwReserved3; + ULONG_PTR hDD; + char cObsolete[12]; + DWORD dwReserved1; + DWORD dwReserved2; + DBLNODE dbnOverlayRoot; + volatile LPWORD lpwPDeviceFlags; + DWORD dwPDevice; + DWORD dwWin16LockCnt; + DWORD dwUnused3; + DWORD hInstance; + DWORD dwEvent16; + DWORD dwSaveNumModes; + ULONG_PTR lpD3DGlobalDriverData; + ULONG_PTR lpD3DHALCallbacks; + DDCORECAPS ddBothCaps; + LPDDVIDEOPORTCAPS lpDDVideoPortCaps; + LPDDRAWI_DDVIDEOPORT_INT dvpList; + ULONG_PTR lpD3DHALCallbacks2; + RECT rectDevice; + DWORD cMonitors; + LPVOID gpbmiSrc; + LPVOID gpbmiDest; + LPHEAPALIASINFO phaiHeapAliases; + ULONG_PTR hKernelHandle; + ULONG_PTR pfnNotifyProc; + LPDDKERNELCAPS lpDDKernelCaps; + LPDDNONLOCALVIDMEMCAPS lpddNLVCaps; + LPDDNONLOCALVIDMEMCAPS lpddNLVHELCaps; + LPDDNONLOCALVIDMEMCAPS lpddNLVBothCaps; + ULONG_PTR lpD3DExtendedCaps; + DWORD dwDOSBoxEvent; + RECT rectDesktop; + char cDriverName[MAX_DRIVER_NAME]; + ULONG_PTR lpD3DHALCallbacks3; + DWORD dwNumZPixelFormats; + LPDDPIXELFORMAT lpZPixelFormats; + LPDDRAWI_DDMOTIONCOMP_INT mcList; + DWORD hDDVxd; + DDSCAPSEX ddsCapsMore; +} DDRAWI_DIRECTDRAW_GBL; + + #ifdef __cplusplus } /* extern "C" */ #endif
19 years, 6 months
1
0
0
0
← Newer
1
...
24
25
26
27
28
29
30
...
65
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
Results per page:
10
25
50
100
200