DSTRICT: comctl32 dll (part 1)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

this is the first step in making comctl32 compile with -DSTRICT. This
patch excludes listview.c cause it's to fast moving target :)

License: LGPL, X11
Changelog:
	Michael Stefaniuc <mstefani@redhat.com>
	- add needed casts for a "no warnings" compile of comctl32

bye
	michael
-- 
Michael Stefaniuc               Tel.: +49-711-96437-199
System Administration           Fax.: +49-711-96437-111
Red Hat GmbH                    Email: mstefani@redhat.com
Hauptstaetterstr. 58            http://www.redhat.de/
D-70178 Stuttgart
Index: dlls/comctl32/animate.c
===================================================================
RCS file: /home/wine/wine/dlls/comctl32/animate.c,v
retrieving revision 1.40
diff -u -r1.40 animate.c
--- dlls/comctl32/animate.c	6 Sep 2002 19:41:17 -0000	1.40
+++ dlls/comctl32/animate.c	22 Oct 2002 21:50:08 -0000
@@ -385,8 +385,8 @@
             hDC = GetDC(infoPtr->hWnd);
 	    /* sometimes the animation window will be destroyed in between
 	     * by the main program, so a ReleaseDC() error msg is possible */
-            infoPtr->hbrushBG = SendMessageA(GetParent(infoPtr->hWnd),
-					     WM_CTLCOLORSTATIC, hDC,
+            infoPtr->hbrushBG = (HBRUSH)SendMessageA(GetParent(infoPtr->hWnd),
+					     WM_CTLCOLORSTATIC, (WPARAM)hDC,
 					     (LPARAM)infoPtr->hWnd);
             ReleaseDC(infoPtr->hWnd,hDC);
         }
@@ -690,7 +690,7 @@
     }
 
     if (!hInstance)
-       hInstance = GetWindowLongA(hWnd, GWL_HINSTANCE);
+       hInstance = (HINSTANCE)GetWindowLongA(hWnd, GWL_HINSTANCE);
 
     if (HIWORD(lParam)) {
 	TRACE("(\"%s\");\n", (LPSTR)lParam);
@@ -816,8 +816,8 @@
 
     if(GetWindowLongA(hWnd, GWL_STYLE) & ACS_TRANSPARENT)
     {
-        hBrush = SendMessageA(GetParent(hWnd),WM_CTLCOLORSTATIC,(HDC)wParam,
-			      (LPARAM)hWnd);
+        hBrush = (HBRUSH)SendMessageA(GetParent(hWnd),WM_CTLCOLORSTATIC,
+				      wParam, (LPARAM)hWnd);
     }
 
     GetClientRect(hWnd, &rect);
@@ -874,8 +874,9 @@
     	if (GetWindowLongA(hWnd, GWL_STYLE) & ACS_TRANSPARENT)
         {
             ANIMATE_INFO* infoPtr = ANIMATE_GetInfoPtr(hWnd);
-            infoPtr->hbrushBG = SendMessageA(GetParent(hWnd), WM_CTLCOLORSTATIC,
-					     (HDC)wParam, (LPARAM)hWnd);
+            infoPtr->hbrushBG = (HBRUSH)SendMessageA(GetParent(hWnd),
+						     WM_CTLCOLORSTATIC,
+						     wParam, (LPARAM)hWnd);
         }
 	return ANIMATE_DrawFrame(ANIMATE_GetInfoPtr(hWnd));
 
@@ -893,8 +894,9 @@
 	    	return DefWindowProcA(hWnd, uMsg, wParam, lParam);
 
             if (GetWindowLongA(hWnd, GWL_STYLE) & ACS_TRANSPARENT)
-                infoPtr->hbrushBG = SendMessageA(GetParent(hWnd), WM_CTLCOLORSTATIC,
-					       	 (HDC)wParam, (LPARAM)hWnd);
+                infoPtr->hbrushBG = (HBRUSH)SendMessageA(GetParent(hWnd),
+							 WM_CTLCOLORSTATIC,
+							 wParam, (LPARAM)hWnd);
 
             if (wParam)
             {
Index: dlls/comctl32/comboex.c
===================================================================
RCS file: /home/wine/wine/dlls/comctl32/comboex.c,v
retrieving revision 1.55
diff -u -r1.55 comboex.c
--- dlls/comctl32/comboex.c	16 Oct 2002 18:57:14 -0000	1.55
+++ dlls/comctl32/comboex.c	22 Oct 2002 21:50:09 -0000
@@ -319,7 +319,7 @@
     HDC mydc;
 
     mydc = GetDC (0); /* why the entire screen???? */
-    nfont = SendMessageW (infoPtr->hwndCombo, WM_GETFONT, 0, 0);
+    nfont = (HFONT)SendMessageW (infoPtr->hwndCombo, WM_GETFONT, 0, 0);
     ofont = (HFONT) SelectObject (mydc, nfont);
     GetTextExtentPointA (mydc, "A", 1, size);
     SelectObject (mydc, ofont);
@@ -962,7 +962,7 @@
 			 GetWindowLongW (hwnd, GWL_STYLE),
 			 cs->y, cs->x, cs->cx, cs->cy, hwnd,
 			 (HMENU) GetWindowLongW (hwnd, GWL_ID),
-			 GetWindowLongW (hwnd, GWL_HINSTANCE), NULL);
+			 (HINSTANCE)GetWindowLongW (hwnd, GWL_HINSTANCE), NULL);
 
     /*
      * native does the following at this point according to trace:
@@ -979,7 +979,7 @@
     SetPropA(infoPtr->hwndCombo, COMBOEX_SUBCLASS_PROP, hwnd);
     infoPtr->prevComboWndProc = (WNDPROC)SetWindowLongW(infoPtr->hwndCombo,
 	                        GWL_WNDPROC, (LONG)COMBOEX_ComboWndProc);
-    infoPtr->font = SendMessageW (infoPtr->hwndCombo, WM_GETFONT, 0, 0);
+    infoPtr->font = (HFONT)SendMessageW (infoPtr->hwndCombo, WM_GETFONT, 0, 0);
 
 
     /*
@@ -992,8 +992,7 @@
 		    0, 0, 0, 0,  /* will set later */
 		    infoPtr->hwndCombo,
 		    (HMENU) GetWindowLongW (hwnd, GWL_ID),
-		    GetWindowLongW (hwnd, GWL_HINSTANCE),
-		    NULL);
+		    (HINSTANCE)GetWindowLongW (hwnd, GWL_HINSTANCE), NULL);
 
 	/* native does the following at this point according to trace:
 	 *  GetWindowThreadProcessId(hwndEdit,0)
@@ -1009,7 +1008,7 @@
         SetPropA(infoPtr->hwndEdit, COMBOEX_SUBCLASS_PROP, hwnd);
 	infoPtr->prevEditWndProc = (WNDPROC)SetWindowLongW(infoPtr->hwndEdit,
 				 GWL_WNDPROC, (LONG)COMBOEX_EditWndProc);
-	infoPtr->font = SendMessageW (infoPtr->hwndCombo, WM_GETFONT, 0, 0);
+	infoPtr->font = (HFONT)SendMessageW(infoPtr->hwndCombo, WM_GETFONT, 0, 0);
     }
 
     /*
Index: dlls/comctl32/commctrl.c
===================================================================
RCS file: /home/wine/wine/dlls/comctl32/commctrl.c,v
retrieving revision 1.58
diff -u -r1.58 commctrl.c
--- dlls/comctl32/commctrl.c	17 Oct 2002 01:18:52 -0000	1.58
+++ dlls/comctl32/commctrl.c	22 Oct 2002 21:50:10 -0000
@@ -321,9 +321,9 @@
     while (*lpMenuId != uFlags)
 	lpMenuId += 2;
 
-    if (GetMenuState (lpInfo[1], uFlags, MF_BYCOMMAND) & MFS_CHECKED) {
+    if (GetMenuState ((HMENU)lpInfo[1], uFlags, MF_BYCOMMAND) & MFS_CHECKED) {
 	/* uncheck menu item */
-	CheckMenuItem (lpInfo[0], *lpMenuId, MF_BYCOMMAND | MF_UNCHECKED);
+	CheckMenuItem ((HMENU)lpInfo[0], *lpMenuId, MF_BYCOMMAND | MF_UNCHECKED);
 
 	/* hide control */
 	lpMenuId++;
@@ -332,7 +332,7 @@
     }
     else {
 	/* check menu item */
-	CheckMenuItem (lpInfo[0], *lpMenuId, MF_BYCOMMAND | MF_CHECKED);
+	CheckMenuItem ((HMENU)lpInfo[0], *lpMenuId, MF_BYCOMMAND | MF_CHECKED);
 
 	/* show control */
 	lpMenuId++;
@@ -500,7 +500,7 @@
     return CreateWindowA(STATUSCLASSNAMEA, text, style,
 			   CW_USEDEFAULT, CW_USEDEFAULT,
 			   CW_USEDEFAULT, CW_USEDEFAULT,
-			   parent, wid, 0, 0);
+			   parent, (HMENU)wid, 0, 0);
 }
 
 
