- Clean up win32k headers even more
- remove INTERNAL_CALL and use NTAPI instead
- remove several unneeded definitions
- remove several unneeded header inclusions

svn path=/trunk/; revision=53467
This commit is contained in:
Giannis Adamopoulos 2011-08-27 12:38:23 +00:00
parent a0213bada8
commit 24abf1b222
75 changed files with 347 additions and 1311 deletions

View file

@ -391,102 +391,4 @@ CLIPOBJ_bEnum(
return ClipGDI->EnumPos < ClipGDI->EnumRects.c;
}
BOOLEAN FASTCALL
ClipobjToSpans(
PSPAN *Spans,
UINT *Count,
CLIPOBJ *ClipRegion,
PRECTL Boundary)
{
BOOL EnumMore;
UINT i, NewCount;
RECT_ENUM RectEnum;
PSPAN NewSpans;
RECTL *Rect;
ASSERT(Boundary->top <= Boundary->bottom && Boundary->left <= Boundary->right);
*Count = Boundary->bottom - Boundary->top;
if (*Count > 0)
{
*Spans = ExAllocatePoolWithTag(PagedPool, *Count * sizeof(SPAN), GDITAG_CLIPOBJ);
if (NULL == *Spans)
{
*Count = 0;
return FALSE;
}
}
if (NULL == ClipRegion || DC_TRIVIAL == ClipRegion->iDComplexity)
{
if (0 != *Count)
{
for (i = 0; i < Boundary->bottom - Boundary->top; i++)
{
(*Spans)[i].X = Boundary->left;
(*Spans)[i].Y = Boundary->top + i;
(*Spans)[i].Width = Boundary->right - Boundary->left;
}
}
return TRUE;
}
*Count = 0;
CLIPOBJ_cEnumStart(ClipRegion, FALSE, CT_RECTANGLES, CD_ANY, 0);
do
{
EnumMore = CLIPOBJ_bEnum(ClipRegion, (ULONG) sizeof(RECT_ENUM), (PVOID) &RectEnum);
NewCount = *Count;
for (i = 0; i < RectEnum.c; i++)
{
NewCount += RectEnum.arcl[i].bottom - RectEnum.arcl[i].top;
}
if (NewCount != *Count)
{
NewSpans = ExAllocatePoolWithTag(PagedPool, NewCount * sizeof(SPAN), GDITAG_CLIPOBJ);
if (NULL == NewSpans)
{
if (NULL != *Spans)
{
ExFreePoolWithTag(*Spans, GDITAG_CLIPOBJ);
*Spans = NULL;
}
*Count = 0;
return FALSE;
}
if (0 != *Count)
{
PSPAN dest, src;
UINT i = *Count;
for(dest = NewSpans, src = *Spans;i > 0; i--)
{
*dest++ = *src++;
}
ExFreePoolWithTag(*Spans, GDITAG_CLIPOBJ);
}
*Spans = NewSpans;
}
for (Rect = RectEnum.arcl; Rect < RectEnum.arcl + RectEnum.c; Rect++)
{
for (i = 0; i < Rect->bottom - Rect->top; i++)
{
(*Spans)[*Count].X = Rect->left;
(*Spans)[*Count].Y = Rect->top + i;
(*Spans)[*Count].Width = Rect->right - Rect->left;
(*Count)++;
}
}
ASSERT(*Count == NewCount);
}
while (EnumMore);
if (0 != *Count)
{
EngSort((PBYTE) *Spans, sizeof(SPAN), *Count, (SORTCOMP) CompareSpans);
}
return TRUE;
}
/* EOF */

View file

