Start using gdi shared handle table.

svn path=/trunk/; revision=31229
This commit is contained in:
James Tabor 2007-12-15 08:08:11 +00:00
parent d7abb13de2
commit 9c07113163
4 changed files with 7 additions and 3 deletions

View file

@ -10,9 +10,11 @@
/* DATA **********************************************************************/ /* DATA **********************************************************************/
extern PGDI_TABLE_ENTRY GdiHandleTable; extern PGDI_TABLE_ENTRY GdiHandleTable;
extern PGDI_SHARED_HANDLE_TABLE GdiSharedHandleTable;
extern HANDLE hProcessHeap; extern HANDLE hProcessHeap;
extern HANDLE CurrentProcessId; extern HANDLE CurrentProcessId;
extern DWORD GDI_BatchLimit; extern DWORD GDI_BatchLimit;
extern PDEVCAPS GdiDevCaps;
typedef INT typedef INT
(CALLBACK* EMFPLAYPROC)( (CALLBACK* EMFPLAYPROC)(

View file

@ -11,6 +11,7 @@
extern HGDIOBJ stock_objects[]; extern HGDIOBJ stock_objects[];
BOOL SetStockObjects = FALSE; BOOL SetStockObjects = FALSE;
PDEVCAPS GdiDevCaps = NULL;
/* /*
* GDI32.DLL doesn't have an entry point. The initialization is done by a call * GDI32.DLL doesn't have an entry point. The initialization is done by a call
@ -36,6 +37,8 @@ GdiProcessSetup (VOID)
/* map the gdi handle table to user space */ /* map the gdi handle table to user space */
GdiHandleTable = NtCurrentTeb()->ProcessEnvironmentBlock->GdiSharedHandleTable; GdiHandleTable = NtCurrentTeb()->ProcessEnvironmentBlock->GdiSharedHandleTable;
GdiSharedHandleTable = NtCurrentTeb()->ProcessEnvironmentBlock->GdiSharedHandleTable;
GdiDevCaps = &GdiSharedHandleTable->DevCaps;
CurrentProcessId = NtCurrentTeb()->Cid.UniqueProcess; CurrentProcessId = NtCurrentTeb()->Cid.UniqueProcess;
GDI_BatchLimit = (DWORD) NtCurrentTeb()->ProcessEnvironmentBlock->GdiDCAttributeList; GDI_BatchLimit = (DWORD) NtCurrentTeb()->ProcessEnvironmentBlock->GdiDCAttributeList;
} }

View file

@ -406,7 +406,6 @@ DdGetScanLine(LPDDHAL_GETSCANLINEDATA pGetScanLine)
} }
/* PRIVATE FUNCTIONS *********************************************************/ /* PRIVATE FUNCTIONS *********************************************************/
static ULONG RemberDdQueryDisplaySettingsUniquenessID = 0;
BOOL BOOL
WINAPI WINAPI
@ -987,8 +986,7 @@ ULONG
STDCALL STDCALL
DdQueryDisplaySettingsUniqueness() DdQueryDisplaySettingsUniqueness()
{ {
/* FIXME share memory */ return GdiSharedHandleTable->flDeviceUniq;
return RemberDdQueryDisplaySettingsUniquenessID;
} }
/* /*

View file

@ -29,6 +29,7 @@
#include "precomp.h" #include "precomp.h"
PGDI_TABLE_ENTRY GdiHandleTable = NULL; PGDI_TABLE_ENTRY GdiHandleTable = NULL;
PGDI_SHARED_HANDLE_TABLE GdiSharedHandleTable = NULL;
HANDLE CurrentProcessId = NULL; HANDLE CurrentProcessId = NULL;
DWORD GDI_BatchLimit = 1; DWORD GDI_BatchLimit = 1;