mirror of
https://github.com/reactos/reactos.git
synced 2025-02-24 09:25:10 +00:00
Fixup UnrealizeObject so it can return the correct state for a Brush Object.
svn path=/trunk/; revision=16640
This commit is contained in:
parent
a6fd14c5c8
commit
6f5624c2a4
1 changed files with 10 additions and 3 deletions
|
@ -594,14 +594,14 @@ NtGdiUnrealizeObject(HGDIOBJ hgdiobj)
|
|||
|
||||
GDIOBJHDR * ptr;
|
||||
DWORD objectType;
|
||||
|
||||
BOOL Ret = FALSE;
|
||||
UNIMPLEMENTED;
|
||||
|
||||
ptr = GDIOBJ_LockObj(hgdiobj, GDI_OBJECT_TYPE_DONTCARE);
|
||||
if (ptr == 0)
|
||||
{
|
||||
SetLastWin32Error(ERROR_INVALID_HANDLE);
|
||||
return FALSE;
|
||||
return Ret;
|
||||
}
|
||||
objectType = GDIOBJ_GetObjectType(hgdiobj);
|
||||
switch(objectType)
|
||||
|
@ -612,9 +612,16 @@ NtGdiUnrealizeObject(HGDIOBJ hgdiobj)
|
|||
DPRINT1("GDI_OBJECT_TYPE_PALETTE\n");
|
||||
break;
|
||||
}
|
||||
/*
|
||||
msdn.microsoft.com,
|
||||
"Windows 2000/XP: If hgdiobj is a brush, UnrealizeObject does nothing,
|
||||
and the function returns TRUE. Use SetBrushOrgEx to set the origin of
|
||||
a brush."
|
||||
*/
|
||||
case GDI_OBJECT_TYPE_BRUSH:
|
||||
{
|
||||
DPRINT1("GDI_OBJECT_TYPE_BRUSH\n");
|
||||
Ret = TRUE;
|
||||
break;
|
||||
}
|
||||
default:
|
||||
|
@ -623,7 +630,7 @@ NtGdiUnrealizeObject(HGDIOBJ hgdiobj)
|
|||
}
|
||||
|
||||
GDIOBJ_UnlockObjByPtr(ptr);
|
||||
return FALSE;
|
||||
return Ret;
|
||||
}
|
||||
|
||||
BOOL STDCALL
|
||||
|
|
Loading…
Reference in a new issue