- Reordered IntGdiGet/SetDCState and separated the copy sections.
authorJames Tabor <james.tabor@reactos.org>
Sat, 8 Sep 2007 01:05:27 +0000 (01:05 +0000)
committerJames Tabor <james.tabor@reactos.org>
Sat, 8 Sep 2007 01:05:27 +0000 (01:05 +0000)
- When creating DCE for window handles, allocate a DC structure for the default window DC.
- Return Dhpdev if not zero for NtGdiOpenDCW.
- Reordered the DC object.

svn path=/trunk/; revision=28932

reactos/subsystems/win32/win32k/include/bitmaps.h
reactos/subsystems/win32/win32k/include/brush.h
reactos/subsystems/win32/win32k/include/gdiobj.h
reactos/subsystems/win32/win32k/include/palette.h
reactos/subsystems/win32/win32k/include/region.h
reactos/subsystems/win32/win32k/include/text.h

index e8e78b4..8a4ba70 100644 (file)
@@ -5,6 +5,11 @@
 /* GDI logical bitmap object */
 typedef struct _BITMAPOBJ
 {
+  HGDIOBJ     hHmgr;
+  PVOID       pvEntry;
+  ULONG       lucExcLock;
+  ULONG       Tid;
+
   SURFOBJ     SurfObj;
   FLONG              flHooks;
   FLONG       flFlags;
index 2b9db88..d948ea6 100644 (file)
@@ -23,6 +23,11 @@ typedef struct
 
 typedef struct
 {
+   HGDIOBJ     hHmgr;
+   PVOID       pvEntry;
+   ULONG       lucExcLock;
+   ULONG       Tid;
+
    ULONG ulStyle;
    HBITMAP hbmPattern;
    HANDLE hbmClient;
index 591f03d..5e2d4ad 100644 (file)
@@ -43,6 +43,19 @@ typedef struct _GDIOBJHDR
 #endif
 } GDIOBJHDR, *PGDIOBJHDR;
 
+//
+// Every GDI Object must have this standard type of header. 
+// It's for thread locking.
+// This header is standalone, used only in gdiobj.c.
+//
+typedef struct _GDIOBJEMPTYHDR
+{
+  HGDIOBJ     hHmgr;
+  PVOID       pvEntry;
+  ULONG       lucExcLock;
+  ULONG       Tid;
+} GDIOBJEMPTYHDR, *PGDIOBJEMPTYHDR;
+
 BOOL    INTERNAL_CALL GDIOBJ_OwnedByCurrentProcess(PGDI_HANDLE_TABLE HandleTable, HGDIOBJ ObjectHandle);
 void    INTERNAL_CALL GDIOBJ_SetOwnership(PGDI_HANDLE_TABLE HandleTable, HGDIOBJ ObjectHandle, PEPROCESS Owner);
 void    INTERNAL_CALL GDIOBJ_CopyOwnership(PGDI_HANDLE_TABLE HandleTable, HGDIOBJ CopyFrom, HGDIOBJ CopyTo);
index 8430d64..9ccdc2d 100644 (file)
@@ -16,6 +16,11 @@ typedef struct {
 } ColorShifts;
 
 typedef struct _PALGDI {
+  HGDIOBJ     hHmgr;
+  PVOID       pvEntry;
+  ULONG       lucExcLock;
+  ULONG       Tid;
+
   PALOBJ PalObj;
   XLATEOBJ *logicalToSystem;
   HPALETTE Self;
index 09694e3..0386d3b 100644 (file)
@@ -6,6 +6,11 @@
 
 /* Internal region data. Can't use RGNDATA structure because buffer is allocated statically */
 typedef struct _ROSRGNDATA {
+  HGDIOBJ     hHmgr;
+  PVOID       pvEntry;
+  ULONG       lucExcLock;
+  ULONG       Tid;
+
   RGNDATAHEADER rdh;
   PRECT         Buffer;
 } ROSRGNDATA, *PROSRGNDATA, *LPROSRGNDATA;
index a3f1e15..c8c8a49 100644 (file)
@@ -6,6 +6,11 @@
 /* GDI logical font object */
 typedef struct
 {
+   HGDIOBJ     hHmgr;
+   PVOID       pvEntry;
+   ULONG       lucExcLock;
+   ULONG       Tid;
+
    ENUMLOGFONTEXDVW logfont;  //LOGFONTW   logfont;
    FONTOBJ    *Font;
    BOOLEAN Initialized; /* Don't reinitialize for each DC */