Author: tkreuzer
Date: Fri Sep 28 21:26:29 2007
New Revision: 29284
URL:
http://svn.reactos.org/svn/reactos?rev=29284&view=rev
Log:
- header update
- add a resource
Added:
trunk/rostests/apitests/w32knapi/ntuser/NtUserFindExistingCursorIcon.c
trunk/rostests/apitests/w32knapi/ntuser/NtUserRedrawWindow.c
trunk/rostests/apitests/w32knapi/resource/
trunk/rostests/apitests/w32knapi/resource.h
trunk/rostests/apitests/w32knapi/resource/system.ico (with props)
trunk/rostests/apitests/w32knapi/w32knapi.rc
Modified:
trunk/rostests/apitests/w32knapi/ntdd/NtGdiDdCreateDirectDrawObject.c
trunk/rostests/apitests/w32knapi/ntdd/NtGdiDdDeleteDirectDrawObject.c
trunk/rostests/apitests/w32knapi/ntdd/NtGdiDdQueryDirectDrawObject.c
trunk/rostests/apitests/w32knapi/ntgdi/NtGdiEngCreatePalette.c
trunk/rostests/apitests/w32knapi/ntgdi/NtGdiEnumFontOpen.c
trunk/rostests/apitests/w32knapi/ntgdi/NtGdiSetBitmapBits.c
trunk/rostests/apitests/w32knapi/ntuser/NtUserCountClipboardFormats.c
trunk/rostests/apitests/w32knapi/testlist.c
trunk/rostests/apitests/w32knapi/w32knapi.h
trunk/rostests/apitests/w32knapi/w32knapi.rbuild
Modified: trunk/rostests/apitests/w32knapi/ntdd/NtGdiDdCreateDirectDrawObject.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/w32knapi/ntdd/Nt…
==============================================================================
--- trunk/rostests/apitests/w32knapi/ntdd/NtGdiDdCreateDirectDrawObject.c (original)
+++ trunk/rostests/apitests/w32knapi/ntdd/NtGdiDdCreateDirectDrawObject.c Fri Sep 28
21:26:29 2007
@@ -1,4 +1,3 @@
-#include "../w32knapi.h"
INT
Test_NtGdiDdCreateDirectDrawObject(PTESTINFO pti)
Modified: trunk/rostests/apitests/w32knapi/ntdd/NtGdiDdDeleteDirectDrawObject.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/w32knapi/ntdd/Nt…
==============================================================================
--- trunk/rostests/apitests/w32knapi/ntdd/NtGdiDdDeleteDirectDrawObject.c (original)
+++ trunk/rostests/apitests/w32knapi/ntdd/NtGdiDdDeleteDirectDrawObject.c Fri Sep 28
21:26:29 2007
@@ -1,14 +1,3 @@
-#include "../w32knapi.h"
-
-W32KAPI
-BOOL
-APIENTRY
-NtGdiDdDeleteDirectDrawObject(
- HANDLE hDirectDrawLocal
-)
-{
- return (BOOL)Syscall(L"NtGdiDdDeleteDirectDrawObject", 1,
&hDirectDrawLocal);
-}
INT
Test_NtGdiDdDeleteDirectDrawObject(PTESTINFO pti)
Modified: trunk/rostests/apitests/w32knapi/ntdd/NtGdiDdQueryDirectDrawObject.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/w32knapi/ntdd/Nt…
==============================================================================
--- trunk/rostests/apitests/w32knapi/ntdd/NtGdiDdQueryDirectDrawObject.c (original)
+++ trunk/rostests/apitests/w32knapi/ntdd/NtGdiDdQueryDirectDrawObject.c Fri Sep 28
21:26:29 2007
@@ -1,23 +1,3 @@
-#include "../w32knapi.h"
-
-W32KAPI
-BOOL STDCALL
-NtGdiDdQueryDirectDrawObject(
- HANDLE hDirectDrawLocal,
- DD_HALINFO *pHalInfo,
- DWORD *pCallBackFlags,
- LPD3DNTHAL_CALLBACKS puD3dCallbacks,
- LPD3DNTHAL_GLOBALDRIVERDATA puD3dDriverData,
- PDD_D3DBUFCALLBACKS puD3dBufferCallbacks,
- LPDDSURFACEDESC puD3dTextureFormats,
- DWORD *puNumHeaps,
- VIDEOMEMORY *puvmList,
- DWORD *puNumFourCC,
- DWORD *puFourCC
-)
-{
- return (BOOL)Syscall(L"NtGdiDdQueryDirectDrawObject", 11,
&hDirectDrawLocal);
-}
INT
Test_NtGdiDdQueryDirectDrawObject(PTESTINFO pti)
Modified: trunk/rostests/apitests/w32knapi/ntgdi/NtGdiEngCreatePalette.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/w32knapi/ntgdi/N…
==============================================================================
--- trunk/rostests/apitests/w32knapi/ntgdi/NtGdiEngCreatePalette.c (original)
+++ trunk/rostests/apitests/w32knapi/ntgdi/NtGdiEngCreatePalette.c Fri Sep 28 21:26:29
2007
@@ -1,16 +1,3 @@
-
-HPALETTE
-APIENTRY
-NtGdiEngCreatePalette(
- IN ULONG iMode,
- IN ULONG cColors,
- IN ULONG *pulColors,
- IN FLONG flRed,
- IN FLONG flGreen,
- IN FLONG flBlue)
-{
- return (HPALETTE)Syscall(L"NtGdiEngCreatePalette", 6, &iMode);
-}
INT
Test_NtGdiEngCreatePalette(PTESTINFO pti)
Modified: trunk/rostests/apitests/w32knapi/ntgdi/NtGdiEnumFontOpen.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/w32knapi/ntgdi/N…
==============================================================================
--- trunk/rostests/apitests/w32knapi/ntgdi/NtGdiEnumFontOpen.c (original)
+++ trunk/rostests/apitests/w32knapi/ntgdi/NtGdiEnumFontOpen.c Fri Sep 28 21:26:29 2007
@@ -25,7 +25,11 @@
/* We should not be able to use DeleteObject() on the handle */
TEST(DeleteObject((HGDIOBJ)idEnum) == FALSE);
- // FIXME: Close the enum handle
+ NtGdiEnumFontClose(idEnum);
+
+ // Test no logfont (NULL): should word
+ // Test empty lfFaceName string: should not work
+
return APISTATUS_NORMAL;
}
Modified: trunk/rostests/apitests/w32knapi/ntgdi/NtGdiSetBitmapBits.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/w32knapi/ntgdi/N…
==============================================================================
--- trunk/rostests/apitests/w32knapi/ntgdi/NtGdiSetBitmapBits.c (original)
+++ trunk/rostests/apitests/w32knapi/ntgdi/NtGdiSetBitmapBits.c Fri Sep 28 21:26:29 2007
@@ -1,5 +1,3 @@
-#include "../w32knapi.h"
-
INT
Test_NtGdiSetBitmapBits(PTESTINFO pti)
{
Modified: trunk/rostests/apitests/w32knapi/ntuser/NtUserCountClipboardFormats.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/w32knapi/ntuser/…
==============================================================================
--- trunk/rostests/apitests/w32knapi/ntuser/NtUserCountClipboardFormats.c (original)
+++ trunk/rostests/apitests/w32knapi/ntuser/NtUserCountClipboardFormats.c Fri Sep 28
21:26:29 2007
@@ -1,5 +1,3 @@
-#include "../w32knapi.h"
-
/* First the call stub */
DWORD STDCALL
NtUserCountClipboardFormats(VOID)
Added: trunk/rostests/apitests/w32knapi/ntuser/NtUserFindExistingCursorIcon.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/w32knapi/ntuser/…
==============================================================================
--- trunk/rostests/apitests/w32knapi/ntuser/NtUserFindExistingCursorIcon.c (added)
+++ trunk/rostests/apitests/w32knapi/ntuser/NtUserFindExistingCursorIcon.c Fri Sep 28
21:26:29 2007
@@ -1,0 +1,7 @@
+INT
+Test_NtUserFindExistingCursoricon(PTESTINFO pti)
+{
+
+ return APISTATUS_NORMAL;
+}
+
Added: trunk/rostests/apitests/w32knapi/ntuser/NtUserRedrawWindow.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/w32knapi/ntuser/…
==============================================================================
--- trunk/rostests/apitests/w32knapi/ntuser/NtUserRedrawWindow.c (added)
+++ trunk/rostests/apitests/w32knapi/ntuser/NtUserRedrawWindow.c Fri Sep 28 21:26:29 2007
@@ -1,0 +1,30 @@
+INT
+Test_NtUserRedrawWindow(PTESTINFO pti)
+{
+ HWND hWnd;
+ RECT rect;
+
+ hWnd = CreateWindowA("BUTTON",
+ "Test",
+ BS_PUSHBUTTON | WS_VISIBLE,
+ 0,
+ 0,
+ 50,
+ 30,
+ NULL,
+ NULL,
+ g_hInstance,
+ 0);
+ ASSERT(hWnd);
+
+ rect.left = 0;
+ rect.top = 0;
+ rect.right = 10;
+ rect.bottom = 10;
+
+ TEST(NtUserRedrawWindow(hWnd, &rect, NULL, RDW_VALIDATE) == TRUE);
+
+ DestroyWindow(hWnd);
+
+ return APISTATUS_NORMAL;
+}
Added: trunk/rostests/apitests/w32knapi/resource.h
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/w32knapi/resourc…
==============================================================================
--- trunk/rostests/apitests/w32knapi/resource.h (added)
+++ trunk/rostests/apitests/w32knapi/resource.h Fri Sep 28 21:26:29 2007
@@ -1,0 +1,2 @@
+
+#define IDI_ICON 1000
Added: trunk/rostests/apitests/w32knapi/resource/system.ico
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/w32knapi/resourc…
==============================================================================
Binary file - no diff available.
Propchange: trunk/rostests/apitests/w32knapi/resource/system.ico
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
Modified: trunk/rostests/apitests/w32knapi/testlist.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/w32knapi/testlis…
==============================================================================
--- trunk/rostests/apitests/w32knapi/testlist.c (original)
+++ trunk/rostests/apitests/w32knapi/testlist.c Fri Sep 28 21:26:29 2007
@@ -20,6 +20,8 @@
#include "ntgdi/NtGdiGetDIBits.c"
#include "ntuser/NtUserCountClipboardFormats.c"
+#include "ntuser/NtUserFindExistingCursorIcon.c"
+#include "ntuser/NtUserRedrawWindow.c"
/* The List of tests */
TESTENTRY TestList[] =
@@ -44,7 +46,9 @@
{ L"NtGdiGetDIBitsInternal", Test_NtGdiGetDIBitsInternal },
/* ntuser */
- { L"NtUserCountClipboardFormats", Test_NtUserCountClipboardFormats }
+ { L"NtUserCountClipboardFormats", Test_NtUserCountClipboardFormats },
+ { L"NtUserFindExistingCursorIcon", Test_NtUserFindExistingCursoricon },
+ { L"NtUserRedrawWindow", Test_NtUserRedrawWindow }
};
/* The function that gives us the number of tests */
Modified: trunk/rostests/apitests/w32knapi/w32knapi.h
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/w32knapi/w32knap…
==============================================================================
--- trunk/rostests/apitests/w32knapi/w32knapi.h (original)
+++ trunk/rostests/apitests/w32knapi/w32knapi.h Fri Sep 28 21:26:29 2007
@@ -1,26 +1,29 @@
#ifndef _W32KNAPI_H
#define _W32KNAPI_H
+/* SDK/NDK Headers */
+#define NTOS_MODE_USER
#define WIN32_NO_STATUS
-#define NTOS_MODE_USER
-#define WINVER 0x501
-
#include <windows.h>
+#include <winuser.h>
+#include <windowsx.h>
+#include <winnls32.h>
+#include <ndk/ntndk.h>
#include <wingdi.h>
#include <winddi.h>
-#include <ntddk.h>
#include <d3dnthal.h>
#include <prntfont.h>
/* Public Win32K Headers */
+#include <win32k/ntusrtyp.h>
+#include <win32k/ntuser.h>
#include <win32k/callback.h>
-#include <win32k/ntusrtyp.h>
#include <win32k/ntgdityp.h>
+#include <ntgdi.h>
#include <win32k/ntgdihdl.h>
-#include <ntgdi.h>
-
#include "../apitest.h"
+#include "resource.h"
typedef struct
{
Modified: trunk/rostests/apitests/w32knapi/w32knapi.rbuild
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/w32knapi/w32knap…
==============================================================================
--- trunk/rostests/apitests/w32knapi/w32knapi.rbuild (original)
+++ trunk/rostests/apitests/w32knapi/w32knapi.rbuild Fri Sep 28 21:26:29 2007
@@ -2,6 +2,7 @@
<include base="w32knapi">.</include>
<define name="__USE_W32API" />
<define name="_WIN32_WINNT">0x0501</define>
+ <define name="WINVER">0x501</define>
<library>apitest</library>
<library>kernel32</library>
<library>user32</library>
@@ -10,4 +11,5 @@
<library>w32kdll</library>
<file>w32knapi.c</file>
<file>testlist.c</file>
+ <file>w32knapi.rc</file>
</module>
Added: trunk/rostests/apitests/w32knapi/w32knapi.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/w32knapi/w32knap…
==============================================================================
--- trunk/rostests/apitests/w32knapi/w32knapi.rc (added)
+++ trunk/rostests/apitests/w32knapi/w32knapi.rc Fri Sep 28 21:26:29 2007
@@ -1,0 +1,5 @@
+#include <windows.h>
+#include "resource.h"
+
+IDI_ICON ICON "resource/system.ico"
+