📄 dllmain.c
字号:
/*
* dllmain.c
*
* $Revision: 1.11 $
* $Author: jimtabor $
* $Date: 2006-10-17 22:55:28 -0500 (Tue, 17 Oct 2006) $
*
*/
#include "precomp.h"
/*
* GDI32.DLL doesn't have an entry point. The initialization is done by a call
* to GdiDllInitialize(). This call is done from the entry point of USER32.DLL.
*/
BOOL
WINAPI
DllMain (
HANDLE hDll,
DWORD dwReason,
LPVOID lpReserved
)
{
return TRUE;
}
VOID
WINAPI
GdiProcessSetup (VOID)
{
hProcessHeap = GetProcessHeap();
/* map the gdi handle table to user space */
GdiHandleTable = NtCurrentTeb()->ProcessEnvironmentBlock->GdiSharedHandleTable;
CurrentProcessId = NtCurrentTeb()->Cid.UniqueProcess;
GDI_BatchLimit = NtCurrentTeb()->GdiBatchCount;
}
/*
* @implemented
*/
BOOL
WINAPI
GdiDllInitialize (
HANDLE hDll,
DWORD dwReason,
LPVOID lpReserved
)
{
switch (dwReason)
{
case DLL_PROCESS_ATTACH:
GdiProcessSetup ();
break;
case DLL_THREAD_ATTACH:
break;
default:
return FALSE;
}
#if 0
/* FIXME: working teb handling needed */
NtCurrentTeb()->GdiTebBatch.Offset = 0;
NtCurrentTeb()->GdiBatchCount = 0;
#endif
return TRUE;
}
/* EOF */
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -