adding a simple NtGdiGetStockObject

it show undocumented stockobject exists in windows xp/2003
value 20 and 21

svn path=/trunk/; revision=33407
This commit is contained in:
Magnus Olsen 2008-05-10 14:01:40 +00:00
parent 826f6108be
commit c958c7e3b0
2 changed files with 33 additions and 1 deletions

View file

@ -0,0 +1,30 @@
INT
Test_NtGdiGetStockObject(PTESTINFO pti)
{
RTEST(NtGdiGetStockObject(WHITE_BRUSH) != 0);
RTEST(NtGdiGetStockObject(LTGRAY_BRUSH) != 0);
RTEST(NtGdiGetStockObject(GRAY_BRUSH) != 0);
RTEST(NtGdiGetStockObject(DKGRAY_BRUSH) != 0);
RTEST(NtGdiGetStockObject(BLACK_BRUSH) != 0);
RTEST(NtGdiGetStockObject(NULL_BRUSH) != 0);
RTEST(NtGdiGetStockObject(WHITE_PEN) != 0);
RTEST(NtGdiGetStockObject(BLACK_PEN) != 0);
RTEST(NtGdiGetStockObject(NULL_PEN) != 0);
RTEST(NtGdiGetStockObject(9) == 0);
RTEST(NtGdiGetStockObject(OEM_FIXED_FONT) != 0);
RTEST(NtGdiGetStockObject(ANSI_FIXED_FONT) != 0);
RTEST(NtGdiGetStockObject(ANSI_VAR_FONT) != 0);
RTEST(NtGdiGetStockObject(SYSTEM_FONT) != 0);
RTEST(NtGdiGetStockObject(DEVICE_DEFAULT_FONT) != 0);
RTEST(NtGdiGetStockObject(DEFAULT_PALETTE) != 0);
RTEST(NtGdiGetStockObject(SYSTEM_FIXED_FONT) != 0);
RTEST(NtGdiGetStockObject(DEFAULT_GUI_FONT) != 0);
RTEST(NtGdiGetStockObject(DC_BRUSH) != 0);
RTEST(NtGdiGetStockObject(DC_PEN) != 0);
RTEST(NtGdiGetStockObject(20) != 0);
RTEST(NtGdiGetStockObject(21) != 0);
RTEST(NtGdiGetStockObject(22) == 0);
RTEST(NtGdiGetStockObject(23) == 0);
return APISTATUS_NORMAL;
}

View file

@ -23,6 +23,7 @@
#include "ntgdi/NtGdiSetBitmapBits.c"
//#include "ntgdi/NtGdiSTROBJ_vEnumStart.c"
#include "ntgdi/NtGdiGetDIBits.c"
#include "ntgdi/NtGdiGetStockObject.c"
#include "ntuser/NtUserCallHwnd.c"
#include "ntuser/NtUserCallHwndLock.c"
@ -50,7 +51,7 @@ TESTENTRY TestList[] =
/* ntgdi */
{ L"NtGdiArcInternal", Test_NtGdiArcInternal },
{ L"NtGdiBitBlt", Test_NtGdiBitBlt },
{ L"NtGdiCreateBitmap", Test_NtGdiCreateBitmap },
{ L"NtGdiCreateBitmap", Test_NtGdiCreateBitmap },
{ L"NtGdiCreateCompatibleBitmap", Test_NtGdiCreateCompatibleBitmap },
{ L"NtGdiDoPalette", Test_NtGdiDoPalette },
{ L"NtGdiEngCreatePalette", Test_NtGdiEngCreatePalette },
@ -65,6 +66,7 @@ TESTENTRY TestList[] =
{ L"NtGdiSelectPen", Test_NtGdiSelectPen },
// { L"NtGdiSTROBJ_vEnumStart", Test_NtGdiSTROBJ_vEnumStart },
{ L"NtGdiGetDIBitsInternal", Test_NtGdiGetDIBitsInternal },
{ L"NtGdiGetStockObject", Test_NtGdiGetStockObject },
/* ntuser */
{ L"NtUserCallHwnd", Test_NtUserCallHwnd },