@@ -524,7 +524,7 @@
     return CreateWindowW(STATUSCLASSNAMEW, text, style,
 			   CW_USEDEFAULT, CW_USEDEFAULT,
 			   CW_USEDEFAULT, CW_USEDEFAULT,
-			   parent, wid, 0, 0);
+			   parent, (HMENU)wid, 0, 0);
 }
 
 
@@ -557,7 +557,7 @@
 {
     HWND hUD =
 	CreateWindowA (UPDOWN_CLASSA, 0, style, x, y, cx, cy,
-			 parent, id, inst, 0);
+			 parent, (HMENU)id, inst, 0);
     if (hUD) {
 	SendMessageA (hUD, UDM_SETBUDDY, (WPARAM)buddy, 0);
 	SendMessageA (hUD, UDM_SETRANGE, 0, MAKELONG(maxVal, minVal));
Index: dlls/comctl32/datetime.c
===================================================================
RCS file: /home/wine/wine/dlls/comctl32/datetime.c,v
retrieving revision 1.31
diff -u -r1.31 datetime.c
--- dlls/comctl32/datetime.c	6 Sep 2002 19:41:17 -0000	1.31
+++ dlls/comctl32/datetime.c	22 Oct 2002 21:50:10 -0000
@@ -1159,7 +1159,7 @@
          WS_CHILD | WS_VISIBLE | BS_AUTOCHECKBOX,
          2,2,13,13,
          hwnd,
-         0, GetWindowLongA  (hwnd, GWL_HINSTANCE), 0);
+         0, (HINSTANCE)GetWindowLongA  (hwnd, GWL_HINSTANCE), 0);
          SendMessageA (infoPtr->hwndCheckbut, BM_SETCHECK, 1, 0);
   }
 
Index: dlls/comctl32/hotkey.c
===================================================================
RCS file: /home/wine/wine/dlls/comctl32/hotkey.c,v
retrieving revision 1.22
diff -u -r1.22 hotkey.c
--- dlls/comctl32/hotkey.c	17 Sep 2002 18:30:07 -0000	1.22
+++ dlls/comctl32/hotkey.c	22 Oct 2002 21:50:10 -0000
@@ -262,7 +262,7 @@
 inline static LRESULT
 HOTKEY_GetFont (HOTKEY_INFO *infoPtr, WPARAM wParam, LPARAM lParam)
 {
-    return infoPtr->hFont;
+    return (LRESULT)infoPtr->hFont;
 }
 
 static LRESULT
