gdi32: Remove unneeded casts.
This commit is contained in:
parent
35d3f81e69
commit
d0d4c74e85
|
@ -471,7 +471,7 @@ BOOL16 WINAPI SetSolidBrush16(HBRUSH16 hBrush, COLORREF newColor )
|
||||||
BRUSHOBJ * brushPtr;
|
BRUSHOBJ * brushPtr;
|
||||||
BOOL16 res = FALSE;
|
BOOL16 res = FALSE;
|
||||||
|
|
||||||
TRACE("(hBrush %04x, newColor %08x)\n", hBrush, (DWORD)newColor);
|
TRACE("(hBrush %04x, newColor %08x)\n", hBrush, newColor);
|
||||||
if (!(brushPtr = (BRUSHOBJ *) GDI_GetObjPtr( HBRUSH_32(hBrush), BRUSH_MAGIC )))
|
if (!(brushPtr = (BRUSHOBJ *) GDI_GetObjPtr( HBRUSH_32(hBrush), BRUSH_MAGIC )))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
|
|
|
@ -832,7 +832,7 @@ INT WINAPI GetDIBits(
|
||||||
*dstbits++ = (BYTE)(((val >> 2) & 0xf8) | ((val >> 7) & 0x07));
|
*dstbits++ = (BYTE)(((val >> 2) & 0xf8) | ((val >> 7) & 0x07));
|
||||||
*dstbits++ = (BYTE)(((val >> 7) & 0xf8) | ((val >> 12) & 0x07));
|
*dstbits++ = (BYTE)(((val >> 7) & 0xf8) | ((val >> 12) & 0x07));
|
||||||
}
|
}
|
||||||
dstbits = (LPBYTE)(dbits+=dstwidthb);
|
dstbits = dbits+=dstwidthb;
|
||||||
srcbits = (LPWORD)(sbits+=srcwidthb);
|
srcbits = (LPWORD)(sbits+=srcwidthb);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -848,7 +848,7 @@ INT WINAPI GetDIBits(
|
||||||
|
|
||||||
case 32: /* 32 bpp srcDIB -> 24 bpp dstDIB */
|
case 32: /* 32 bpp srcDIB -> 24 bpp dstDIB */
|
||||||
{
|
{
|
||||||
LPBYTE srcbits = (LPBYTE)sbits;
|
LPBYTE srcbits = sbits;
|
||||||
|
|
||||||
width = min(srcwidth, dstwidth);
|
width = min(srcwidth, dstwidth);
|
||||||
for( y = 0; y < lines; y++) {
|
for( y = 0; y < lines; y++) {
|
||||||
|
@ -857,8 +857,8 @@ INT WINAPI GetDIBits(
|
||||||
*dstbits++ = *srcbits++;
|
*dstbits++ = *srcbits++;
|
||||||
*dstbits++ = *srcbits++;
|
*dstbits++ = *srcbits++;
|
||||||
}
|
}
|
||||||
dstbits=(LPBYTE)(dbits+=dstwidthb);
|
dstbits = dbits+=dstwidthb;
|
||||||
srcbits = (LPBYTE)(sbits+=srcwidthb);
|
srcbits = sbits+=srcwidthb;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -2545,7 +2545,7 @@ static INT CALLBACK cbEnhPaletteCopy( HDC a,
|
||||||
|
|
||||||
/* Update the passed data as a return code */
|
/* Update the passed data as a return code */
|
||||||
info->lpPe = NULL; /* Palettes were copied! */
|
info->lpPe = NULL; /* Palettes were copied! */
|
||||||
info->cEntries = (UINT)dwNumPalToCopy;
|
info->cEntries = dwNumPalToCopy;
|
||||||
|
|
||||||
return FALSE; /* That's all we need */
|
return FALSE; /* That's all we need */
|
||||||
}
|
}
|
||||||
|
@ -2576,7 +2576,7 @@ UINT WINAPI GetEnhMetaFilePaletteEntries( HENHMETAFILE hEmf,
|
||||||
if ( enhHeader->nPalEntries == 0 ) return 0;
|
if ( enhHeader->nPalEntries == 0 ) return 0;
|
||||||
|
|
||||||
/* Is the user requesting the number of palettes? */
|
/* Is the user requesting the number of palettes? */
|
||||||
if ( lpPe == NULL ) return (UINT)enhHeader->nPalEntries;
|
if ( lpPe == NULL ) return enhHeader->nPalEntries;
|
||||||
|
|
||||||
/* Copy cEntries worth of PALETTEENTRY structs into the buffer */
|
/* Copy cEntries worth of PALETTEENTRY structs into the buffer */
|
||||||
infoForCallBack.cEntries = cEntries;
|
infoForCallBack.cEntries = cEntries;
|
||||||
|
|
|
@ -3291,7 +3291,7 @@ static void GetEnumStructs(Face *face, LPENUMLOGFONTEXW pelf,
|
||||||
if(size) {
|
if(size) {
|
||||||
potm = HeapAlloc(GetProcessHeap(), 0, size);
|
potm = HeapAlloc(GetProcessHeap(), 0, size);
|
||||||
WineEngGetOutlineTextMetrics(font, size, potm);
|
WineEngGetOutlineTextMetrics(font, size, potm);
|
||||||
ptm = (TEXTMETRICW*)&potm->otmTextMetrics;
|
ptm = &potm->otmTextMetrics;
|
||||||
} else {
|
} else {
|
||||||
WineEngGetTextMetrics(font, &tm);
|
WineEngGetTextMetrics(font, &tm);
|
||||||
ptm = &tm;
|
ptm = &tm;
|
||||||
|
|
|
@ -1271,7 +1271,7 @@ static BOOL MF_Play_MetaExtTextOut(HDC hdc, METARECORD *mr)
|
||||||
{
|
{
|
||||||
dxx = (LPINT16)(sot+(((s1+1)>>1)*2));
|
dxx = (LPINT16)(sot+(((s1+1)>>1)*2));
|
||||||
dx = HeapAlloc( GetProcessHeap(), 0, s1*sizeof(INT));
|
dx = HeapAlloc( GetProcessHeap(), 0, s1*sizeof(INT));
|
||||||
if (dx) for (i = 0; i < s1; i++) dx[i] = (SHORT)dxx[i];
|
if (dx) for (i = 0; i < s1; i++) dx[i] = dxx[i];
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
TRACE("%s len: %d\n", sot, mr->rdSize);
|
TRACE("%s len: %d\n", sot, mr->rdSize);
|
||||||
|
|
|
@ -308,8 +308,6 @@ HMETAFILE16 WINAPI SetMetaFileBits16( HGLOBAL16 hMem )
|
||||||
HMETAFILE16 WINAPI SetMetaFileBitsBetter16( HMETAFILE16 hMeta )
|
HMETAFILE16 WINAPI SetMetaFileBitsBetter16( HMETAFILE16 hMeta )
|
||||||
{
|
{
|
||||||
if( IsValidMetaFile16( hMeta ) )
|
if( IsValidMetaFile16( hMeta ) )
|
||||||
return (HMETAFILE16)GlobalReAlloc16( hMeta, 0,
|
return GlobalReAlloc16( hMeta, 0, GMEM_SHARE | GMEM_NODISCARD | GMEM_MODIFY);
|
||||||
GMEM_SHARE | GMEM_NODISCARD | GMEM_MODIFY);
|
|
||||||
return (HMETAFILE16)0;
|
return (HMETAFILE16)0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -327,7 +327,7 @@ HPQ16 WINAPI CreatePQ16(INT16 size)
|
||||||
*/
|
*/
|
||||||
INT16 WINAPI DeletePQ16(HPQ16 hPQ)
|
INT16 WINAPI DeletePQ16(HPQ16 hPQ)
|
||||||
{
|
{
|
||||||
return GlobalFree16((HGLOBAL16)hPQ);
|
return GlobalFree16(hPQ);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**********************************************************************
|
/**********************************************************************
|
||||||
|
|
Loading…
Reference in New Issue