Author: jimtabor
Date: Wed Oct 31 05:48:54 2007
New Revision: 29993
URL:
http://svn.reactos.org/svn/reactos?rev=29993&view=rev
Log:
Fix gdi init so it can support batch. Used wrong limit source.
Modified:
trunk/reactos/dll/win32/gdi32/main/dllmain.c
trunk/reactos/include/ndk/pstypes.h
trunk/reactos/subsystems/win32/win32k/main/dllmain.c
Modified: trunk/reactos/dll/win32/gdi32/main/dllmain.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/gdi32/main/dllma…
==============================================================================
--- trunk/reactos/dll/win32/gdi32/main/dllmain.c (original)
+++ trunk/reactos/dll/win32/gdi32/main/dllmain.c Wed Oct 31 05:48:54 2007
@@ -37,7 +37,7 @@
/* map the gdi handle table to user space */
GdiHandleTable = NtCurrentTeb()->ProcessEnvironmentBlock->GdiSharedHandleTable;
CurrentProcessId = NtCurrentTeb()->Cid.UniqueProcess;
- GDI_BatchLimit = NtCurrentTeb()->GdiBatchCount;
+ GDI_BatchLimit = (DWORD)
NtCurrentTeb()->ProcessEnvironmentBlock->GdiDCAttributeList;
}
@@ -59,23 +59,21 @@
break;
case DLL_THREAD_ATTACH:
+ NtCurrentTeb()->GdiTebBatch.Offset = 0;
+ NtCurrentTeb()->GdiBatchCount = 0;
break;
default:
return FALSE;
}
-#if 0
- /* FIXME: working teb handling needed */
- NtCurrentTeb()->GdiTebBatch.Offset = 0;
- NtCurrentTeb()->GdiBatchCount = 0;
-#endif
// Very simple, the list will fill itself as it is needed.
if(!SetStockObjects)
{
RtlZeroMemory( &stock_objects, NB_STOCK_OBJECTS); //Assume Ros is dirty.
SetStockObjects = TRUE;
}
+
return TRUE;
}
Modified: trunk/reactos/include/ndk/pstypes.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/ndk/pstypes.h?rev=…
==============================================================================
--- trunk/reactos/include/ndk/pstypes.h (original)
+++ trunk/reactos/include/ndk/pstypes.h Wed Oct 31 05:48:54 2007
@@ -627,7 +627,7 @@
PVOID* ProcessHeaps;
PVOID GdiSharedHandleTable;
PVOID ProcessStarterHelper;
- PVOID GdiDCAttributeList;
+ ULONG GdiDCAttributeList;
#if (NTDDI_VERSION >= NTDDI_LONGHORN)
struct _RTL_CRITICAL_SECTION *LoaderLock;
#else
Modified: trunk/reactos/subsystems/win32/win32k/main/dllmain.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ma…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/main/dllmain.c (original)
+++ trunk/reactos/subsystems/win32/win32k/main/dllmain.c Wed Oct 31 05:48:54 2007
@@ -117,6 +117,7 @@
{
/* map the gdi handle table to user land */
Process->Peb->GdiSharedHandleTable = GDI_MapHandleTable(GdiTableSection,
Process);
+ Process->Peb->GdiDCAttributeList = 5;
}
/* setup process flags */