Index: dlls/comctl32/imagelist.c
===================================================================
RCS file: /home/wine/wine/dlls/comctl32/imagelist.c,v
retrieving revision 1.63
diff -u -r1.63 imagelist.c
--- dlls/comctl32/imagelist.c	16 Oct 2002 18:57:14 -0000	1.63
+++ dlls/comctl32/imagelist.c	22 Oct 2002 21:50:11 -0000
@@ -195,12 +194,13 @@
 
     if(himl->hbmMask)
     {
-        HDC hdcMask, hdcTemp, hOldBitmapMask, hOldBitmapTemp;
+	HDC hdcMask, hdcTemp;
+	HBITMAP hOldBitmapMask, hOldBitmapTemp;
 
         hdcMask   = CreateCompatibleDC (0);
         hdcTemp   = CreateCompatibleDC(0);
-        hOldBitmapMask = (HBITMAP) SelectObject(hdcMask, himl->hbmMask);
-        hOldBitmapTemp = (HBITMAP) SelectObject(hdcTemp, hbmMask);
+        hOldBitmapMask = SelectObject(hdcMask, himl->hbmMask);
+        hOldBitmapTemp = SelectObject(hdcTemp, hbmMask);
 
         BitBlt (hdcMask,
             nStartX, 0, bmp.bmWidth, bmp.bmHeight,
Index: dlls/comctl32/ipaddress.c
===================================================================
RCS file: /home/wine/wine/dlls/comctl32/ipaddress.c,v
retrieving revision 1.27
diff -u -r1.27 ipaddress.c
--- dlls/comctl32/ipaddress.c	16 Oct 2002 18:57:14 -0000	1.27
+++ dlls/comctl32/ipaddress.c	22 Oct 2002 21:50:12 -0000
@@ -179,7 +179,7 @@
 		CreateWindowW (EDIT, NULL, WS_CHILD | WS_VISIBLE | ES_CENTER,
                                edit.left, edit.top, edit.right - edit.left,
 			       edit.bottom - edit.top, hwnd, (HMENU) 1,
-			       GetWindowLongW (hwnd, GWL_HINSTANCE), NULL);
+			       (HINSTANCE)GetWindowLongW(hwnd, GWL_HINSTANCE), NULL);
 	SetPropA(part->EditHwnd, IP_SUBCLASS_PROP, hwnd);
         part->OrigProc = (WNDPROC)
 		SetWindowLongW (part->EditHwnd, GWL_WNDPROC,
Index: dlls/comctl32/progress.c
===================================================================
RCS file: /home/wine/wine/dlls/comctl32/progress.c,v
retrieving revision 1.26
diff -u -r1.26 progress.c
--- dlls/comctl32/progress.c	16 Oct 2002 18:57:14 -0000	1.26
+++ dlls/comctl32/progress.c	22 Oct 2002 21:50:12 -0000
@@ -314,7 +314,7 @@
         return (LRESULT)infoPtr->Font;
 
     case WM_SETFONT:
-        return PROGRESS_SetFont (infoPtr, (HFONT)wParam, (BOOL)lParam);
+        return (LRESULT)PROGRESS_SetFont(infoPtr, (HFONT)wParam, (BOOL)lParam);
 
     case WM_PAINT:
         return PROGRESS_Paint (infoPtr, (HDC)wParam);
Index: dlls/comctl32/status.c
===================================================================
RCS file: /home/wine/wine/dlls/comctl32/status.c,v
retrieving revision 1.53
diff -u -r1.53 status.c
--- dlls/comctl32/status.c	16 Oct 2002 18:57:14 -0000	1.53
+++ dlls/comctl32/status.c	22 Oct 2002 21:50:12 -0000
@@ -899,10 +899,9 @@
     if (dwStyle & SBT_TOOLTIPS) {
 	infoPtr->hwndToolTip =
 	    CreateWindowExW (0, TOOLTIPS_CLASSW, NULL, 0,
-			       CW_USEDEFAULT, CW_USEDEFAULT,
-			       CW_USEDEFAULT, CW_USEDEFAULT,
-			     hwnd, 0,
-			     GetWindowLongW (hwnd, GWL_HINSTANCE), NULL);
+			     CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT,
+			     CW_USEDEFAULT, hwnd, 0,
+			     (HINSTANCE)GetWindowLongW(hwnd, GWL_HINSTANCE), NULL);
 
 	if (infoPtr->hwndToolTip) {
 	    NMTOOLTIPSCREATED nmttc;
@@ -1188,7 +1187,7 @@
 	    return STATUSBAR_WMDestroy (infoPtr);
 
 	case WM_GETFONT:
-	    return infoPtr->hFont? infoPtr->hFont : infoPtr->hDefaultFont;
+	    return (LRESULT)(infoPtr->hFont? infoPtr->hFont : infoPtr->hDefaultFont);
 
 	case WM_GETTEXT:
             return STATUSBAR_WMGetText (infoPtr, (INT)wParam, (LPWSTR)lParam);
Index: dlls/comctl32/toolbar.c
===================================================================
RCS file: /home/wine/wine/dlls/comctl32/toolbar.c,v
retrieving revision 1.121
diff -u -r1.121 toolbar.c
--- dlls/comctl32/toolbar.c	21 Oct 2002 18:19:02 -0000	1.121
+++ dlls/comctl32/toolbar.c	22 Oct 2002 21:50:14 -0000
@@ -2765,7 +2765,7 @@
     if(!(template = (LPVOID)LoadResource (COMCTL32_hModule, hRes)))
 	return FALSE;
 
-    ret = DialogBoxIndirectParamA (GetWindowLongA (hwnd, GWL_HINSTANCE),
+    ret = DialogBoxIndirectParamA ((HINSTANCE)GetWindowLongA(hwnd, GWL_HINSTANCE),
                                    (LPDLGTEMPLATEA)template,
                                    hwnd,
                                    (DLGPROC)TOOLBAR_CustomizeDialogProc,
@@ -3683,7 +3683,7 @@
           lpReplace->hInstOld, lpReplace->nIDOld, lpReplace->hInstNew, lpReplace->nIDNew,
           lpReplace->nButtons);
 
-    if (lpReplace->hInstOld == -1)
+    if (lpReplace->hInstOld == HINST_COMMCTRL)
     {
         FIXME("changing standard bitmaps not implemented\n");
         return FALSE;
@@ -4703,7 +4703,7 @@
 {
     TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd);
 
-    return infoPtr->hFont;
+    return (LRESULT)infoPtr->hFont;
 }
 
 
Index: dlls/comctl32/tooltips.c
===================================================================
RCS file: /home/wine/wine/dlls/comctl32/tooltips.c,v
retrieving revision 1.49
diff -u -r1.49 tooltips.c
--- dlls/comctl32/tooltips.c	2 Oct 2002 23:46:20 -0000	1.49
+++ dlls/comctl32/tooltips.c	22 Oct 2002 21:50:15 -0000
@@ -720,10 +720,12 @@
     /* install subclassing hook */
     if (toolPtr->uFlags & TTF_SUBCLASS) {
 	if (toolPtr->uFlags & TTF_IDISHWND) {
-	    SetWindowSubclass(toolPtr->uId, TOOLTIPS_SubclassProc, 1, hwnd);
+	    SetWindowSubclass((HWND)toolPtr->uId, TOOLTIPS_SubclassProc, 1,
+			       (DWORD_PTR)hwnd);
 	}
 	else {
-	    SetWindowSubclass(toolPtr->hwnd, TOOLTIPS_SubclassProc, 1, hwnd);
+	    SetWindowSubclass(toolPtr->hwnd, TOOLTIPS_SubclassProc, 1,
+			      (DWORD_PTR)hwnd);
 	}
 	TRACE("subclassing installed!\n");
     }
@@ -795,10 +797,12 @@
     /* install subclassing hook */
     if (toolPtr->uFlags & TTF_SUBCLASS) {
 	if (toolPtr->uFlags & TTF_IDISHWND) {
-	    SetWindowSubclass(toolPtr->uId, TOOLTIPS_SubclassProc, 1, hwnd);
+	    SetWindowSubclass((HWND)toolPtr->uId, TOOLTIPS_SubclassProc, 1,
+			      (DWORD_PTR)hwnd);
 	}
 	else {
-	    SetWindowSubclass(toolPtr->hwnd, TOOLTIPS_SubclassProc, 1, hwnd);
+	    SetWindowSubclass(toolPtr->hwnd, TOOLTIPS_SubclassProc, 1,
+			      (DWORD_PTR)hwnd);
 	}
 	TRACE("subclassing installed!\n");
     }
@@ -841,7 +845,7 @@
     /* remove subclassing */
     if (toolPtr->uFlags & TTF_SUBCLASS) {
 	if (toolPtr->uFlags & TTF_IDISHWND) {
-	    RemoveWindowSubclass(toolPtr->uId, TOOLTIPS_SubclassProc, 1);
+	    RemoveWindowSubclass((HWND)toolPtr->uId, TOOLTIPS_SubclassProc, 1);
 	}
 	else {
 	    RemoveWindowSubclass(toolPtr->hwnd, TOOLTIPS_SubclassProc, 1);
@@ -916,7 +920,7 @@
     /* remove subclassing */
     if (toolPtr->uFlags & TTF_SUBCLASS) {
 	if (toolPtr->uFlags & TTF_IDISHWND) {
-	    RemoveWindowSubclass(toolPtr->uId, TOOLTIPS_SubclassProc, 1);
+	    RemoveWindowSubclass((HWND)toolPtr->uId, TOOLTIPS_SubclassProc, 1);
 	}
 	else {
 	    RemoveWindowSubclass(toolPtr->hwnd, TOOLTIPS_SubclassProc, 1);
@@ -1966,7 +1970,7 @@
 	    /* remove subclassing */
         if (toolPtr->uFlags & TTF_SUBCLASS) {
             if (toolPtr->uFlags & TTF_IDISHWND) {
-                RemoveWindowSubclass(toolPtr->uId, TOOLTIPS_SubclassProc, 1);
+                RemoveWindowSubclass((HWND)toolPtr->uId, TOOLTIPS_SubclassProc, 1);
             }
             else {
                 RemoveWindowSubclass(toolPtr->hwnd, TOOLTIPS_SubclassProc, 1);
@@ -2007,7 +2011,7 @@
 {
     TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd);
 
-    return infoPtr->hFont;
+    return (LRESULT)infoPtr->hFont;
 }
 
 
@@ -2222,7 +2226,7 @@
 	msg.message = uMsg;
 	msg.wParam = wParam;
 	msg.lParam = lParam;
-	TOOLTIPS_RelayEvent(dwRef, 0, (LPARAM)&msg);
+	TOOLTIPS_RelayEvent((HWND)dwRef, 0, (LPARAM)&msg);
 	break;
 
     default:
Index: dlls/comctl32/trackbar.c
===================================================================
RCS file: /home/wine/wine/dlls/comctl32/trackbar.c,v
retrieving revision 1.41
diff -u -r1.41 trackbar.c
--- dlls/comctl32/trackbar.c	16 Oct 2002 18:57:14 -0000	1.41
+++ dlls/comctl32/trackbar.c	22 Oct 2002 21:50:15 -0000
@@ -1560,7 +1560,7 @@
         return TRACKBAR_ClearTics (infoPtr, (BOOL)wParam);
 
     case TBM_GETBUDDY:
-        return wParam ? infoPtr->hwndBuddyLA : infoPtr->hwndBuddyRB;
+        return (LRESULT)(wParam ? infoPtr->hwndBuddyLA : infoPtr->hwndBuddyRB);
 
     case TBM_GETCHANNELRECT:
         return TRACKBAR_GetChannelRect (infoPtr, (LPRECT)lParam);
Index: dlls/comctl32/treeview.c
===================================================================
RCS file: /home/wine/wine/dlls/comctl32/treeview.c,v
retrieving revision 1.103
diff -u -r1.103 treeview.c
--- dlls/comctl32/treeview.c	6 Sep 2002 19:41:18 -0000	1.103
+++ dlls/comctl32/treeview.c	22 Oct 2002 21:50:17 -0000
@@ -1770,7 +1770,7 @@
 TREEVIEW_GetFont(TREEVIEW_INFO *infoPtr)
 {
     TRACE("%x\n", infoPtr->hFont);
-    return infoPtr->hFont;
+    return (LRESULT)infoPtr->hFont;
 }
 
 
@@ -2814,7 +2814,7 @@
             rc.left = 0; rc.top = 0;
             rc.right = bitmap.bmWidth;
             rc.bottom = bitmap.bmHeight;
-            TREEVIEW_EraseBackground(infoPtr, wParam);
+            TREEVIEW_EraseBackground(infoPtr, (HDC)wParam);
         }
     }
     else
@@ -3476,7 +3476,7 @@
 	    len = GetWindowTextA(infoPtr->hwndEdit, buffer, sizeof(buffer));
 
 	    /* Select font to get the right dimension of the string */
-	    hFont = SendMessageA(infoPtr->hwndEdit, WM_GETFONT, 0, 0);
+	    hFont = (HFONT)SendMessageA(infoPtr->hwndEdit, WM_GETFONT, 0, 0);
 	    if (hFont != 0)
 	    {
 		hOldFont = SelectObject(hdc, hFont);
@@ -3526,7 +3526,7 @@
     HWND hwndEdit;
     SIZE sz;
     TREEVIEW_ITEM *editItem = hItem;
-    HINSTANCE hinst = GetWindowLongA(hwnd, GWL_HINSTANCE);
+    HINSTANCE hinst = (HINSTANCE)GetWindowLongA(hwnd, GWL_HINSTANCE);
     HDC hdc;
     HFONT hOldFont=0;
     TEXTMETRICA textMetric;
@@ -3589,8 +3589,8 @@
     SetWindowLongA(hwndEdit, GWL_STYLE,
 		   GetWindowLongA(hwndEdit, GWL_STYLE) | WS_BORDER);
 
-    SendMessageA(hwndEdit, WM_SETFONT, TREEVIEW_FontForItem(infoPtr, editItem),
-		 FALSE);
+    SendMessageA(hwndEdit, WM_SETFONT,
+		 (WPARAM)TREEVIEW_FontForItem(infoPtr, editItem), FALSE);
 
     infoPtr->wpEditOrig = (WNDPROC)SetWindowLongA(hwndEdit, GWL_WNDPROC,
 						  (DWORD)

Attachment: pgp00067.pgp
Description: PGP signature


[Index of Archives]     [Gimp for Windows]     [Red Hat]     [Samba]     [Yosemite Camping]     [Graphics Cards]     [Wine Home]

  Powered by Linux