@ -19,7 +19,7 @@
/*!
* \brief DRIVEROBJ cleanup function
*/
BOOL INTERNAL_CALL
BOOL NTAPI
DRIVEROBJ_Cleanup(PVOID pObject)
{
PEDRIVEROBJ pedo = pObject;

View file

@ -35,7 +35,7 @@ EngSetPointerTag(
* FUNCTION: Notify the mouse driver that drawing is about to begin in
* a rectangle on a particular surface.
*/
INT INTERNAL_CALL
INT NTAPI
MouseSafetyOnDrawStart(
PPDEVOBJ ppdev,
LONG HazardX1,
@ -91,7 +91,7 @@ MouseSafetyOnDrawStart(
/*
* FUNCTION: Notify the mouse driver that drawing has finished on a surface.
*/
INT INTERNAL_CALL
INT NTAPI
MouseSafetyOnDrawEnd(
PPDEVOBJ ppdev)
{
@ -125,7 +125,7 @@ MouseSafetyOnDrawEnd(
/* SOFTWARE MOUSE POINTER IMPLEMENTATION **************************************/
VOID
INTERNAL_CALL
NTAPI
IntHideMousePointer(
PDEVOBJ *ppdev,
SURFOBJ *psoDest)
@ -179,7 +179,7 @@ IntHideMousePointer(
}
VOID
INTERNAL_CALL
NTAPI
IntShowMousePointer(PDEVOBJ *ppdev, SURFOBJ *psoDest)
{
GDIPOINTER *pgp;

View file

@ -64,7 +64,7 @@ ULONG FASTCALL BitmapFormat(ULONG cBits, ULONG iCompression)
}
BOOL
INTERNAL_CALL
NTAPI
SURFACE_Cleanup(PVOID ObjectBody)
{
PSURFACE psurf = (PSURFACE)ObjectBody;

View file

@ -1,9 +1,5 @@
#pragma once
#include <include/win32.h>
#include <include/winsta.h>
#include <include/window.h>
typedef struct _ACCELERATOR_TABLE
{
HEAD head;
@ -11,12 +7,6 @@ typedef struct _ACCELERATOR_TABLE
LPACCEL Table;
} ACCELERATOR_TABLE, *PACCELERATOR_TABLE;
INIT_FUNCTION
NTSTATUS
NTAPI
InitAcceleratorImpl(VOID);
NTSTATUS FASTCALL
CleanupAcceleratorImpl(VOID);
INIT_FUNCTION NTSTATUS NTAPI InitAcceleratorImpl(VOID);
NTSTATUS FASTCALL CleanupAcceleratorImpl(VOID);
PACCELERATOR_TABLE FASTCALL UserGetAccelObject(HACCEL);

View file

@ -1,7 +1,6 @@
#pragma once
INT APIENTRY BITMAP_GetObject(SURFACE * bmp, INT count, LPVOID buffer);
HBITMAP FASTCALL IntCreateBitmap(IN SIZEL Size, IN LONG Width, IN ULONG Format, IN ULONG Flags, IN PVOID Bits);
HBITMAP FASTCALL BITMAP_CopyBitmap (HBITMAP hBitmap);
HBITMAP

View file

@ -1,7 +1,5 @@
#pragma once
#include "gdiobj.h"
/* Internal interface */
#define NB_HATCH_STYLES 6
@ -96,7 +94,7 @@ typedef struct _EBRUSHOBJ
#define BRUSH_ShareUnlockBrush(pBrush) GDIOBJ_vDereferenceObject((POBJ)pBrush)
INT FASTCALL BRUSH_GetObject (PBRUSH GdiObject, INT Count, LPLOGBRUSH Buffer);
BOOL INTERNAL_CALL BRUSH_Cleanup(PVOID ObjectBody);
BOOL NTAPI BRUSH_Cleanup(PVOID ObjectBody);
struct _DC;
@ -124,10 +122,6 @@ PVOID
NTAPI
EBRUSHOBJ_pvGetEngBrush(EBRUSHOBJ *pebo);
PVOID FASTCALL AllocateObjectAttr(VOID);
VOID FASTCALL FreeObjectAttr(PVOID);
BOOL FASTCALL IntGdiSetBrushOwner(PBRUSH,DWORD);
BOOL FASTCALL GreSetBrushOwner(HBRUSH,DWORD);

View file

@ -1,7 +1,5 @@
#pragma once
#include <include/win32.h>
LRESULT APIENTRY
co_IntCallWindowProc(WNDPROC Proc,
BOOLEAN IsAnsiProc,

View file

@ -1,22 +1,10 @@
#pragma once
#include <include/win32.h>
#include <include/window.h>
BOOL FASTCALL
co_IntDestroyCaret(PTHREADINFO Win32Thread);
BOOL FASTCALL
IntSetCaretBlinkTime(UINT uMSeconds);
BOOL FASTCALL
co_IntSetCaretPos(int X, int Y);
BOOL FASTCALL
IntSwitchCaretShowing(PVOID Info);
BOOL FASTCALL co_IntDestroyCaret(PTHREADINFO Win32Thread);
BOOL FASTCALL IntSetCaretBlinkTime(UINT uMSeconds);
BOOL FASTCALL co_IntSetCaretPos(int X, int Y);
BOOL FASTCALL IntSwitchCaretShowing(PVOID Info);
BOOL FASTCALL co_UserShowCaret(PWND WindowObject);
BOOL FASTCALL co_UserHideCaret(PWND WindowObject);
/* EOF */

View file

@ -1,8 +1,5 @@
#pragma once
#include <include/win32.h>
#include <include/desktop.h>
#define IS_ATOM(x) \
(((ULONG_PTR)(x) > 0x0) && ((ULONG_PTR)(x) < 0x10000))
@ -19,17 +16,10 @@ IsCallProcHandle(IN WNDPROC lpWndProc)
return ((ULONG_PTR)lpWndProc & 0xFFFF0000) == 0xFFFF0000;
}
WNDPROC
GetCallProcHandle(IN PCALLPROCDATA CallProc);
VOID
DestroyCallProc(IN PDESKTOPINFO Desktop,
IN OUT PCALLPROCDATA CallProc);
PCALLPROCDATA
CloneCallProc(IN PDESKTOP Desktop,
IN PCALLPROCDATA CallProc);
PCALLPROCDATA
CreateCallProc(IN PDESKTOP Desktop,
IN WNDPROC WndProc,
@ -43,48 +33,14 @@ UserGetCallProcInfo(IN HANDLE hCallProc,
void FASTCALL
DestroyProcessClasses(PPROCESSINFO Process );
PCLS
IntReferenceClass(IN OUT PCLS BaseClass,
IN OUT PCLS *ClassLink,
IN PDESKTOP Desktop);
VOID
IntDereferenceClass(IN OUT PCLS Class,
IN PDESKTOPINFO Desktop,
IN PPROCESSINFO pi);
RTL_ATOM
UserRegisterClass(IN CONST WNDCLASSEXW* lpwcx,
IN PUNICODE_STRING ClassName,
IN PUNICODE_STRING MenuName,
IN DWORD fnID,
IN DWORD dwFlags);
BOOL
UserUnregisterClass(IN PUNICODE_STRING ClassName,
IN HINSTANCE hInstance,
OUT PCLSMENUNAME pClassMenuName);
RTL_ATOM
IntGetClassAtom(IN PUNICODE_STRING ClassName,
IN HINSTANCE hInstance OPTIONAL,
IN PPROCESSINFO pi OPTIONAL,
OUT PCLS *BaseClass OPTIONAL,
OUT PCLS **Link OPTIONAL);
PCLS
IntGetAndReferenceClass(PUNICODE_STRING ClassName, HINSTANCE hInstance);
PCLS
FASTCALL
IntCreateClass(IN CONST WNDCLASSEXW* lpwcx,
IN PUNICODE_STRING ClassName,
IN PUNICODE_STRING MenuName,
IN DWORD fnID,
IN DWORD dwFlags,
IN PDESKTOP Desktop,
IN PPROCESSINFO pi);
BOOL FASTCALL UserRegisterSystemClasses(VOID);
VOID
@ -99,8 +55,6 @@ BOOL
IntCheckProcessDesktopClasses(IN PDESKTOP Desktop,
IN BOOL FreeOnFailure);
BOOL FASTCALL LookupFnIdToiCls(int, int * );
WNDPROC FASTCALL IntGetClassWndProc(PCLS, BOOL);
ULONG_PTR FASTCALL UserGetCPD(PVOID,GETCPD,ULONG_PTR);
/* EOF */

View file

@ -1,9 +0,0 @@
#pragma once
NTSTATUS FASTCALL
IntSafeCopyUnicodeString(PUNICODE_STRING Dest,
PUNICODE_STRING Source);
NTSTATUS FASTCALL
IntSafeCopyUnicodeStringTerminateNULL(PUNICODE_STRING Dest,
PUNICODE_STRING Source);

View file

@ -1,10 +1,5 @@
#pragma once
#include "window.h"
#include <include/win32.h>
VOID FASTCALL IntIncrementSequenceNumber(VOID);
typedef struct _ClipboardChainElement
{
PWND window;
@ -40,12 +35,6 @@ typedef struct _CLIPBOARDSYSTEM
} CLIPBOARDSYSTEM, *PCLIPBOARDSYSTEM;
VOID FASTCALL
IntClipboardFreeWindow(PWND window);
VOID FASTCALL IntClipboardFreeWindow(PWND window);
UINT APIENTRY IntEnumClipboardFormats(UINT format);
/*
UINT FASTCALL
IntEnumClipboardFormats(UINT format);
*/
VOID FASTCALL IntIncrementSequenceNumber(VOID);

View file

@ -1,8 +1,5 @@
#pragma once
INT FASTCALL IntGdiGetClipBox(PDC, RECTL* rc);
INT FASTCALL IntGdiExtSelectClipRgn (PDC, PROSRGNDATA, int);
INT FASTCALL GdiGetClipBox(HDC hDC, RECTL *rc);
INT FASTCALL GdiSelectVisRgn(HDC hdc, HRGN hrgn);
INT FASTCALL GdiExtSelectClipRgn (PDC dc, HRGN hrgn, int fnMode);

View file

@ -32,10 +32,4 @@ typedef struct _COLORTRANSFORMOBJ
extern HCOLORSPACE hStockColorSpace;
const PALETTEENTRY* FASTCALL COLOR_GetSystemPaletteTemplate (VOID);
COLORREF APIENTRY COLOR_LookupNearestColor (PALETTEENTRY* palPalEntry, INT size, COLORREF color);
INT APIENTRY COLOR_PaletteLookupExactIndex (PALETTEENTRY* palPalEntry, INT size, COLORREF col);
INT APIENTRY COLOR_PaletteLookupPixel(PALETTEENTRY *palPalEntry, INT size, XLATEOBJ *XlateObj, COLORREF col, BOOL skipReserved);
UINT FASTCALL IntGdiRealizePalette (HDC);
HCOLORSPACE FASTCALL IntGdiCreateColorSpace(PLOGCOLORSPACEEXW);
BOOL FASTCALL IntGdiDeleteColorSpace(HCOLORSPACE);

View file

@ -1,8 +1,5 @@
#pragma once
#include <include/dc.h>
#include <include/xformobj.h>
#define IntLPtoDP(pdc, ppt, count) DC_vXformWorldToDevice(pdc, count, (PPOINTL)(ppt), (PPOINTL)(ppt));
#define CoordLPtoDP(pdc, ppt) DC_vXformWorldToDevice(pdc, 1, (PPOINTL)(ppt), (PPOINTL)(ppt));
#define IntDPtoLP(pdc, ppt, count) DC_vXformDeviceToWorld(pdc, count, (PPOINTL)(ppt), (PPOINTL)(ppt));

View file

@ -76,22 +76,4 @@ PSYSTEM_CURSORINFO IntGetSysCursorInfo(VOID);
#define IntReleaseCurIconObject(CurIconObj) \
UserDereferenceObject(CurIconObj)
ULONG
NTAPI
GreSetPointerShape(
HDC hdc,
HBITMAP hbmMask,
HBITMAP hbmColor,
LONG xHot,
LONG yHot,
LONG x,
LONG y);
VOID
NTAPI
GreMovePointer(
HDC hdc,
LONG x,
LONG y);
/* EOF */

View file

@ -1,15 +1,6 @@
#ifndef __WIN32K_DC_H
#define __WIN32K_DC_H
typedef struct _DC *PDC;
#include "engobjects.h"
#include "brush.h"
#include "bitmaps.h"
#include "pdevobj.h"
#include "palette.h"
#include "region.h"
/* Constants ******************************************************************/
/* Get/SetBounds/Rect support. */
@ -154,16 +145,10 @@ extern PDC defaultDCstate;
INIT_FUNCTION NTSTATUS NTAPI InitDcImpl(VOID);
PPDEVOBJ FASTCALL IntEnumHDev(VOID);
PDC NTAPI DC_AllocDcWithHandle(VOID);
VOID FASTCALL DC_InitDC(HDC DCToInit);
BOOL NTAPI DC_bAllocDcAttr(PDC pdc);
VOID FASTCALL DC_FreeDcAttr(HDC);
BOOL INTERNAL_CALL DC_Cleanup(PVOID ObjectBody);
BOOL FASTCALL DC_SetOwnership(HDC hDC, PEPROCESS Owner);
VOID FASTCALL DC_LockDisplay(HDC);
VOID FASTCALL DC_UnlockDisplay(HDC);
BOOL NTAPI DC_Cleanup(PVOID ObjectBody);
BOOL FASTCALL IntGdiDeleteDC(HDC, BOOL);
VOID FASTCALL DC_UpdateXforms(PDC dc);
BOOL FASTCALL DC_InvertXform(const XFORM *xformSrc, XFORM *xformDest);
VOID FASTCALL DC_vUpdateViewportExt(PDC pdc);
VOID FASTCALL DC_vCopyState(PDC pdcSrc, PDC pdcDst, BOOL to);
@ -176,27 +161,19 @@ VOID FASTCALL DC_vPrepareDCsForBlit(PDC pdc1, RECT rc1, PDC pdc2, RECT rc2);
VOID NTAPI DC_vRestoreDC(IN PDC pdc, INT iSaveLevel);
BOOL FASTCALL DCU_SyncDcAttrtoUser(PDC);
BOOL FASTCALL DCU_SynchDcAttrtoUser(HDC);
VOID FASTCALL DCU_SetDcUndeletable(HDC);
VOID NTAPI DC_vFreeDcAttr(PDC pdc);
VOID NTAPI DC_vInitDc(PDC pdc, DCTYPE dctype, PPDEVOBJ ppdev);
COLORREF FASTCALL IntGdiSetBkColor (HDC hDC, COLORREF Color);
INT FASTCALL IntGdiSetBkMode(HDC hDC, INT backgroundMode);
COLORREF APIENTRY IntGdiGetBkColor(HDC hDC);
INT APIENTRY IntGdiGetBkMode(HDC hDC);
COLORREF FASTCALL IntGdiSetTextColor(HDC hDC, COLORREF color);
UINT FASTCALL IntGdiSetTextAlign(HDC hDC, UINT Mode);
UINT APIENTRY IntGdiGetTextAlign(HDC hDC);
COLORREF APIENTRY IntGdiGetTextColor(HDC hDC);
INT APIENTRY IntGdiSetStretchBltMode(HDC hDC, INT stretchBltMode);
VOID FASTCALL IntGdiReferencePdev(PPDEVOBJ pPDev);
VOID FASTCALL IntGdiUnreferencePdev(PPDEVOBJ pPDev, DWORD CleanUpType);
HDC FASTCALL IntGdiCreateDisplayDC(HDEV hDev, ULONG DcType, BOOL EmptyDC);
BOOL FASTCALL IntGdiCleanDC(HDC hDC);
VOID FASTCALL IntvGetDeviceCaps(PPDEVOBJ, PDEVCAPS);
BOOL FASTCALL MakeInfoDC(PDC,BOOL);
BOOL FASTCALL IntSetDefaultRegion(PDC);
BOOL NTAPI GreSetDCOwner(HDC hdc, ULONG ulOwner);

View file

@ -1,13 +1,5 @@
#pragma once
/* Ported from WINE by Jason Filby */
typedef struct tagDCE *PDCE;
#include <include/window.h>
typedef HANDLE HDCE;
/* DC hook codes */
#define DCHC_INVALIDVISRGN 0x0001
#define DCHC_DELETEDC 0x0002
@ -37,24 +29,19 @@ typedef struct tagDCE
PTHREADINFO ptiOwner;
PPROCESSINFO ppiOwner;
struct _MONITOR* pMonitor;
} DCE; /* PDCE already declared at top of file */
} DCE, *PDCE;
/* internal DCX flags, see psdk/winuser.h for the rest */
#define DCX_DCEEMPTY 0x00000800
#define DCX_DCEBUSY 0x00001000
#define DCX_DCEDIRTY 0x00002000
#define DCX_LAYEREDWIN 0x00004000
#define DCX_DCPOWNED 0x00008000
#define DCX_NOCLIPCHILDREN 0x00080000
#define DCX_NORECOMPUTE 0x00100000
#define DCX_INDESTROY 0x00400000
#define DCX_DCEEMPTY 0x00000800
#define DCX_DCEBUSY 0x00001000
#define DCX_DCEDIRTY 0x00002000
#define DCX_LAYEREDWIN 0x00004000
#define DCX_DCPOWNED 0x00008000
#define DCX_NOCLIPCHILDREN 0x00080000
#define DCX_NORECOMPUTE 0x00100000
#define DCX_INDESTROY 0x00400000
BOOL FASTCALL DCE_Cleanup(PDCE pDce);
PDCE FASTCALL DceAllocDCE(PWND Window, DCE_TYPE Type);
PDCE FASTCALL DCE_FreeDCE(PDCE dce);
VOID FASTCALL DCE_FreeWindowDCE(HWND);
INT FASTCALL DCE_ExcludeRgn(HDC, HWND, HRGN);
BOOL FASTCALL DCE_InvalidateDCE(HWND, const PRECTL);
HWND FASTCALL IntWindowFromDC(HDC hDc);
PDCE FASTCALL DceFreeDCE(PDCE dce, BOOLEAN Force);
void FASTCALL DceEmptyCache(void);

View file

@ -1,8 +1,5 @@
#pragma once
#include "msgqueue.h"
#include "window.h"
typedef struct _DESKTOP
{
PDESKTOPINFO pDeskInfo;
@ -32,7 +29,7 @@ typedef struct _DESKTOP
/* Thread blocking input */
PVOID BlockInputThread;
LIST_ENTRY ShellHookWindows;
} DESKTOP, *PDESKTOP;
} DESKTOP;
// Desktop flags
#define DF_TME_HOVER 0x00000400
@ -81,9 +78,6 @@ IntDesktopObjectDelete(PWIN32_DELETEMETHOD_PARAMETERS Parameters);
NTSTATUS NTAPI
IntDesktopOkToClose(PWIN32_OKAYTOCLOSEMETHOD_PARAMETERS Parameters);
LRESULT CALLBACK
IntDesktopWindowProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam);
HDC FASTCALL
IntGetScreenDC(VOID);
@ -111,9 +105,6 @@ co_IntShowDesktop(PDESKTOP Desktop, ULONG Width, ULONG Height);
NTSTATUS FASTCALL
IntHideDesktop(PDESKTOP Desktop);
HDESK FASTCALL
IntGetDesktopObjectHandle(PDESKTOP DesktopObject);
BOOL IntSetThreadDesktop(IN HDESK hDesktop,
IN BOOL FreeOnFailure);
@ -123,18 +114,19 @@ IntValidateDesktopHandle(
KPROCESSOR_MODE AccessMode,
ACCESS_MASK DesiredAccess,
PDESKTOP *Object);
NTSTATUS FASTCALL
IntParseDesktopPath(PEPROCESS Process,
PUNICODE_STRING DesktopPath,
HWINSTA *hWinSta,
HDESK *hDesktop);
BOOL FASTCALL IntDesktopUpdatePerUserSettings(BOOL bEnable);
VOID APIENTRY UserRedrawDesktop(VOID);
BOOL IntRegisterShellHookWindow(HWND hWnd);
BOOL IntDeRegisterShellHookWindow(HWND hWnd);
VOID co_IntShellHookNotify(WPARAM Message, LPARAM lParam);
HDC FASTCALL UserGetDesktopDC(ULONG,BOOL,BOOL);
BOOL FASTCALL IntPaintDesktop(HDC hDC);
#define IntIsActiveDesktop(Desktop) \
((Desktop)->rpwinstaParent->ActiveDesktop == (Desktop))

View file

@ -1,10 +1,4 @@
//#define _PDEVOBJ _PDEVOBJ2
//#define PDEVOBJ PDEVOBJ2
//#define PPDEVOBJ PPDEVOBJ2
//typedef struct _PDEVOBJ *PPDEVOBJ;
#define TAG_GDEV 'gdev'
VOID
@ -35,10 +29,6 @@ NTSTATUS
NTAPI
InitDeviceImpl(VOID);
BOOL
FASTCALL
DC_AllocDcAttr(PDC pdc);
//#define KeRosDumpStackFrames(Frames, Count) KdSystemDebugControl(TAG('R', 'o', 's', 'D'), (PVOID)Frames, Count, NULL, 0, NULL, KernelMode)
NTSYSAPI ULONG APIENTRY RtlWalkFrameChain(OUT PVOID *Callers, IN ULONG Count, IN ULONG Flags);

View file

@ -1,21 +1,11 @@
#pragma once
#include "dc.h"
INT FASTCALL
DIB_BitmapInfoSize (const BITMAPINFO * info, WORD coloruse);
HBITMAP APIENTRY
DIB_CreateDIBSection (PDC dc, CONST BITMAPINFO *bmi, UINT usage, LPVOID *bits, HANDLE section, DWORD offset, DWORD ovr_pitch);
int FASTCALL
DIB_GetBitmapInfo( const BITMAPINFOHEADER *header, LONG *width,
INT FASTCALL DIB_BitmapInfoSize (const BITMAPINFO * info, WORD coloruse);
HBITMAP APIENTRY DIB_CreateDIBSection (PDC dc, CONST BITMAPINFO *bmi, UINT usage, LPVOID *bits, HANDLE section, DWORD offset, DWORD ovr_pitch);
int FASTCALL DIB_GetBitmapInfo( const BITMAPINFOHEADER *header, LONG *width,
LONG *height, WORD *planes, WORD *bpp, DWORD *compr, DWORD *size );
INT APIENTRY
DIB_GetDIBImageBytes (INT width, INT height, INT depth);
HPALETTE FASTCALL
DIB_MapPaletteColors(PPALETTE ppal, CONST BITMAPINFO* lpbmi);
HPALETTE FASTCALL
BuildDIBPalette (CONST BITMAPINFO *bmi);
INT APIENTRY DIB_GetDIBImageBytes (INT width, INT height, INT depth);
HPALETTE FASTCALL DIB_MapPaletteColors(PPALETTE ppal, CONST BITMAPINFO* lpbmi);
HPALETTE FASTCALL BuildDIBPalette (CONST BITMAPINFO *bmi);
BITMAPINFO* FASTCALL DIB_ConvertBitmapInfo(CONST BITMAPINFO* bmi, DWORD Usage);
VOID FASTCALL DIB_FreeConvertedBitmapInfo(BITMAPINFO* converted, BITMAPINFO* orig);

View file

@ -1,21 +0,0 @@
#pragma once
#include <winddi.h>
typedef struct _DRIVERS
{
LIST_ENTRY ListEntry;
PVOID SectionPointer;
PVOID BaseAddress;
UNICODE_STRING DriverName;
}DRIVERS, *PDRIVERS;
BOOL DRIVER_RegisterDriver(LPCWSTR Name, PFN_DrvEnableDriver EnableDriver);
PFN_DrvEnableDriver DRIVER_FindExistingDDIDriver(LPCWSTR Name);
PFN_DrvEnableDriver DRIVER_FindDDIDriver(LPCWSTR Name);
PFILE_OBJECT DRIVER_FindMPDriver(ULONG DisplayNumber);
BOOL DRIVER_BuildDDIFunctions(PDRVENABLEDATA DED,
PDRIVER_FUNCTIONS DF);
BOOL DRIVER_UnregisterDriver(LPCWSTR Name);
INT DRIVER_ReferenceDriver (LPCWSTR Name);
INT DRIVER_UnreferenceDriver (LPCWSTR Name);

View file

@ -1,7 +1,5 @@
#pragma once
#include "gdiobj.h"
/* Object structure */
typedef struct _EDRIVEROBJ
{
@ -11,7 +9,7 @@ typedef struct _EDRIVEROBJ
} EDRIVEROBJ, *PEDRIVEROBJ;
/* Cleanup function */
BOOL INTERNAL_CALL DRIVEROBJ_Cleanup(PVOID pObject);
BOOL NTAPI DRIVEROBJ_Cleanup(PVOID pObject);
#define DRIVEROBJ_AllocObjectWithHandle() ((PEDRIVEROBJ)GDIOBJ_AllocObjWithHandle(GDI_OBJECT_TYPE_DRIVEROBJ, sizeof(DRIVEROBJ)))

View file

@ -1,7 +1,5 @@
#pragma once
BOOL APIENTRY EngIntersectRect (PRECTL prcDst, PRECTL prcSrc1, PRECTL prcSrc2);
VOID FASTCALL EngDeleteXlate (XLATEOBJ *XlateObj);
BOOL APIENTRY
IntEngMaskBlt(SURFOBJ *psoDest,
SURFOBJ *psoMask,

View file

@ -28,9 +28,6 @@
#pragma once
#include <ft2build.h>
#include <freetype/freetype.h>
/* Structure of internal gdi objects that win32k manages for ddi engine:
|---------------------------------|
| Public part |

View file

@ -3,26 +3,17 @@
/*
* These functions take the window handles from current message queue.
*/
HWND FASTCALL
IntGetCaptureWindow(VOID);
HWND FASTCALL
IntGetFocusWindow(VOID);
HWND FASTCALL
co_UserSetCapture(HWND hWnd);
BOOL FASTCALL
IntReleaseCapture(VOID);
HWND FASTCALL IntGetCaptureWindow(VOID);
HWND FASTCALL IntGetFocusWindow(VOID);
HWND FASTCALL co_UserSetCapture(HWND hWnd);
BOOL FASTCALL IntReleaseCapture(VOID);
/*
* These functions take the window handles from current thread queue.
*/
HWND FASTCALL
IntGetThreadFocusWindow(VOID);
HWND FASTCALL IntGetThreadFocusWindow(VOID);
HWND APIENTRY IntGetCapture(VOID);
HWND FASTCALL UserGetActiveWindow(VOID);
BOOL FASTCALL
co_IntMouseActivateWindow(PWND Window);
BOOL FASTCALL
co_IntSetForegroundWindow(PWND Window);
HWND FASTCALL
co_IntSetActiveWindow(PWND Window);
BOOL FASTCALL co_IntMouseActivateWindow(PWND Window);
BOOL FASTCALL co_IntSetForegroundWindow(PWND Window);
HWND FASTCALL co_IntSetActiveWindow(PWND Window);

View file

@ -1,11 +1,5 @@
#pragma once
#include "dc.h"
#include "math.h"
#include "xformobj.h"
#include <ft2build.h>
#include FT_FREETYPE_H
typedef struct tagFLOAT_POINT
{
FLOAT x, y;

View file

@ -5,9 +5,6 @@
#pragma once
/* Public GDI Object/Handle definitions */
#include "win32.h"
/* The first 10 entries are never used in windows, they are empty */
#define RESERVE_ENTRIES_COUNT 10
@ -31,7 +28,7 @@ extern PGDI_HANDLE_TABLE GdiHandleTable;
typedef PVOID PGDIOBJ;
typedef BOOL (INTERNAL_CALL *GDICLEANUPPROC)(PVOID ObjectBody);
typedef BOOL (NTAPI *GDICLEANUPPROC)(PVOID ObjectBody);
/* Every GDI Object must have this standard type of header.
* It's for thread locking. */
@ -175,8 +172,8 @@ NTAPI
GDIOBJ_pvGetObjectAttr(
POBJ pobj);
BOOL INTERNAL_CALL GDIOBJ_ConvertToStockObj(HGDIOBJ *hObj);
POBJ INTERNAL_CALL GDIOBJ_AllocObjWithHandle(ULONG ObjectType, ULONG cjSize);
PGDIOBJ INTERNAL_CALL GDIOBJ_ShareLockObj(HGDIOBJ hObj, DWORD ObjectType);
PVOID INTERNAL_CALL GDI_MapHandleTable(PEPROCESS Process);
BOOL NTAPI GDIOBJ_ConvertToStockObj(HGDIOBJ *hObj);
POBJ NTAPI GDIOBJ_AllocObjWithHandle(ULONG ObjectType, ULONG cjSize);
PGDIOBJ NTAPI GDIOBJ_ShareLockObj(HGDIOBJ hObj, DWORD ObjectType);
PVOID NTAPI GDI_MapHandleTable(PEPROCESS Process);

View file

@ -1,8 +1,5 @@
#pragma once
#include <include/winsta.h>
#include <include/window.h>
typedef struct _HOT_KEY_ITEM
{
LIST_ENTRY ListEntry;
@ -15,13 +12,7 @@ typedef struct _HOT_KEY_ITEM
#define IDHOT_REACTOS (-9)
INIT_FUNCTION
NTSTATUS
NTAPI
InitHotkeyImpl(VOID);
//NTSTATUS FASTCALL
//CleanupHotKeys(PWINSTATION_OBJECT WinStaObject);
INIT_FUNCTION NTSTATUS NTAPI InitHotkeyImpl(VOID);
BOOL FASTCALL
GetHotKey (UINT fsModifiers,
@ -30,14 +21,9 @@ GetHotKey (UINT fsModifiers,
HWND *hWnd,
int *id);
VOID FASTCALL
UnregisterWindowHotKeys(PWND Window);
VOID FASTCALL
UnregisterThreadHotKeys(struct _ETHREAD *Thread);
UINT FASTCALL
DefWndGetHotKey(HWND hwnd);
INT FASTCALL
DefWndSetHotKey( PWND pWnd, WPARAM wParam);
VOID FASTCALL UnregisterWindowHotKeys(PWND Window);
VOID FASTCALL UnregisterThreadHotKeys(struct _ETHREAD *Thread);
UINT FASTCALL DefWndGetHotKey(HWND hwnd);
INT FASTCALL DefWndSetHotKey( PWND pWnd, WPARAM wParam);
/* EOF */

View file

@ -43,28 +43,15 @@ extern PATTACHINFO gpai;
/* From kbdxx.c -- Key changes with numlock */
#define KNUMP 0x400
INIT_FUNCTION
NTSTATUS
NTAPI
InitInputImpl(VOID);
INIT_FUNCTION
NTSTATUS
NTAPI
InitKeyboardImpl(VOID);
PUSER_MESSAGE_QUEUE W32kGetPrimitiveMessageQueue(VOID);
VOID W32kUnregisterPrimitiveMessageQueue(VOID);
INIT_FUNCTION NTSTATUS NTAPI InitInputImpl(VOID);
INIT_FUNCTION NTSTATUS NTAPI InitKeyboardImpl(VOID);
PKBL W32kGetDefaultKeyLayout(VOID);
VOID FASTCALL W32kKeyProcessMessage(LPMSG Msg, PKBDTABLES KeyLayout, BYTE Prefix);
BOOL FASTCALL IntBlockInput(PTHREADINFO W32Thread, BOOL BlockIt);
BOOL FASTCALL IntMouseInput(MOUSEINPUT *mi, BOOL Injected);
BOOL FASTCALL IntKeyboardInput(KEYBDINPUT *ki, BOOL Injected);
BOOL UserInitDefaultKeyboardLayout(VOID);
PKBL UserHklToKbl(HKL hKl);
BOOL FASTCALL UserAttachThreadInput(PTHREADINFO,PTHREADINFO,BOOL);
BOOL FASTCALL IntConnectThreadInput(PTHREADINFO,PTHREADINFO*,PUSER_MESSAGE_QUEUE*);
#define ThreadHasInputAccess(W32Thread) \
(TRUE)

View file

@ -119,11 +119,6 @@ IntEngCreateClipRegion(ULONG count,
VOID FASTCALL
IntEngDeleteClipRegion(CLIPOBJ *ClipObj);
BOOLEAN FASTCALL
ClipobjToSpans(PSPAN *Spans,
UINT *Count,
CLIPOBJ *ClipRegion,
PRECTL Boundary);
BOOL FASTCALL
IntEngTransparentBlt(SURFOBJ *Dest,
@ -142,12 +137,6 @@ IntEngPaint(IN SURFOBJ *Surface,
IN POINTL *BrushOrigin,
IN MIX Mix);
VOID APIENTRY
IntEngMovePointer(IN SURFOBJ *pso,
IN LONG x,
IN LONG y,
IN RECTL *prcl);
ULONG APIENTRY
IntEngSetPointerShape(
IN SURFOBJ *pso,

View file

@ -1,28 +1,10 @@
#pragma once
#include "region.h"
/* Brush functions */
extern HDC hSystemBM;
extern HSEMAPHORE hsemDriverMgmt;
XLATEOBJ*
FASTCALL
IntCreateXlateForBlt(PDC pDCDest, PDC pDCSrc, SURFACE* pDestSurf, SURFACE* pSrcSurf);
HBRUSH APIENTRY
IntGdiCreateDIBBrush(
CONST BITMAPINFO *BitmapInfo,
UINT ColorSpec,
UINT BitmapInfoSize,
CONST VOID *PackedDIB);
HBRUSH APIENTRY
IntGdiCreateHatchBrush(
INT Style,
COLORREF Color);
HBRUSH APIENTRY
IntGdiCreatePatternBrush(
HBITMAP hBitmap);
@ -34,27 +16,9 @@ IntGdiCreateSolidBrush(
HBRUSH APIENTRY
IntGdiCreateNullBrush(VOID);
BOOL FASTCALL
IntPatBlt(
PDC dc,
INT XLeft,
INT YLeft,
INT Width,
INT Height,
DWORD ROP,
PBRUSH BrushObj);
VOID FASTCALL
IntGdiSetSolidBrushColor(HBRUSH hBrush, COLORREF Color);
/* Pen functions */
HPEN APIENTRY
IntGdiExtCreatePen(DWORD, DWORD, IN ULONG, IN ULONG, IN ULONG_PTR, IN ULONG_PTR, DWORD, PULONG, IN ULONG, IN BOOL, IN OPTIONAL HBRUSH);
VOID FASTCALL
IntGdiSetSolidPenColor(HPEN hPen, COLORREF Color);
/* Line functions */
BOOL FASTCALL
@ -95,33 +59,8 @@ IntGdiPolylineTo(DC *dc,
LPPOINT pt,
DWORD Count);
BOOL FASTCALL
IntGdiArc(DC *dc,
int LeftRect,
int TopRect,
int RightRect,
int BottomRect,
int XStartArc,
int YStartArc,
int XEndArc,
int YEndArc);
INT FASTCALL
IntGdiGetArcDirection(DC *dc);
/* Shape functions */
BOOL FASTCALL
IntGdiPolygon(PDC dc,
PPOINT UnsafePoints,
int Count);
BOOL FASTCALL
IntGdiPolyPolygon(DC *dc,
LPPOINT Points,
PULONG PolyCounts,
int Count);
BOOL
NTAPI
GreGradientFill(
@ -134,12 +73,6 @@ GreGradientFill(
/* DC functions */
BOOL FASTCALL
IntGdiGetDCOrg(PDC pDC, PPOINTL pPointl);
INT FASTCALL
IntGdiGetObject(HANDLE handle, INT count, LPVOID buffer);
HDC FASTCALL
IntGdiCreateDC(PUNICODE_STRING Driver,
PUNICODE_STRING Device,
@ -167,88 +100,31 @@ IntGetSysColor(INT nIndex);
/* Other Stuff */
INT
FASTCALL
IntGdiEscape(PDC dc,
INT Escape,
INT InSize,
LPCSTR InData,
LPVOID OutData);
NTSTATUS
FASTCALL
IntEnumDisplaySettings(
IN PUNICODE_STRING pDeviceName OPTIONAL,
IN DWORD iModeNum,
IN OUT LPDEVMODEW pDevMode,
IN DWORD dwFlags);
HBITMAP
FASTCALL
IntCreateCompatibleBitmap(PDC Dc,
INT Width,
INT Height);
HBITMAP APIENTRY
IntGdiCreateBitmap(
INT Width,
INT Height,
UINT Planes,
UINT BitsPixel,
IN OPTIONAL LPBYTE pBits);
HDC APIENTRY IntGdiGetDCState(HDC hDC);
WORD APIENTRY IntGdiSetHookFlags(HDC hDC, WORD Flags);
VOID APIENTRY IntGdiSetDCState ( HDC hDC, HDC hDCSave );
LONG APIENTRY IntSetBitmapBits(PSURFACE bmp, DWORD Bytes, IN PBYTE Bits);
LONG APIENTRY IntGetBitmapBits(PSURFACE bmp, DWORD Bytes, OUT PBYTE Bits);
UINT APIENTRY IntSetDIBColorTable(HDC hDC, UINT StartIndex, UINT Entries, CONST RGBQUAD *Colors);
UINT APIENTRY IntGetDIBColorTable(HDC hDC, UINT StartIndex, UINT Entries, RGBQUAD *Colors);
UINT APIENTRY
IntAnimatePalette(HPALETTE hPal, UINT StartIndex,
UINT NumEntries, CONST PPALETTEENTRY PaletteColors);
UINT APIENTRY
IntGetPaletteEntries(HPALETTE hpal,
UINT StartIndex,
UINT Entries,
LPPALETTEENTRY pe);
UINT APIENTRY
IntSetPaletteEntries(HPALETTE hpal,
UINT Start,
UINT Entries,
CONST LPPALETTEENTRY pe);
UINT APIENTRY
IntGetSystemPaletteEntries(HDC hDC,
UINT StartIndex,
UINT Entries,
LPPALETTEENTRY pe);
UINT APIENTRY
IntSetDIBColorTable(HDC hDC, UINT StartIndex, UINT Entries, CONST RGBQUAD *Colors);
VOID FASTCALL CreateStockObjects (VOID);
VOID FASTCALL CreateSysColorObjects (VOID);
BOOL APIENTRY
GreStretchBltMask(IN HDC hdcDst,
IN INT xDst,
IN INT yDst,
IN INT cxDst,
IN INT cyDst,
IN HDC hdcSrc,
IN INT xSrc,
IN INT ySrc,
IN INT cxSrc,
IN INT cySrc,
IN DWORD dwRop,
IN DWORD dwBackColor,
IN HDC hdcMask,
IN INT xMask,
IN INT yMask);
PPOINT FASTCALL GDI_Bezier (const POINT *Points, INT count, PINT nPtsOut);

View file

@ -49,53 +49,17 @@ IntGetMenuObject(HMENU hMenu);
#define IntReleaseMenuObject(MenuObj) \
UserDereferenceObject(MenuObj)
BOOL FASTCALL
IntFreeMenuItem(PMENU_OBJECT MenuObject, PMENU_ITEM MenuItem, BOOL bRecurse);
BOOL FASTCALL
IntRemoveMenuItem(PMENU_OBJECT MenuObject, UINT uPosition, UINT uFlags,
BOOL bRecurse);
UINT FASTCALL
IntDeleteMenuItems(PMENU_OBJECT MenuObject, BOOL bRecurse);
BOOL FASTCALL
IntDestroyMenuObject(PMENU_OBJECT MenuObject, BOOL bRecurse, BOOL RemoveFromProcess);
PMENU_OBJECT FASTCALL
IntCreateMenu(PHANDLE Handle, BOOL IsMenuBar);
PMENU_OBJECT FASTCALL
IntCloneMenu(PMENU_OBJECT Source);
BOOL FASTCALL
IntSetMenuFlagRtoL(PMENU_OBJECT MenuObject);
BOOL FASTCALL
IntSetMenuContextHelpId(PMENU_OBJECT MenuObject, DWORD dwContextHelpId);
BOOL FASTCALL
IntGetMenuInfo(PMENU_OBJECT MenuObject, PROSMENUINFO lpmi);
BOOL FASTCALL
IntSetMenuInfo(PMENU_OBJECT MenuObject, PROSMENUINFO lpmi);
int FASTCALL
IntGetMenuItemByFlag(PMENU_OBJECT MenuObject, UINT uSearchBy, UINT fFlag,
PMENU_OBJECT *SubMenu, PMENU_ITEM *MenuItem,
PMENU_ITEM *PrevMenuItem);
UINT FASTCALL
IntEnableMenuItem(PMENU_OBJECT MenuObject, UINT uIDEnableItem, UINT uEnable);
DWORD FASTCALL
IntCheckMenuItem(PMENU_OBJECT MenuObject, UINT uIDCheckItem, UINT uCheck);
BOOL FASTCALL
IntSetMenuItemRect(PMENU_OBJECT MenuObject, UINT Item, BOOL fByPos, RECTL *rcRect);
DWORD FASTCALL UserInsertMenuItem(PMENU_OBJECT Menu, UINT uItem, BOOL fByPosition, LPCMENUITEMINFOW lpmii);
BOOL FASTCALL
IntCleanupMenus(struct _EPROCESS *Process, PPROCESSINFO Win32Process);
@ -103,11 +67,5 @@ BOOL FASTCALL
IntInsertMenuItem(PMENU_OBJECT MenuObject, UINT uItem, BOOL fByPosition,
PROSMENUITEMINFO ItemInfo);
INIT_FUNCTION
NTSTATUS
NTAPI
InitMenuImpl(VOID);
NTSTATUS FASTCALL
CleanupMenuImpl(VOID);
PMENU_OBJECT FASTCALL
IntGetSystemMenu(PWND Window, BOOL bRevert, BOOL RetMenu);

View file

@ -24,7 +24,6 @@ extern HGDIOBJ StockObjects[];
extern SHORT gusLanguageID;
SHORT FASTCALL IntGdiGetLanguageID(VOID);
DWORD APIENTRY IntGetQueueStatus(DWORD);
VOID FASTCALL IntUserManualGuiCheck(LONG Check);
PVOID APIENTRY HackSecureVirtualMemory(IN PVOID,IN SIZE_T,IN ULONG,OUT PVOID *);
VOID APIENTRY HackUnsecureVirtualMemory(IN PVOID);
@ -137,3 +136,12 @@ _ExInitializePushLock(PEX_PUSH_LOCK Lock)
*(PULONG_PTR)Lock = 0;
}
#define ExInitializePushLock _ExInitializePushLock
NTSTATUS FASTCALL
IntSafeCopyUnicodeString(PUNICODE_STRING Dest,
PUNICODE_STRING Source);
NTSTATUS FASTCALL
IntSafeCopyUnicodeStringTerminateNULL(PUNICODE_STRING Dest,
PUNICODE_STRING Source);

View file

@ -1,6 +1,5 @@
#pragma once
#include <pseh/pseh2.h>
NTSTATUS _MmCopyFromCaller( PVOID Target, PVOID Source, UINT Bytes );
NTSTATUS _MmCopyToCaller( PVOID Target, PVOID Source, UINT Bytes );

View file

@ -1,19 +1,23 @@
#pragma once
#include <include/winsta.h>
INT NTAPI MouseSafetyOnDrawStart(PPDEVOBJ ppdev, LONG HazardX1, LONG HazardY1, LONG HazardX2, LONG HazardY2);
INT NTAPI MouseSafetyOnDrawEnd(PPDEVOBJ ppdev);
INT INTERNAL_CALL MouseSafetyOnDrawStart(PPDEVOBJ ppdev, LONG HazardX1, LONG HazardY1, LONG HazardX2, LONG HazardY2);
INT INTERNAL_CALL MouseSafetyOnDrawEnd(PPDEVOBJ ppdev);
ULONG
NTAPI
GreSetPointerShape(
HDC hdc,
HBITMAP hbmMask,
HBITMAP hbmColor,
LONG xHot,
LONG yHot,
LONG x,
LONG y);
VOID
NTAPI
GreMovePointer(
HDC hdc,
LONG x,
LONG y);
#ifndef XBUTTON1
#define XBUTTON1 (0x01)
#endif
#ifndef XBUTTON2
#define XBUTTON2 (0x02)
#endif
#ifndef MOUSEEVENTF_XDOWN
#define MOUSEEVENTF_XDOWN (0x80)
#endif
#ifndef MOUSEEVENTF_XUP
#define MOUSEEVENTF_XUP (0x100)
#endif

View file

@ -1,8 +1,5 @@
#pragma once
#include "hook.h"
#include "cursoricon.h"
#define MSQ_HUNG 5000
#define MSQ_NORMAL 0
#define MSQ_ISHOOK 1
@ -143,23 +140,15 @@ typedef struct _USER_MESSAGE_QUEUE
#define QF_CAPTURELOCKED 0x00100000
#define QF_ACTIVEWNDTRACKING 0x00200000
BOOL FASTCALL
MsqIsHung(PUSER_MESSAGE_QUEUE MessageQueue);
BOOL FASTCALL MsqIsHung(PUSER_MESSAGE_QUEUE MessageQueue);
VOID CALLBACK HungAppSysTimerProc(HWND,UINT,UINT_PTR,DWORD);
NTSTATUS FASTCALL
co_MsqSendMessage(PUSER_MESSAGE_QUEUE MessageQueue,
HWND Wnd, UINT Msg, WPARAM wParam, LPARAM lParam,
UINT uTimeout, BOOL Block, INT HookMessage,
ULONG_PTR *uResult);
PUSER_MESSAGE FASTCALL
MsqCreateMessage(LPMSG Msg);
VOID FASTCALL
MsqDestroyMessage(PUSER_MESSAGE Message);
VOID FASTCALL
MsqPostMessage(PUSER_MESSAGE_QUEUE MessageQueue,
MSG* Msg, BOOLEAN HardwareMessage, DWORD MessageBits);
VOID FASTCALL
MsqPostQuitMessage(PUSER_MESSAGE_QUEUE MessageQueue, ULONG ExitCode);
NTSTATUS FASTCALL co_MsqSendMessage(PUSER_MESSAGE_QUEUE MessageQueue,
HWND Wnd, UINT Msg, WPARAM wParam, LPARAM lParam,
UINT uTimeout, BOOL Block, INT HookMessage, ULONG_PTR *uResult);
PUSER_MESSAGE FASTCALL MsqCreateMessage(LPMSG Msg);
VOID FASTCALL MsqDestroyMessage(PUSER_MESSAGE Message);
VOID FASTCALL MsqPostMessage(PUSER_MESSAGE_QUEUE MessageQueue, MSG* Msg, BOOLEAN HardwareMessage, DWORD MessageBits);
VOID FASTCALL MsqPostQuitMessage(PUSER_MESSAGE_QUEUE MessageQueue, ULONG ExitCode);
BOOLEAN APIENTRY
MsqPeekMessage(IN PUSER_MESSAGE_QUEUE MessageQueue,
IN BOOLEAN Remove,
@ -183,39 +172,18 @@ co_MsqPeekMouseMove(IN PUSER_MESSAGE_QUEUE MessageQueue,
IN UINT MsgFilterLow,
IN UINT MsgFilterHigh,
OUT MSG* pMsg);
BOOLEAN FASTCALL
MsqInitializeMessageQueue(struct _ETHREAD *Thread, PUSER_MESSAGE_QUEUE MessageQueue);
VOID FASTCALL
MsqCleanupMessageQueue(PUSER_MESSAGE_QUEUE MessageQueue);
PUSER_MESSAGE_QUEUE FASTCALL
MsqCreateMessageQueue(struct _ETHREAD *Thread);
VOID FASTCALL
MsqDestroyMessageQueue(PUSER_MESSAGE_QUEUE MessageQueue);
PUSER_MESSAGE_QUEUE FASTCALL
MsqGetHardwareMessageQueue(VOID);
INIT_FUNCTION
NTSTATUS
NTAPI
MsqInitializeImpl(VOID);
BOOLEAN FASTCALL
co_MsqDispatchOneSentMessage(PUSER_MESSAGE_QUEUE MessageQueue);
BOOLEAN FASTCALL MsqInitializeMessageQueue(struct _ETHREAD *Thread, PUSER_MESSAGE_QUEUE MessageQueue);
PUSER_MESSAGE_QUEUE FASTCALL MsqCreateMessageQueue(struct _ETHREAD *Thread);
VOID FASTCALL MsqDestroyMessageQueue(PUSER_MESSAGE_QUEUE MessageQueue);
INIT_FUNCTION NTSTATUS NTAPI MsqInitializeImpl(VOID);
BOOLEAN FASTCALL co_MsqDispatchOneSentMessage(PUSER_MESSAGE_QUEUE MessageQueue);
NTSTATUS FASTCALL
co_MsqWaitForNewMessages(PUSER_MESSAGE_QUEUE MessageQueue, PWND WndFilter,
UINT MsgFilterMin, UINT MsgFilterMax);
VOID FASTCALL
MsqIncPaintCountQueue(PUSER_MESSAGE_QUEUE Queue);
VOID FASTCALL
MsqDecPaintCountQueue(PUSER_MESSAGE_QUEUE Queue);
LRESULT FASTCALL
co_IntSendMessage(HWND hWnd,
UINT Msg,
WPARAM wParam,
LPARAM lParam);
LRESULT FASTCALL
co_IntPostOrSendMessage(HWND hWnd,
UINT Msg,
WPARAM wParam,
LPARAM lParam);
VOID FASTCALL MsqIncPaintCountQueue(PUSER_MESSAGE_QUEUE Queue);
VOID FASTCALL MsqDecPaintCountQueue(PUSER_MESSAGE_QUEUE Queue);
LRESULT FASTCALL co_IntSendMessage(HWND hWnd, UINT Msg, WPARAM wParam, LPARAM lParam);
LRESULT FASTCALL co_IntPostOrSendMessage(HWND hWnd, UINT Msg, WPARAM wParam, LPARAM lParam);
LRESULT FASTCALL
co_IntSendMessageTimeout(HWND hWnd,
UINT Msg,
@ -239,40 +207,21 @@ co_IntSendMessageWithCallBack(HWND hWnd,
ULONG_PTR CompletionCallbackContext,
ULONG_PTR *uResult);
LRESULT FASTCALL
IntDispatchMessage(MSG* Msg);
BOOL FASTCALL
IntTranslateKbdMessage(LPMSG lpMsg, UINT flags);
VOID FASTCALL
co_MsqPostKeyboardMessage(UINT uMsg, WPARAM wParam, LPARAM lParam);
VOID FASTCALL
MsqPostHotKeyMessage(PVOID Thread, HWND hWnd, WPARAM wParam, LPARAM lParam);
VOID FASTCALL
co_MsqInsertMouseMessage(MSG* Msg, DWORD flags, ULONG_PTR dwExtraInfo, BOOL Hook);
BOOL FASTCALL
MsqIsClkLck(LPMSG Msg, BOOL Remove);
BOOL FASTCALL
MsqIsDblClk(LPMSG Msg, BOOL Remove);
HWND FASTCALL
MsqSetStateWindow(PUSER_MESSAGE_QUEUE MessageQueue, ULONG Type, HWND hWnd);
__inline BOOL MsqIsSignaled( PUSER_MESSAGE_QUEUE queue );
__inline VOID MsqSetQueueBits( PUSER_MESSAGE_QUEUE queue, WORD bits );
LRESULT FASTCALL IntDispatchMessage(MSG* Msg);
BOOL FASTCALL IntTranslateKbdMessage(LPMSG lpMsg, UINT flags);
VOID FASTCALL co_MsqPostKeyboardMessage(UINT uMsg, WPARAM wParam, LPARAM lParam);
VOID FASTCALL MsqPostHotKeyMessage(PVOID Thread, HWND hWnd, WPARAM wParam, LPARAM lParam);
VOID FASTCALL co_MsqInsertMouseMessage(MSG* Msg, DWORD flags, ULONG_PTR dwExtraInfo, BOOL Hook);
BOOL FASTCALL MsqIsClkLck(LPMSG Msg, BOOL Remove);
BOOL FASTCALL MsqIsDblClk(LPMSG Msg, BOOL Remove);
HWND FASTCALL MsqSetStateWindow(PUSER_MESSAGE_QUEUE MessageQueue, ULONG Type, HWND hWnd);
BOOL APIENTRY IntInitMessagePumpHook(VOID);
BOOL APIENTRY IntUninitMessagePumpHook(VOID);
#define MAKE_LONG(x, y) ((((y) & 0xFFFF) << 16) | ((x) & 0xFFFF))
LPARAM FASTCALL MsqSetMessageExtraInfo(LPARAM lParam);
LPARAM FASTCALL MsqGetMessageExtraInfo(VOID);
VOID APIENTRY MsqRemoveWindowMessagesFromQueue(PVOID pWindow); /* F*(&$ headers, will be gone in the rewrite! */
#define IntLockHardwareMessageQueue(MsgQueue) \
KeWaitForMutexObject(&(MsgQueue)->HardwareLock, UserRequest, KernelMode, FALSE, NULL)
#define IntUnLockHardwareMessageQueue(MsgQueue) \
KeReleaseMutex(&(MsgQueue)->HardwareLock, FALSE)
#define IntReferenceMessageQueue(MsgQueue) \
InterlockedIncrement(&(MsgQueue)->References)
@ -307,11 +256,8 @@ VOID APIENTRY MsqRemoveWindowMessagesFromQueue(PVOID pWindow); /* F*(&$ headers,
#define IS_KBD_MESSAGE(message) \
(message >= WM_KEYFIRST && message <= WM_KEYLAST)
HANDLE FASTCALL
IntMsqSetWakeMask(DWORD WakeMask);
BOOL FASTCALL
IntMsqClearWakeMask(VOID);
HANDLE FASTCALL IntMsqSetWakeMask(DWORD WakeMask);
BOOL FASTCALL IntMsqClearWakeMask(VOID);
static __inline LONG
MsqCalculateMessageTime(IN PLARGE_INTEGER TickCount)
@ -322,7 +268,6 @@ MsqCalculateMessageTime(IN PLARGE_INTEGER TickCount)
VOID FASTCALL IdlePing(VOID);
VOID FASTCALL IdlePong(VOID);
BOOL FASTCALL co_MsqReplyMessage(LRESULT);
UINT FASTCALL GetWakeMask(UINT, UINT);
VOID FASTCALL MsqWakeQueue(PUSER_MESSAGE_QUEUE,DWORD,BOOL);
VOID FASTCALL ClearMsgBitsMask(PUSER_MESSAGE_QUEUE,UINT);
@ -332,4 +277,5 @@ FASTCALL
UserSetCursor(PCURICON_OBJECT NewCursor,
BOOL ForceChange);
DWORD APIENTRY IntGetQueueStatus(DWORD);
/* EOF */

View file

@ -36,13 +36,7 @@ BOOL FASTCALL UserDereferenceObject(PVOID obj);
PVOID FASTCALL UserCreateObject(PUSER_HANDLE_TABLE ht, struct _DESKTOP* pDesktop, HANDLE* h,USER_OBJECT_TYPE type , ULONG size);
BOOL FASTCALL UserDeleteObject(HANDLE h, USER_OBJECT_TYPE type );
PVOID UserGetObject(PUSER_HANDLE_TABLE ht, HANDLE handle, USER_OBJECT_TYPE type );
HANDLE UserAllocHandle(PUSER_HANDLE_TABLE ht, PVOID object, USER_OBJECT_TYPE type );
BOOL FASTCALL UserFreeHandle(PUSER_HANDLE_TABLE ht, HANDLE handle );
PVOID UserGetNextHandle(PUSER_HANDLE_TABLE ht, HANDLE* handle, USER_OBJECT_TYPE type );
PUSER_HANDLE_ENTRY handle_to_entry(PUSER_HANDLE_TABLE ht, HANDLE handle );
BOOL FASTCALL UserCreateHandleTable(VOID);
VOID UserInitHandleTable(PUSER_HANDLE_TABLE ht, PVOID mem, ULONG bytes);
static __inline VOID
UserRefObjectCo(PVOID obj, PUSER_REFERENCE_ENTRY UserReferenceEntry)
@ -76,9 +70,4 @@ UserDerefObjectCo(PVOID obj)
UserDereferenceObject(obj);
}
VOID FASTCALL CreateStockObjects (VOID);
VOID FASTCALL CreateSysColorObjects (VOID);
PPOINT FASTCALL GDI_Bezier (const POINT *Points, INT count, PINT nPtsOut);
/* EOF */

View file

@ -1,15 +1,7 @@
#pragma once
#include <include/class.h>
#include <include/msgqueue.h>
#include <include/window.h>
BOOL FASTCALL
co_UserRedrawWindow(PWND Wnd, const RECTL* UpdateRect, HRGN UpdateRgn, ULONG Flags);
VOID FASTCALL
IntInvalidateWindows(PWND Window, HRGN hRgn, ULONG Flags);
BOOL FASTCALL
IntGetPaintMessage(PWND Window, UINT MsgFilterMin, UINT MsgFilterMax, PTHREADINFO Thread,
MSG *Message, BOOL Remove);
BOOL FASTCALL co_UserRedrawWindow(PWND Wnd, const RECTL* UpdateRect, HRGN UpdateRgn, ULONG Flags);
VOID FASTCALL IntInvalidateWindows(PWND Window, HRGN hRgn, ULONG Flags);
BOOL FASTCALL IntGetPaintMessage(PWND Window, UINT MsgFilterMin, UINT MsgFilterMax, PTHREADINFO Thread, MSG *Message, BOOL Remove);
INT FASTCALL UserRealizePalette(HDC);
INT FASTCALL co_UserGetUpdateRgn(PWND, HRGN, BOOL);

View file

@ -1,7 +1,5 @@
#pragma once
#include <include/dc.h>
#define PALETTE_FIXED 0x0001 /* read-only colormap - have to use XAllocColor (if not virtual) */
#define PALETTE_VIRTUAL 0x0002 /* no mapping needed - pixel == pixel color */
@ -72,7 +70,7 @@ HPALETTE FASTCALL PALETTE_AllocPaletteIndexedRGB(ULONG NumColors,
#define PALETTE_ShareUnlockPalette(ppal) \
GDIOBJ_vDereferenceObject(&ppal->BaseObject)
BOOL INTERNAL_CALL PALETTE_Cleanup(PVOID ObjectBody);
BOOL NTAPI PALETTE_Cleanup(PVOID ObjectBody);
INIT_FUNCTION NTSTATUS NTAPI InitPaletteImpl(VOID);
VOID FASTCALL PALETTE_ValidateFlags (PALETTEENTRY* lpPalE, INT size);
INT FASTCALL PALETTE_ToPhysical (PDC dc, COLORREF color);

View file

@ -49,11 +49,8 @@ typedef struct _EPATHOBJ
#define PATH_IsPathOpen(dclevel) ( ((dclevel).hPath) && ((dclevel).flPath & DCPATH_ACTIVE) )
BOOL FASTCALL PATH_Arc (PDC dc, INT x1, INT y1, INT x2, INT y2, INT xStart, INT yStart, INT xEnd, INT yEnd, INT lines);
BOOL FASTCALL PATH_AssignGdiPath (PPATH pPathDest, const PPATH pPathSrc);
VOID FASTCALL PATH_DestroyGdiPath (PPATH pPath);
BOOL FASTCALL PATH_Ellipse (PDC dc, INT x1, INT y1, INT x2, INT y2);
VOID FASTCALL PATH_EmptyPath (PPATH pPath);
VOID FASTCALL PATH_InitGdiPath (PPATH pPath);
BOOL FASTCALL PATH_LineTo (PDC dc, INT x, INT y);
BOOL FASTCALL PATH_MoveTo (PDC dc);
BOOL FASTCALL PATH_PolyBezier (PDC dc, const POINT *pts, DWORD cbPoints);

View file

@ -29,7 +29,7 @@ INT FASTCALL REGION_GetRgnBox(PROSRGNDATA Rgn, RECTL *pRect);
BOOL FASTCALL REGION_RectInRegion(PROSRGNDATA Rgn, const RECTL *rc);
BOOL FASTCALL REGION_CropAndOffsetRegion(PROSRGNDATA rgnDst, PROSRGNDATA rgnSrc, const RECTL *rect, const POINT *off);
VOID FASTCALL REGION_SetRectRgn(PROSRGNDATA pRgn, INT LeftRect, INT TopRect, INT RightRect, INT BottomRect);
BOOL INTERNAL_CALL REGION_Cleanup(PVOID ObjectBody);
BOOL NTAPI REGION_Cleanup(PVOID ObjectBody);
extern PROSRGNDATA prgnDefault;
extern HRGN hrgnDefault;

View file

@ -1,8 +1,5 @@
#pragma once
#include "win32.h"
#include "gdiobj.h"
#define PDEV_SURFACE 0x80000000
/* GDI surface object */
@ -102,7 +99,7 @@ typedef struct _SURFACE
#define SURFACE_ShareUnlockSurface(pBMObj) \
GDIOBJ_vDereferenceObject ((POBJ)pBMObj)
BOOL INTERNAL_CALL SURFACE_Cleanup(PVOID ObjectBody);
BOOL NTAPI SURFACE_Cleanup(PVOID ObjectBody);
PSURFACE
NTAPI

View file

@ -1,7 +1,5 @@
#pragma once
#include "cursoricon.h"
// create one struct
// make usable for different users (multiple structs!)

View file

@ -1,7 +1,5 @@
#pragma once
#include <include/engobjects.h>
#define TAG_FINF 'FNIF'
//
// EXSTROBJ flags.

View file

@ -32,10 +32,7 @@ typedef struct _TIMER
extern PKTIMER MasterTimer;
INIT_FUNCTION
NTSTATUS
NTAPI
InitTimerImpl(VOID);
INIT_FUNCTION NTSTATUS NTAPI InitTimerImpl(VOID);
BOOL FASTCALL DestroyTimersForThread(PTHREADINFO pti);
BOOL FASTCALL DestroyTimersForWindow(PTHREADINFO pti, PWND Window);
BOOL FASTCALL IntKillTimer(PWND Window, UINT_PTR IDEvent, BOOL SystemTimer);

View file

@ -1,7 +1,5 @@
#pragma once
RTL_ATOM FASTCALL
IntAddAtom(LPWSTR AtomName);
ULONG FASTCALL
IntGetAtomName(RTL_ATOM nAtom, LPWSTR lpBuffer, ULONG nSize);
RTL_ATOM FASTCALL IntAddAtom(LPWSTR AtomName);
ULONG FASTCALL IntGetAtomName(RTL_ATOM nAtom, LPWSTR lpBuffer, ULONG nSize);
RTL_ATOM FASTCALL IntAddGlobalAtom(LPWSTR,BOOL);

View file

@ -41,11 +41,6 @@ PWND FASTCALL IntGetWindowObject(HWND hWnd);
HWINSTA FASTCALL UserGetProcessWindowStation(VOID);
/*************** WINPOS.C ***************/
BOOL FASTCALL
UserGetClientOrigin(PWND Window, LPPOINT Point);
/*************** FOCUS.C ***************/
HWND FASTCALL UserGetActiveWindow(VOID);
@ -56,36 +51,24 @@ HWND FASTCALL co_UserSetFocus(PWND Window);
/*************** WINDC.C ***************/
INT FASTCALL
UserReleaseDC(PWND Window, HDC hDc, BOOL EndPaint);
HDC FASTCALL
UserGetDCEx(PWND Window OPTIONAL, HANDLE ClipRegion, ULONG Flags);
HDC FASTCALL
UserGetWindowDC(PWND Wnd);
INT FASTCALL UserReleaseDC(PWND Window, HDC hDc, BOOL EndPaint);
HDC FASTCALL UserGetDCEx(PWND Window OPTIONAL, HANDLE ClipRegion, ULONG Flags);
HDC FASTCALL UserGetWindowDC(PWND Wnd);
/*************** SESSION.C ***************/
extern PRTL_ATOM_TABLE gAtomTable;
NTSTATUS FASTCALL InitSessionImpl(VOID);
/*************** METRIC.C ***************/
BOOL FASTCALL
InitMetrics(VOID);
ULONG FASTCALL
UserGetSystemMetrics(ULONG Index);
BOOL FASTCALL InitMetrics(VOID);
ULONG FASTCALL UserGetSystemMetrics(ULONG Index);
/*************** KEYBOARD.C ***************/
DWORD FASTCALL UserGetKeyState(DWORD key);
DWORD FASTCALL UserGetKeyboardType(DWORD TypeFlag);
HKL FASTCALL UserGetKeyboardLayout(DWORD dwThreadId);
@ -106,45 +89,21 @@ UserPostMessage(HWND Wnd,
WPARAM wParam,
LPARAM lParam);
/*************** PAINTING.C ***************/
BOOL FASTCALL co_UserValidateRgn(PWND Window, HRGN hRgn);
/*************** WINDOW.C ***************/
PWND FASTCALL UserGetWindowObject(HWND hWnd);
VOID FASTCALL
co_DestroyThreadWindows(struct _ETHREAD *Thread);
VOID FASTCALL co_DestroyThreadWindows(struct _ETHREAD *Thread);
HWND FASTCALL UserGetShellWindow(VOID);
HDC FASTCALL
UserGetDCEx(PWND Window OPTIONAL, HANDLE ClipRegion, ULONG Flags);
HDC FASTCALL UserGetDCEx(PWND Window OPTIONAL, HANDLE ClipRegion, ULONG Flags);
BOOLEAN FASTCALL co_UserDestroyWindow(PWND Wnd);
PWND FASTCALL UserGetAncestor(PWND Wnd, UINT Type);
/*************** MENU.C ***************/
HMENU FASTCALL UserCreateMenu(BOOL PopupMenu);
BOOL FASTCALL
UserSetMenuDefaultItem(
PMENU_OBJECT Menu,
UINT uItem,
UINT fByPos);
BOOL FASTCALL UserSetMenuDefaultItem(PMENU_OBJECT Menu, UINT uItem, UINT fByPos);
BOOL FASTCALL UserDestroyMenu(HMENU hMenu);
/*************** SCROLLBAR.C ***************/
DWORD FASTCALL

View file

@ -10,13 +10,7 @@
#pragma once
#include <include/window.h>
HRGN FASTCALL
VIS_ComputeVisibleRegion(PWND Window, BOOLEAN ClientArea,
BOOLEAN ClipChildren, BOOLEAN ClipSiblings);
VOID FASTCALL
co_VIS_WindowLayoutChanged(PWND Window, HRGN UncoveredRgn);
HRGN FASTCALL VIS_ComputeVisibleRegion(PWND Window, BOOLEAN ClientArea, BOOLEAN ClipChildren, BOOLEAN ClipSiblings);
VOID FASTCALL co_VIS_WindowLayoutChanged(PWND Window, HRGN UncoveredRgn);
/* EOF */

View file

@ -9,7 +9,6 @@
/* INCLUDES ******************************************************************/
#pragma once
#define INTERNAL_CALL APIENTRY
#ifndef _MSC_VER
#define PLACE_IN_SECTION(s) __attribute__((section(s)))
@ -24,78 +23,79 @@
#define DBG_ENABLE_SERVICE_HOOKS 0
/* misc headers */
#include <include/win32kdebug.h>
#include <include/mmcopy.h>
#include <include/tags.h>
#include <include/win32kdebug.h>
#include <include/cleanup.h>
#include <include/rect.h>
#include <include/misc.h>
/* Internal NtGdi Headers */
typedef struct _DC *PDC;
#include <include/gdiobj.h>
#include <include/surface.h>
#include <include/pdevobj.h>
#include <include/ldevobj.h>
#include <include/xformobj.h>
#include <include/bitmaps.h>
#include <include/engobjects.h>
#include <include/eng.h>
#include <include/brush.h>
#include <include/color.h>
#include <include/driverobj.h>
#include <include/palette.h>
#include <include/region.h>
#include <include/dc.h>
#include <include/dib.h>
#include <include/driver.h>
#include <include/driverobj.h>
#include <include/floatobj.h>
#include <include/palette.h>
#include <include/pdevobj.h>
#include <include/rect.h>
#include <include/xformobj.h>
#include <include/path.h>
#include <include/xlateobj.h>
#include <include/cliprgn.h>
#include <include/region.h>
#include <include/eng.h>
#include <include/inteng.h>
#include <include/intgdi.h>
#include <include/intddraw.h>
#include <include/paint.h>
#include <include/path.h>
#include <include/bitmaps.h>
#include <include/text.h>
#include <include/misc.h>
#include <include/engobjects.h>
#include <include/engevent.h>
#include <include/ldevobj.h>
#include <include/device.h>
#include <include/pen.h>
#include <include/cliprgn.h>
#include <include/coord.h>
#include <include/gdifloat.h>
#include <include/floatobj.h>
#include <dib/dib.h>
#include <include/gdidebug.h>
#include <include/mouse.h>
/* Internal NtUser Headers */
#include <include/ntuser.h>
#include <include/accelerator.h>
#include <include/clipboard.h>
#include <include/caret.h>
#include <include/class.h>
#include <include/dce.h>
#include <include/sysparams.h>
typedef struct _DESKTOP *PDESKTOP;
#include <include/win32.h>
#include <include/window.h>
#include <include/winsta.h>
#include <include/object.h>
#include <include/ntuser.h>
#include <include/cursoricon.h>
#include <include/desktop.h>
#include <include/focus.h>
#include <include/guicheck.h>
#include <include/accelerator.h>
#include <include/hook.h>
#include <include/clipboard.h>
#include <include/winsta.h>
#include <include/msgqueue.h>
#include <include/desktop.h>
#include <include/dce.h>
#include <include/focus.h>
#include <include/hotkey.h>
#include <include/input.h>
#include <include/menu.h>
#include <include/monitor.h>
#include <include/mouse.h>
#include <include/msgqueue.h>
#include <include/object.h>
#include <include/painting.h>
#include <include/prop.h>
#include <include/timer.h>
#include <include/caret.h>
#include <include/painting.h>
#include <include/class.h>
#include <include/window.h>
#include <include/sysparams.h>
#include <include/prop.h>
#include <include/guicheck.h>
#include <include/useratom.h>
#include <include/vis.h>
#include <include/userfuncs.h>
#include <include/winpos.h>
#include <include/scroll.h>
#include <include/csr.h>
#include <include/winpos.h>
#include <include/callback.h>
#include <include/gdidebug.h>

View file

@ -1,24 +1,10 @@
#pragma once
struct _PROPERTY;
struct _WINDOW_OBJECT;
typedef struct _WINDOW_OBJECT *PWINDOW_OBJECT;
#include <include/object.h>
#include <include/class.h>
#include <include/msgqueue.h>
#include <include/winsta.h>
#include <include/dce.h>
#include <include/prop.h>
#include <include/scroll.h>
extern ATOM AtomMessage;
extern ATOM AtomWndObj; /* WNDOBJ list */
extern ATOM AtomLayer;
extern ATOM AtomFlashWndState;
BOOL FASTCALL UserUpdateUiState(PWND Wnd, WPARAM wParam);
#define HAS_DLGFRAME(Style, ExStyle) \
(((ExStyle) & WS_EX_DLGMODALFRAME) || \
(((Style) & WS_DLGFRAME) && (!((Style) & WS_THICKFRAME))))
@ -30,19 +16,6 @@ BOOL FASTCALL UserUpdateUiState(PWND Wnd, WPARAM wParam);
#define HAS_THINFRAME(Style, ExStyle) \
(((Style) & WS_BORDER) || (!((Style) & (WS_CHILD | WS_POPUP))))
#define HAS_BIGFRAME(style,exStyle) \
(((style) & (WS_THICKFRAME | WS_DLGFRAME)) || \
((exStyle) & WS_EX_DLGMODALFRAME))
#define HAS_STATICOUTERFRAME(style,exStyle) \
(((exStyle) & (WS_EX_STATICEDGE|WS_EX_DLGMODALFRAME)) == \
WS_EX_STATICEDGE)
#define HAS_ANYFRAME(style,exStyle) \
(((style) & (WS_THICKFRAME | WS_DLGFRAME | WS_BORDER)) || \
((exStyle) & WS_EX_DLGMODALFRAME) || \
!((style) & (WS_CHILD | WS_POPUP)))
#define HAS_MENU(pWnd,style) ((((style) & (WS_CHILD | WS_POPUP)) != WS_CHILD) && pWnd->IDMenu)
#define IntIsDesktopWindow(WndObj) \
@ -61,73 +34,20 @@ BOOL FASTCALL UserUpdateUiState(PWND Wnd, WPARAM wParam);
#define IntGetWndProcessId(WndObj) \
WndObj->head.pti->pEThread->ThreadsProcess->UniqueProcessId
BOOL FASTCALL
IntIsWindow(HWND hWnd);
HWND* FASTCALL
IntWinListChildren(PWND Window);
INIT_FUNCTION
NTSTATUS
NTAPI
InitWindowImpl (VOID);
NTSTATUS FASTCALL
CleanupWindowImpl (VOID);
VOID FASTCALL
IntGetClientRect (PWND WindowObject, RECTL *Rect);
HWND FASTCALL
IntGetActiveWindow (VOID);
BOOL FASTCALL
IntIsWindowVisible (PWND Window);
BOOL FASTCALL
IntIsChildWindow (PWND Parent, PWND Child);
VOID FASTCALL
IntUnlinkWindow(PWND Wnd);
VOID FASTCALL
IntLinkWindow(PWND Wnd, PWND WndPrevSibling);
VOID FASTCALL
IntLinkHwnd(PWND Wnd, HWND hWndPrev);
PWND FASTCALL
IntGetAncestor(PWND Wnd, UINT Type);
PWND FASTCALL
IntGetParent(PWND Wnd);
INT FASTCALL
IntGetWindowRgn(PWND Window, HRGN hRgn);
INT FASTCALL
IntGetWindowRgnBox(PWND Window, RECTL *Rect);
BOOL FASTCALL
IntGetWindowInfo(PWND WindowObject, PWINDOWINFO pwi);
VOID FASTCALL
IntGetWindowBorderMeasures(PWND WindowObject, UINT *cx, UINT *cy);
BOOL FASTCALL
IntIsWindowInDestroy(PWND Window);
BOOL FASTCALL
IntShowOwnedPopups( PWND owner, BOOL fShow );
LRESULT FASTCALL
IntDefWindowProc( PWND Window, UINT Msg, WPARAM wParam, LPARAM lParam, BOOL Ansi);
BOOL FASTCALL UserUpdateUiState(PWND Wnd, WPARAM wParam);
BOOL FASTCALL IntIsWindow(HWND hWnd);
HWND* FASTCALL IntWinListChildren(PWND Window);
VOID FASTCALL IntGetClientRect (PWND WindowObject, RECTL *Rect);
BOOL FASTCALL IntIsChildWindow (PWND Parent, PWND Child);
VOID FASTCALL IntUnlinkWindow(PWND Wnd);
VOID FASTCALL IntLinkHwnd(PWND Wnd, HWND hWndPrev);
PWND FASTCALL IntGetParent(PWND Wnd);
VOID FASTCALL IntGetWindowBorderMeasures(PWND WindowObject, UINT *cx, UINT *cy);
BOOL FASTCALL IntShowOwnedPopups( PWND owner, BOOL fShow );
LRESULT FASTCALL IntDefWindowProc( PWND Window, UINT Msg, WPARAM wParam, LPARAM lParam, BOOL Ansi);
VOID FASTCALL IntNotifyWinEvent(DWORD, PWND, LONG, LONG, DWORD);
PWND FASTCALL co_UserCreateWindowEx(CREATESTRUCTW*, PUNICODE_STRING, PLARGE_STRING);
WNDPROC FASTCALL IntGetWindowProc(PWND,BOOL);
BOOL FASTCALL IntEnableWindow(HWND,BOOL);
DWORD FASTCALL GetNCHitEx(PWND pWnd, POINT pt);

View file

@ -27,41 +27,31 @@ typedef struct _SMWP
PCVR acvr;
} SMWP, *PSMWP;
#define IntPtInWindow(WndObject,x,y) \
((x) >= (WndObject)->rcWindow.left && \
(x) < (WndObject)->rcWindow.right && \
(y) >= (WndObject)->rcWindow.top && \
(y) < (WndObject)->rcWindow.bottom && \
(!(WndObject)->hrgnClip || ((WndObject)->style & WS_MINIMIZE) || \
NtGdiPtInRegion((WndObject)->hrgnClip, (INT)((x) - (WndObject)->rcWindow.left), \
(INT)((y) - (WndObject)->rcWindow.top))))
FORCEINLINE BOOL IntPtInWindow(PWND pwnd, INT x, INT y)
{
if(!RECTL_bPointInRect(&pwnd->rcWindow, x, y))
{
return FALSE;
}
#define IntPtInRect(lprc,pt) \
((pt.x >= (lprc)->left) && (pt.x < (lprc)->right) && (pt.y >= (lprc)->top) && (pt.y < (lprc)->bottom))
if(!pwnd->hrgnClip || pwnd->style & WS_MINIMIZE)
{
return TRUE;
}
UINT
FASTCALL co_WinPosArrangeIconicWindows(PWND parent);
BOOL FASTCALL
IntGetClientOrigin(PWND Window, LPPOINT Point);
LRESULT FASTCALL
co_WinPosGetNonClientSize(PWND Window, RECTL* WindowRect, RECTL* ClientRect);
UINT FASTCALL
co_WinPosGetMinMaxInfo(PWND Window, POINT* MaxSize, POINT* MaxPos,
POINT* MinTrack, POINT* MaxTrack);
UINT FASTCALL
co_WinPosMinMaximize(PWND WindowObject, UINT ShowFlag, RECTL* NewPos);
BOOLEAN FASTCALL
co_WinPosSetWindowPos(PWND Wnd, HWND WndInsertAfter, INT x, INT y, INT cx,
INT cy, UINT flags);
BOOLEAN FASTCALL
co_WinPosShowWindow(PWND Window, INT Cmd);
void FASTCALL
co_WinPosSendSizeMove(PWND Window);
PWND FASTCALL
co_WinPosWindowFromPoint(PWND ScopeWin, POINT *WinPoint, USHORT* HitTest);
return NtGdiPtInRegion(pwnd->hrgnClip,
x - pwnd->rcWindow.left,
y - pwnd->rcWindow.top);
}
UINT FASTCALL co_WinPosArrangeIconicWindows(PWND parent);
BOOL FASTCALL IntGetClientOrigin(PWND Window, LPPOINT Point);
LRESULT FASTCALL co_WinPosGetNonClientSize(PWND Window, RECTL* WindowRect, RECTL* ClientRect);
UINT FASTCALL co_WinPosGetMinMaxInfo(PWND Window, POINT* MaxSize, POINT* MaxPos, POINT* MinTrack, POINT* MaxTrack);
UINT FASTCALL co_WinPosMinMaximize(PWND WindowObject, UINT ShowFlag, RECTL* NewPos);
BOOLEAN FASTCALL co_WinPosSetWindowPos(PWND Wnd, HWND WndInsertAfter, INT x, INT y, INT cx, INT cy, UINT flags);
BOOLEAN FASTCALL co_WinPosShowWindow(PWND Window, INT Cmd);
void FASTCALL co_WinPosSendSizeMove(PWND Window);
PWND FASTCALL co_WinPosWindowFromPoint(PWND ScopeWin, POINT *WinPoint, USHORT* HitTest);
VOID FASTCALL co_WinPosActivateOtherWindow(PWND Window);
VOID FASTCALL WinPosInitInternalPos(PWND WindowObject,
POINT *pt, RECTL *RestoreRect);
BOOL FASTCALL IntEndDeferWindowPosEx(HDWP);
HDWP FASTCALL IntDeferWindowPos(HDWP,HWND,HWND,INT,INT,INT,INT,UINT);
VOID FASTCALL WinPosInitInternalPos(PWND WindowObject, POINT *pt, RECTL *RestoreRect);

View file

@ -1,8 +1,5 @@
#pragma once
#include "window.h"
#include "clipboard.h"
#define WINSTA_ROOT_NAME L"\\Windows\\WindowStations"
#define WINSTA_ROOT_NAME_LENGTH 23

View file

@ -34,20 +34,20 @@ XFORMOBJ_pmx(
}
ULONG
INTERNAL_CALL
NTAPI
XFORMOBJ_iSetXform(
OUT XFORMOBJ *pxo,
IN const XFORML *pxform);
ULONG
INTERNAL_CALL
NTAPI
XFORMOBJ_iCombine(
IN XFORMOBJ *pxo,
IN XFORMOBJ *pxo1,
IN XFORMOBJ *pxo2);
ULONG
INTERNAL_CALL
NTAPI
XFORMOBJ_iCombineXform(
IN XFORMOBJ *pxo,
IN XFORMOBJ *pxo1,
@ -55,7 +55,7 @@ XFORMOBJ_iCombineXform(
IN BOOL bLeftMultiply);
ULONG
INTERNAL_CALL
NTAPI
XFORMOBJ_iInverse(
OUT XFORMOBJ *pxoDst,
IN XFORMOBJ *pxoSrc);

View file

@ -7,8 +7,6 @@
*
*/
#include <include/palette.h>
struct _EXLATEOBJ;
typedef ULONG (FASTCALL *PFN_XLATE)(struct _EXLATEOBJ *pexlo, ULONG iColor);

View file

@ -14,8 +14,8 @@
HANDLE hModuleWin;
PGDI_HANDLE_TABLE INTERNAL_CALL GDIOBJ_iAllocHandleTable(OUT PSECTION_OBJECT *SectionObject);
BOOL INTERNAL_CALL GDI_CleanupForProcess (struct _EPROCESS *Process);
PGDI_HANDLE_TABLE NTAPI GDIOBJ_iAllocHandleTable(OUT PSECTION_OBJECT *SectionObject);
BOOL NTAPI GDI_CleanupForProcess (struct _EPROCESS *Process);
HANDLE GlobalUserHeap = NULL;
PSECTION_OBJECT GlobalUserHeapSection = NULL;
@ -583,8 +583,6 @@ DriverEntry(
NT_ROF(InitHotkeyImpl());
NT_ROF(InitWindowStationImpl());
NT_ROF(InitDesktopImpl());
NT_ROF(InitWindowImpl());
NT_ROF(InitMenuImpl());
NT_ROF(InitInputImpl());
NT_ROF(InitKeyboardImpl());
NT_ROF(InitMonitorImpl());

View file

@ -30,28 +30,6 @@ DestroyCallProc(IN PDESKTOPINFO Desktop,
UserDeleteObject(UserHMGetHandle(CallProc), otCallProc);
}
PCALLPROCDATA
CloneCallProc(IN PDESKTOP Desktop,
IN PCALLPROCDATA CallProc)
{
PCALLPROCDATA NewCallProc;
HANDLE Handle;
NewCallProc = (PCALLPROCDATA)UserCreateObject(gHandleTable,
Desktop,
&Handle,
otCallProc,
sizeof(CALLPROCDATA));
if (NewCallProc != NULL)
{
NewCallProc->pfnClientPrevious = CallProc->pfnClientPrevious;
NewCallProc->wType = CallProc->wType;
NewCallProc->spcpdNext = NULL;
}
return NewCallProc;
}
PCALLPROCDATA
CreateCallProc(IN PDESKTOP Desktop,
IN WNDPROC WndProc,
@ -82,8 +60,6 @@ UserGetCallProcInfo(IN HANDLE hCallProc,
{
PCALLPROCDATA CallProc;
/* NOTE: Accessing the WNDPROC_INFO structure may raise an exception! */
CallProc = UserGetObject(gHandleTable,
hCallProc,
otCallProc);

View file

@ -246,20 +246,20 @@ GetNCHitEx(PWND pWnd, POINT pt)
rcClient.right = pWnd->rcClient.right;
rcClient.bottom = pWnd->rcClient.bottom;
if (!IntPtInRect(&rcWindow, pt)) return HTNOWHERE;
if (!RECTL_bPointInRect(&rcWindow, pt.x, pt.y)) return HTNOWHERE;
Style = pWnd->style;
ExStyle = pWnd->ExStyle;
if (Style & WS_MINIMIZE) return HTCAPTION;
if (IntPtInRect( &rcClient, pt )) return HTCLIENT;
if (RECTL_bPointInRect( &rcClient, pt.x, pt.y )) return HTCLIENT;
/* Check borders */
if (HAS_THICKFRAME( Style, ExStyle ))
{
RECTL_vInflateRect(&rcWindow, -UserGetSystemMetrics(SM_CXFRAME), -UserGetSystemMetrics(SM_CYFRAME) );
if (!IntPtInRect(&rcWindow, pt))
if (!RECTL_bPointInRect(&rcWindow, pt.x, pt.y ))
{
/* Check top sizing border */
if (pt.y < rcWindow.top)
@ -297,7 +297,7 @@ GetNCHitEx(PWND pWnd, POINT pt)
RECTL_vInflateRect(&rcWindow, -UserGetSystemMetrics(SM_CXDLGFRAME), -UserGetSystemMetrics(SM_CYDLGFRAME));
else if (HAS_THINFRAME( Style, ExStyle ))
RECTL_vInflateRect(&rcWindow, -UserGetSystemMetrics(SM_CXBORDER), -UserGetSystemMetrics(SM_CYBORDER));
if (!IntPtInRect( &rcWindow, pt )) return HTBORDER;
if (!RECTL_bPointInRect( &rcWindow, pt.x, pt.y )) return HTBORDER;
}
/* Check caption */
@ -308,7 +308,7 @@ GetNCHitEx(PWND pWnd, POINT pt)
rcWindow.top += UserGetSystemMetrics(SM_CYSMCAPTION) - 1;
else
rcWindow.top += UserGetSystemMetrics(SM_CYCAPTION) - 1;
if (!IntPtInRect( &rcWindow, pt ))
if (!RECTL_bPointInRect( &rcWindow, pt.x, pt.y ))
{
BOOL min_or_max_box = (Style & WS_MAXIMIZEBOX) ||
(Style & WS_MINIMIZEBOX);
@ -393,7 +393,7 @@ GetNCHitEx(PWND pWnd, POINT pt)
rcClient.left -= UserGetSystemMetrics(SM_CXVSCROLL);
else
rcClient.right += UserGetSystemMetrics(SM_CXVSCROLL);
if (IntPtInRect( &rcClient, pt )) return HTVSCROLL;
if (RECTL_bPointInRect( &rcClient, pt.x, pt.y )) return HTVSCROLL;
}
/* Check horizontal scroll bar */
@ -401,7 +401,7 @@ GetNCHitEx(PWND pWnd, POINT pt)
if (Style & WS_HSCROLL)
{
rcClient.bottom += UserGetSystemMetrics(SM_CYHSCROLL);
if (IntPtInRect( &rcClient, pt ))
if (RECTL_bPointInRect( &rcClient, pt.x, pt.y ))
{
/* Check size box */
if ((Style & WS_VSCROLL) &&

View file

@ -13,29 +13,6 @@
DBG_DEFAULT_CHANNEL(UserMenu);
PMENU_OBJECT FASTCALL
IntGetSystemMenu(PWND Window, BOOL bRevert, BOOL RetMenu);
/* STATIC FUNCTION ***********************************************************/
static
BOOL FASTCALL
UserMenuItemInfo(
PMENU_OBJECT Menu,
UINT Item,
BOOL ByPosition,
PROSMENUITEMINFO UnsafeItemInfo,
BOOL SetOrGet);
static
BOOL FASTCALL
UserMenuInfo(
PMENU_OBJECT Menu,
PROSMENUINFO UnsafeMenuInfo,
BOOL SetOrGet);
/* INTERNAL ******************************************************************/
/* maximum number of menu items a menu can contain */
@ -79,25 +56,6 @@ UserMenuInfo(
} \
}
#define InRect(r, x, y) \
( ( ((r).right >= x)) && \
( ((r).left <= x)) && \
( ((r).bottom >= y)) && \
( ((r).top <= y)) )
INIT_FUNCTION
NTSTATUS
NTAPI
InitMenuImpl(VOID)
{
return(STATUS_SUCCESS);
}
NTSTATUS FASTCALL
CleanupMenuImpl(VOID)
{
return(STATUS_SUCCESS);
}
PMENU_OBJECT FASTCALL UserGetMenuObject(HMENU hMenu)
{
@ -1249,19 +1207,6 @@ co_IntTrackPopupMenu(PMENU_OBJECT Menu, PWND Window,
return FALSE;
}
BOOL FASTCALL
IntSetMenuItemRect(PMENU_OBJECT Menu, UINT Item, BOOL fByPos, RECTL *rcRect)
{
PMENU_ITEM mi;
if(IntGetMenuItemByFlag(Menu, Item, (fByPos ? MF_BYPOSITION : MF_BYCOMMAND),
NULL, &mi, NULL) > -1)
{
mi->Rect = *rcRect;
return TRUE;
}
return FALSE;
}
/*!
* Internal function. Called when the process is destroyed to free the remaining menu handles.
@ -2239,7 +2184,7 @@ NtUserMenuItemFromPoint(
mi = Menu->MenuItemList;
for (i = 0; NULL != mi; i++)
{
if (InRect(mi->Rect, X, Y))
if (RECTL_bPointInRect(&(mi->Rect), X, Y))
{
break;
}

View file

@ -1771,7 +1771,7 @@ NtUserDragDetect(
POINT tmp;
tmp.x = (short)LOWORD(msg.lParam);
tmp.y = (short)HIWORD(msg.lParam);
if( !IntPtInRect( &rect, tmp ) )
if( !RECTL_bPointInRect( &rect, tmp.x, tmp.y ) )
{
co_UserSetCapture(NULL);
RETURN( TRUE);

View file

@ -1963,8 +1963,11 @@ MsqCleanupMessageQueue(PUSER_MESSAGE_QUEUE MessageQueue)
}
// Clear it all out.
pti->pcti->fsWakeBits = 0;
pti->pcti->fsChangeBits = 0;
if(pti->pcti)
{
pti->pcti->fsWakeBits = 0;
pti->pcti->fsChangeBits = 0;
}
MessageQueue->nCntsQBits[QSRosKey] = 0;
MessageQueue->nCntsQBits[QSRosMouseMove] = 0;

View file

@ -474,3 +474,82 @@ UserReferenceObjectByHandle(HANDLE handle, USER_OBJECT_TYPE type)
}
return object;
}
/*
* NtUserValidateHandleSecure
*
* Status
* @implemented
*/
BOOL
APIENTRY
NtUserValidateHandleSecure(
HANDLE handle,
BOOL Restricted)
{
if(!Restricted)
{
UINT uType;
{
PUSER_HANDLE_ENTRY entry;
if (!(entry = handle_to_entry(gHandleTable, handle )))
{
EngSetLastError(ERROR_INVALID_HANDLE);
return FALSE;
}
uType = entry->type;
}
switch (uType)
{
case otWindow:
{
PWND Window;
if ((Window = UserGetWindowObject((HWND) handle))) return TRUE;
return FALSE;
}
case otMenu:
{
PMENU_OBJECT Menu;
if ((Menu = UserGetMenuObject((HMENU) handle))) return TRUE;
return FALSE;
}
case otAccel:
{
PACCELERATOR_TABLE Accel;
if ((Accel = UserGetAccelObject((HACCEL) handle))) return TRUE;
return FALSE;
}
case otCursorIcon:
{
PCURICON_OBJECT Cursor;
if ((Cursor = UserGetCurIconObject((HCURSOR) handle))) return TRUE;
return FALSE;
}
case otHook:
{
PHOOK Hook;
if ((Hook = IntGetHookObject((HHOOK) handle))) return TRUE;
return FALSE;
}
case otMonitor:
{
PMONITOR Monitor;
if ((Monitor = UserGetMonitorObject((HMONITOR) handle))) return TRUE;
return FALSE;
}
case otCallProc:
{
WNDPROC_INFO Proc;
return UserGetCallProcInfo( handle, &Proc );
}
default:
EngSetLastError(ERROR_INVALID_HANDLE);
}
}
else
{ /* Is handle entry restricted? */
STUB
}
return FALSE;
}

View file

@ -325,7 +325,7 @@ SystemTimerProc(HWND hwnd,
pWnd == pDesk->spwndTrack )
{
Point = gpsi->ptCursor;
if ( IntPtInRect(&pDesk->rcMouseHover, Point) )
if ( RECTL_bPointInRect(&pDesk->rcMouseHover, Point.x, Point.y) )
{
if (pDesk->htEx == HTCLIENT) // In a client area.
{

View file

@ -16,34 +16,6 @@ DBG_DEFAULT_CHANNEL(UserWnd);
#define POINT_IN_RECT(p, r) (((r.bottom >= p.y) && (r.top <= p.y))&&((r.left <= p.x )&&( r.right >= p.x )))
/* PRIVATE FUNCTIONS **********************************************************/
/*
* InitWindowImpl
*
* Initialize windowing implementation.
*/
INIT_FUNCTION
NTSTATUS
NTAPI
InitWindowImpl(VOID)
{
return STATUS_SUCCESS;
}
/*
* CleanupWindowImpl
*
* Cleanup windowing implementation.
*/
NTSTATUS FASTCALL
CleanupWindowImpl(VOID)
{
return STATUS_SUCCESS;
}
/* HELPER FUNCTIONS ***********************************************************/
BOOL FASTCALL UserUpdateUiState(PWND Wnd, WPARAM wParam)
@ -946,35 +918,6 @@ IntIsChildWindow(PWND Parent, PWND BaseWindow)
return(FALSE);
}
BOOL FASTCALL
IntIsWindowVisible(PWND BaseWindow)
{
PWND Window;
Window = BaseWindow;
while(Window)
{
if(!(Window->style & WS_CHILD))
{
break;
}
if(!(Window->style & WS_VISIBLE))
{
return FALSE;
}
Window = Window->spwndParent;
}
if(Window && Window->style & WS_VISIBLE)
{
return TRUE;
}
return FALSE;
}
/*
link the window into siblings list
children and parent are kept in place.
@ -4198,84 +4141,4 @@ IntShowOwnedPopups(PWND OwnerWnd, BOOL fShow )
return TRUE;
}
/*
* NtUserValidateHandleSecure
*
* Status
* @implemented
*/
BOOL
APIENTRY
NtUserValidateHandleSecure(
HANDLE handle,
BOOL Restricted)
{
if(!Restricted)
{
UINT uType;
{
PUSER_HANDLE_ENTRY entry;
if (!(entry = handle_to_entry(gHandleTable, handle )))
{
EngSetLastError(ERROR_INVALID_HANDLE);
return FALSE;
}
uType = entry->type;
}
switch (uType)
{
case otWindow:
{
PWND Window;
if ((Window = UserGetWindowObject((HWND) handle))) return TRUE;
return FALSE;
}
case otMenu:
{
PMENU_OBJECT Menu;
if ((Menu = UserGetMenuObject((HMENU) handle))) return TRUE;
return FALSE;
}
case otAccel:
{
PACCELERATOR_TABLE Accel;
if ((Accel = UserGetAccelObject((HACCEL) handle))) return TRUE;
return FALSE;
}
case otCursorIcon:
{
PCURICON_OBJECT Cursor;
if ((Cursor = UserGetCurIconObject((HCURSOR) handle))) return TRUE;
return FALSE;
}
case otHook:
{
PHOOK Hook;
if ((Hook = IntGetHookObject((HHOOK) handle))) return TRUE;
return FALSE;
}
case otMonitor:
{
PMONITOR Monitor;
if ((Monitor = UserGetMonitorObject((HMONITOR) handle))) return TRUE;
return FALSE;
}
case otCallProc:
{
WNDPROC_INFO Proc;
return UserGetCallProcInfo( handle, &Proc );
}
default:
EngSetLastError(ERROR_INVALID_HANDLE);
}
}
else
{ /* Is handle entry restricted? */
STUB
}
return FALSE;
}
/* EOF */

View file

@ -68,38 +68,6 @@ IntGetClientOrigin(PWND Window OPTIONAL, LPPOINT Point)
return TRUE;
}
BOOL FASTCALL
UserGetClientOrigin(PWND Window, LPPOINT Point)
{
BOOL Ret;
POINT pt;
NTSTATUS Status;
if(!Point)
{
EngSetLastError(ERROR_INVALID_PARAMETER);
return FALSE;
}
Ret = IntGetClientOrigin(Window, &pt);
if(!Ret)
{
EngSetLastError(ERROR_INVALID_WINDOW_HANDLE);
return FALSE;
}
Status = MmCopyToCaller(Point, &pt, sizeof(POINT));
if(!NT_SUCCESS(Status))
{
SetLastNtError(Status);
return FALSE;
}
return Ret;
}
/*******************************************************************
* can_activate_window

View file

@ -510,47 +510,6 @@ NtGdiGetPixel(HDC hDC, INT XPos, INT YPos)
return Result;
}
LONG APIENTRY
IntGetBitmapBits(
PSURFACE psurf,
DWORD Bytes,
OUT PBYTE Bits)
{
LONG ret;
ASSERT(Bits);
/* Don't copy more bytes than the buffer has */
Bytes = min(Bytes, psurf->SurfObj.cjBits);
#if 0
/* FIXME: Call DDI CopyBits here if available */
if (psurf->DDBitmap)
{
DPRINT("Calling device specific BitmapBits\n");
if (psurf->DDBitmap->funcs->pBitmapBits)
{
ret = psurf->DDBitmap->funcs->pBitmapBits(hbitmap,
bits,
count,
DDB_GET);
}
else
{
ERR_(bitmap)("BitmapBits == NULL??\n");
ret = 0;
}
}
else
#endif
{
RtlCopyMemory(Bits, psurf->SurfObj.pvBits, Bytes);
ret = Bytes;
}
return ret;
}
VOID
FASTCALL
UnsafeGetBitmapBits(

View file

@ -125,7 +125,7 @@ BRUSH_vFreeBrushAttr(PBRUSH pbr)
}
BOOL
INTERNAL_CALL
NTAPI
BRUSH_Cleanup(PVOID ObjectBody)
{
PBRUSH pbrush = (PBRUSH)ObjectBody;

View file

@ -351,7 +351,7 @@ DC_vInitDc(
}
BOOL
INTERNAL_CALL
NTAPI
DC_Cleanup(PVOID ObjectBody)
{
PDC pdc = (PDC)ObjectBody;

View file

@ -70,7 +70,7 @@ int FASTCALL IntFillRect(DC *dc, INT XLeft, INT YLeft, INT Width, INT Height, PB
static
POINT
INTERNAL_CALL
NTAPI
app_new_point(int x, int y)
{
POINT p;
@ -82,7 +82,7 @@ app_new_point(int x, int y)
static
Rect
INTERNAL_CALL
NTAPI
rect(int x, int y, int width, int height)
{
Rect r;
@ -122,7 +122,7 @@ rect(int x, int y, int width, int height)
*/
static
int
INTERNAL_CALL
NTAPI
app_draw_ellipse(DC *g, Rect r, PBRUSH pbrush)
{
/* Outer ellipse: e(x,y) = b*b*x*x + a*a*y*y - a*a*b*b */

View file

@ -87,7 +87,7 @@ ULONG gulFirstFree;
ULONG gulFirstUnused;
static PPAGED_LOOKASIDE_LIST gpaLookasideList;
static BOOL INTERNAL_CALL GDIOBJ_Cleanup(PVOID ObjectBody);
static BOOL NTAPI GDIOBJ_Cleanup(PVOID ObjectBody);
static const
GDICLEANUPPROC
@ -130,7 +130,7 @@ apfnCleanup[] =
/* INTERNAL FUNCTIONS ********************************************************/
static
BOOL INTERNAL_CALL
BOOL NTAPI
GDIOBJ_Cleanup(PVOID ObjectBody)
{
return TRUE;
@ -1175,7 +1175,7 @@ NtGdiDeleteClientObj(
PGDI_HANDLE_TABLE GdiHandleTable = NULL;
PGDIOBJ INTERNAL_CALL
PGDIOBJ NTAPI
GDIOBJ_ShareLockObj(HGDIOBJ hObj, DWORD ExpectedType)
{
if (ExpectedType == GDI_OBJECT_TYPE_DONTCARE)
@ -1187,7 +1187,7 @@ GDIOBJ_ShareLockObj(HGDIOBJ hObj, DWORD ExpectedType)
// That shouldn't be a problem, since we don't have any processes yet,
// that could delete the handle
BOOL
INTERNAL_CALL
NTAPI
GDIOBJ_ConvertToStockObj(HGDIOBJ *phObj)
{
PENTRY pentry;
@ -1220,7 +1220,7 @@ GDIOBJ_ConvertToStockObj(HGDIOBJ *phObj)
return TRUE;
}
POBJ INTERNAL_CALL
POBJ NTAPI
GDIOBJ_AllocObjWithHandle(ULONG ObjectType, ULONG cjSize)
{
POBJ pobj;
@ -1245,7 +1245,7 @@ GDIOBJ_AllocObjWithHandle(ULONG ObjectType, ULONG cjSize)
return pobj;
}
PVOID INTERNAL_CALL
PVOID NTAPI
GDI_MapHandleTable(PEPROCESS pProcess)
{
PVOID pvMappedView = NULL;
@ -1275,7 +1275,7 @@ GDI_MapHandleTable(PEPROCESS pProcess)
return pvMappedView;
}
BOOL INTERNAL_CALL
BOOL NTAPI
GDI_CleanupForProcess(struct _EPROCESS *Process)
{
PENTRY pentry;

View file

@ -285,7 +285,7 @@ PALETTE_AllocPaletteIndexedRGB(ULONG NumColors,
return NewPalette;
}
BOOL INTERNAL_CALL
BOOL NTAPI
PALETTE_Cleanup(PVOID ObjectBody)
{
PPALETTE pPal = (PPALETTE)ObjectBody;

View file

@ -60,6 +60,20 @@ VOID FASTCALL IntGetCurrentPositionEx(PDC dc, LPPOINT pt);
/***********************************************************************
* Internal functions
*/
/* PATH_DestroyGdiPath
*
* Destroys a GdiPath structure (frees the memory in the arrays).
*/
VOID
FASTCALL
PATH_DestroyGdiPath ( PPATH pPath )
{
ASSERT(pPath!=NULL);
if (pPath->pPoints) ExFreePoolWithTag(pPath->pPoints, TAG_PATH);
if (pPath->pFlags) ExFreePoolWithTag(pPath->pFlags, TAG_PATH);
}
BOOL
FASTCALL
@ -185,20 +199,6 @@ PATH_InitGdiPath ( PPATH pPath )
pPath->numEntriesAllocated=0;
}
/* PATH_DestroyGdiPath
*
* Destroys a GdiPath structure (frees the memory in the arrays).
*/
VOID
FASTCALL
PATH_DestroyGdiPath ( PPATH pPath )
{
ASSERT(pPath!=NULL);
if (pPath->pPoints) ExFreePoolWithTag(pPath->pPoints, TAG_PATH);
if (pPath->pFlags) ExFreePoolWithTag(pPath->pFlags, TAG_PATH);
}
/* PATH_AssignGdiPath
*
* Copies the GdiPath structure "pPathSrc" to "pPathDest". A deep copy is

View file

@ -2271,7 +2271,7 @@ IntSysCreateRectRgn(INT LeftRect, INT TopRect, INT RightRect, INT BottomRect)
return hrgn;
}
BOOL INTERNAL_CALL
BOOL NTAPI
REGION_Cleanup(PVOID ObjectBody)
{
PROSRGNDATA pRgn = (PROSRGNDATA)ObjectBody;

View file

@ -111,7 +111,7 @@ HintFromAccel(ULONG flAccel)
/** Internal functions ********************************************************/
ULONG
INTERNAL_CALL
NTAPI
XFORMOBJ_UpdateAccel(
IN XFORMOBJ *pxo)
{
@ -152,7 +152,7 @@ XFORMOBJ_UpdateAccel(
ULONG
INTERNAL_CALL
NTAPI
XFORMOBJ_iSetXform(
OUT XFORMOBJ *pxo,
IN const XFORML *pxform)
@ -186,7 +186,7 @@ XFORMOBJ_iSetXform(
* | efDx efDy 1 |
*/
ULONG
INTERNAL_CALL
NTAPI
XFORMOBJ_iCombine(
IN XFORMOBJ *pxo,
IN XFORMOBJ *pxo1,
@ -218,7 +218,7 @@ XFORMOBJ_iCombine(
ULONG
INTERNAL_CALL
NTAPI
XFORMOBJ_iCombineXform(
IN XFORMOBJ *pxo,
IN XFORMOBJ *pxo1,
@ -246,7 +246,7 @@ XFORMOBJ_iCombineXform(
* A^-1 = 1/(a*d - b*c) * (a22,-a12,a21,-a11)
*/
ULONG
INTERNAL_CALL
NTAPI
XFORMOBJ_iInverse(
OUT XFORMOBJ *pxoDst,
IN XFORMOBJ *pxoSrc)
@ -285,7 +285,7 @@ XFORMOBJ_iInverse(
BOOL
INTERNAL_CALL
NTAPI
XFORMOBJ_bXformFixPoints(
IN XFORMOBJ *pxo,
IN ULONG cPoints,

View file

@ -37,6 +37,7 @@ typedef struct _SECURITY_ATTRIBUTES SECURITY_ATTRIBUTES, *LPSECURITY_ATTRIBUTES;
#define STARTF_USEPOSITION 4
#include <stdarg.h>
#include <windef.h>
#include <math.h>
/* Avoid type casting, by defining RECT to RECTL */
#define RECT RECTL
@ -76,6 +77,10 @@ typedef struct _SECURITY_ATTRIBUTES SECURITY_ATTRIBUTES, *LPSECURITY_ATTRIBUTES;
/* Undocumented user definitions */
#include <undocuser.h>
/* Freetype headers*/
#include <ft2build.h>
#include <freetype/freetype.h>
/* Internal Win32K Header */
#include "include/win32kp.h"