Module: wine Branch: master Commit: 092b892f54883f05d1603fc94038388f2e7e1fa2 URL: http://source.winehq.org/git/wine.git/?a=commit;h=092b892f54883f05d1603fc940...
Author: Michael Stefaniuc mstefani@redhat.de Date: Sat Oct 25 23:38:37 2008 +0200
comctl32: HGDIOBJ is interchangeable with other handle types so don't cast.
---
dlls/comctl32/comboex.c | 2 +- dlls/comctl32/imagelist.c | 4 ++-- dlls/comctl32/ipaddress.c | 2 +- dlls/comctl32/pager.c | 2 +- dlls/comctl32/tests/datetime.c | 2 +- dlls/comctl32/tests/imagelist.c | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/dlls/comctl32/comboex.c b/dlls/comctl32/comboex.c index 899760e..8d91992 100644 --- a/dlls/comctl32/comboex.c +++ b/dlls/comctl32/comboex.c @@ -348,7 +348,7 @@ static void COMBOEX_GetComboFontSize (COMBOEX_INFO *infoPtr, SIZE *size)
mydc = GetDC (0); /* why the entire screen???? */ nfont = (HFONT)SendMessageW (infoPtr->hwndCombo, WM_GETFONT, 0, 0); - ofont = (HFONT) SelectObject (mydc, nfont); + ofont = SelectObject (mydc, nfont); GetTextExtentPointW (mydc, strA, 1, size); SelectObject (mydc, ofont); ReleaseDC (0, mydc); diff --git a/dlls/comctl32/imagelist.c b/dlls/comctl32/imagelist.c index 8c2e95f..c2f4f7b 100644 --- a/dlls/comctl32/imagelist.c +++ b/dlls/comctl32/imagelist.c @@ -1212,7 +1212,7 @@ ImageList_DrawIndirect (IMAGELISTDRAWPARAMS *pimldp) /* Create the blend Mask */ hOldBitmap = SelectObject(hBlendMaskDC, hBlendMaskBmp); hBlendBrush = fStyle & ILD_BLEND50 ? himl->hbrBlend50 : himl->hbrBlend25; - hOldBrush = (HBRUSH) SelectObject(hBlendMaskDC, hBlendBrush); + hOldBrush = SelectObject(hBlendMaskDC, hBlendBrush); PatBlt(hBlendMaskDC, 0, 0, cx, cy, PATCOPY); SelectObject(hBlendMaskDC, hOldBrush);
@@ -1225,7 +1225,7 @@ ImageList_DrawIndirect (IMAGELISTDRAWPARAMS *pimldp) /* now apply blend to the current image given the BlendMask */ if (clrBlend == CLR_DEFAULT) clrBlend = GetSysColor (COLOR_HIGHLIGHT); else if (clrBlend == CLR_NONE) clrBlend = GetTextColor (pimldp->hdcDst); - hOldBrush = (HBRUSH) SelectObject (hImageDC, CreateSolidBrush(clrBlend)); + hOldBrush = SelectObject (hImageDC, CreateSolidBrush(clrBlend)); BitBlt (hImageDC, 0, 0, cx, cy, hBlendMaskDC, 0, 0, 0xB8074A); /* PSDPxax */ DeleteObject(SelectObject(hImageDC, hOldBrush)); SelectObject(hBlendMaskDC, hOldBitmap); diff --git a/dlls/comctl32/ipaddress.c b/dlls/comctl32/ipaddress.c index 5d8d970..4a91417 100644 --- a/dlls/comctl32/ipaddress.c +++ b/dlls/comctl32/ipaddress.c @@ -193,7 +193,7 @@ static LRESULT IPADDRESS_Create (HWND hwnd, const CREATESTRUCTA *lpCreate) infoPtr->Enabled = TRUE; infoPtr->Notify = lpCreate->hwndParent;
- hSysFont = (HFONT) GetStockObject(ANSI_VAR_FONT); + hSysFont = GetStockObject(ANSI_VAR_FONT); GetObjectW(hSysFont, sizeof(LOGFONTW), &logSysFont); SystemParametersInfoW(SPI_GETICONTITLELOGFONT, 0, &logFont, 0); strcpyW(logFont.lfFaceName, logSysFont.lfFaceName); diff --git a/dlls/comctl32/pager.c b/dlls/comctl32/pager.c index 079fbfb..fdf470c 100644 --- a/dlls/comctl32/pager.c +++ b/dlls/comctl32/pager.c @@ -237,7 +237,7 @@ PAGER_DrawButton(HDC hdc, COLORREF clrBk, RECT arrowRect, return;
hBrush = CreateSolidBrush(clrBk); - hOldBrush = (HBRUSH)SelectObject(hdc, hBrush); + hOldBrush = SelectObject(hdc, hBrush);
FillRect(hdc, &rc, hBrush);
diff --git a/dlls/comctl32/tests/datetime.c b/dlls/comctl32/tests/datetime.c index b194cc1..d835e75 100644 --- a/dlls/comctl32/tests/datetime.c +++ b/dlls/comctl32/tests/datetime.c @@ -256,7 +256,7 @@ static void test_dtm_set_and_get_mcfont(HWND hWndDateTime) { HFONT hFontOrig, hFontNew;
- hFontOrig = (HFONT)GetStockObject(DEFAULT_GUI_FONT); + hFontOrig = GetStockObject(DEFAULT_GUI_FONT); SendMessage(hWndDateTime, DTM_SETMCFONT, (WPARAM)hFontOrig, TRUE); hFontNew = (HFONT)SendMessage(hWndDateTime, DTM_GETMCFONT, 0, 0); ok(hFontOrig == hFontNew, "Expected hFontOrig==hFontNew, hFontOrig=%p, hFontNew=%p\n", hFontOrig, hFontNew); diff --git a/dlls/comctl32/tests/imagelist.c b/dlls/comctl32/tests/imagelist.c index 0ed8c78..4b4964f 100644 --- a/dlls/comctl32/tests/imagelist.c +++ b/dlls/comctl32/tests/imagelist.c @@ -138,7 +138,7 @@ static HWND create_a_window(void) cls.hInstance = 0; cls.hIcon = LoadIconA (0, (LPSTR)IDI_APPLICATION); cls.hCursor = LoadCursorA (0, (LPSTR)IDC_ARROW); - cls.hbrBackground = (HBRUSH) GetStockObject (WHITE_BRUSH); + cls.hbrBackground = GetStockObject (WHITE_BRUSH); cls.lpszMenuName = 0; cls.lpszClassName = className;