2 * GDI brush objects - win16drv
4 * Copyright 1997 John Harvey
9 #include "debugtools.h"
11 DEFAULT_DEBUG_CHANNEL(win16drv);
13 HBRUSH WIN16DRV_BRUSH_SelectObject( DC * dc, HBRUSH hbrush )
15 WIN16DRV_PDEVICE *physDev = (WIN16DRV_PDEVICE *)dc->physDev;
16 HBRUSH16 prevHandle = dc->hBrush;
20 if (!GetObject16( hbrush, sizeof(lBrush16), &lBrush16 )) return 0;
23 if ( physDev->BrushInfo )
25 TRACE("UnRealizing BrushInfo\n");
26 nSize = PRTDRV_RealizeObject (physDev->segptrPDEVICE, -DRVOBJ_BRUSH,
28 physDev->BrushInfo, 0);
32 nSize = PRTDRV_RealizeObject (physDev->segptrPDEVICE, DRVOBJ_BRUSH,
34 physDev->BrushInfo = HeapAlloc( GetProcessHeap(), 0, nSize );
38 nSize = PRTDRV_RealizeObject(physDev->segptrPDEVICE, DRVOBJ_BRUSH,
41 win16drv_SegPtr_TextXForm);