- In the process of rewriting IntGdiCreateDisplayDC, making it an intermediate level support function for IntGdiCreateDC.

svn path=/trunk/; revision=41744
This commit is contained in:
James Tabor 2009-07-02 19:09:32 +00:00
parent d5fa564670
commit a9a2a4be8f
4 changed files with 25 additions and 21 deletions

View file

@ -110,22 +110,17 @@ 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);
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);
#define IntIsActiveDesktop(Desktop) \
((Desktop)->WindowStation->ActiveDesktop == (Desktop))

View file

@ -698,20 +698,7 @@ HDC
APIENTRY
DxEngGetDesktopDC(ULONG DcType, BOOL EmptyDC, BOOL ValidatehWnd)
{
PWINDOW_OBJECT DesktopObject = 0;
HDC DesktopHDC = 0;
if (DcType == DC_TYPE_DIRECT)
{
DesktopObject = UserGetDesktopWindow();
DesktopHDC = (HDC)UserGetWindowDC(DesktopObject);
}
else
{
UNIMPLEMENTED;
}
return DesktopHDC;
return UserGetDesktopDC(DcType, EmptyDC, ValidatehWnd);
}
/************************************************************************/

View file

@ -618,6 +618,27 @@ BOOL FASTCALL IntDesktopUpdatePerUserSettings(BOOL bEnable)
/* PUBLIC FUNCTIONS ***********************************************************/
HDC FASTCALL
UserGetDesktopDC(ULONG DcType, BOOL EmptyDC, BOOL ValidatehWnd)
{
PWINDOW_OBJECT DesktopObject = 0;
HDC DesktopHDC = 0;
if (DcType == DC_TYPE_DIRECT)
{
DesktopObject = UserGetDesktopWindow();
DesktopHDC = (HDC)UserGetWindowDC(DesktopObject);
}
else
{
HDEV hDev;
hDev = (HDEV)pPrimarySurface;
DesktopHDC = IntGdiCreateDisplayDC(hDev, DcType, EmptyDC);
}
return DesktopHDC;
}
VOID APIENTRY
UserRedrawDesktop()
{

View file

@ -432,6 +432,7 @@ IntGdiCreateDisplayDC(HDEV hDev, ULONG DcType, BOOL EmptyDC)
//
// If NULL, first time through! Build the default (was window) dc!
// Setup clean DC state for the system.
//
if (hDC && !defaultDCstate) // Ultra HAX! Dedicated to GvG!
{ // This is a cheesy way to do this.