mirror of
https://github.com/reactos/reactos.git
synced 2024-12-27 09:34:43 +00:00
Set ownership to NULL for both cursor and mask bitmaps
svn path=/trunk/; revision=12258
This commit is contained in:
parent
026cdb6db3
commit
b41e30eb6d
1 changed files with 8 additions and 11 deletions
|
@ -16,7 +16,7 @@
|
|||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
*/
|
||||
/* $Id: cursoricon.c,v 1.3 2004/12/18 23:55:26 royce Exp $ */
|
||||
/* $Id: cursoricon.c,v 1.4 2004/12/20 21:34:23 gvg Exp $ */
|
||||
#include <w32k.h>
|
||||
|
||||
PCURICON_OBJECT FASTCALL
|
||||
|
@ -419,7 +419,7 @@ NtUserCreateCursorIconHandle(PICONINFO IconInfo, BOOL Indirect)
|
|||
{
|
||||
return (HANDLE)0;
|
||||
}
|
||||
|
||||
|
||||
CurIconObject = IntCreateCurIconHandle(WinStaObject);
|
||||
if(CurIconObject)
|
||||
{
|
||||
|
@ -443,16 +443,13 @@ NtUserCreateCursorIconHandle(PICONINFO IconInfo, BOOL Indirect)
|
|||
BITMAPOBJ_UnlockBitmap(CurIconObject->IconInfo.hbmColor);
|
||||
GDIOBJ_SetOwnership(CurIconObject->IconInfo.hbmColor, NULL);
|
||||
}
|
||||
else
|
||||
if(CurIconObject->IconInfo.hbmMask &&
|
||||
(bmp = BITMAPOBJ_LockBitmap(CurIconObject->IconInfo.hbmMask)))
|
||||
{
|
||||
if(CurIconObject->IconInfo.hbmMask &&
|
||||
(bmp = BITMAPOBJ_LockBitmap(CurIconObject->IconInfo.hbmMask)))
|
||||
{
|
||||
CurIconObject->Size.cx = bmp->SurfObj.sizlBitmap.cx;
|
||||
CurIconObject->Size.cy = bmp->SurfObj.sizlBitmap.cy / 2;
|
||||
BITMAPOBJ_UnlockBitmap(CurIconObject->IconInfo.hbmMask);
|
||||
GDIOBJ_SetOwnership(CurIconObject->IconInfo.hbmMask, NULL);
|
||||
}
|
||||
CurIconObject->Size.cx = bmp->SurfObj.sizlBitmap.cx;
|
||||
CurIconObject->Size.cy = bmp->SurfObj.sizlBitmap.cy / 2;
|
||||
BITMAPOBJ_UnlockBitmap(CurIconObject->IconInfo.hbmMask);
|
||||
GDIOBJ_SetOwnership(CurIconObject->IconInfo.hbmMask, NULL);
|
||||
}
|
||||
}
|
||||
else
|
||||
|
|
Loading…
Reference in a new issue