[2/5] GetWindowLongPtr: Shell32

Robert Shearman rob at codeweavers.com
Wed Sep 22 12:17:56 CDT 2004


Hi,

Once again, if this patch conflicts with your work just shout and make 
Alexandre drop it for the moment.

Rob

Changelog:
GetWindowLong -> GetWindowLongPtr.
-------------- next part --------------
Index: wine/dlls/shell32/autocomplete.c
===================================================================
RCS file: /home/wine/wine/dlls/shell32/autocomplete.c,v
retrieving revision 1.9
diff -u -p -r1.9 autocomplete.c
--- wine/dlls/shell32/autocomplete.c	9 Sep 2004 20:17:08 -0000	1.9
+++ wine/dlls/shell32/autocomplete.c	22 Sep 2004 17:01:45 -0000
@@ -260,7 +260,7 @@ static HRESULT WINAPI IAutoComplete_fnIn
 					    WS_BORDER | WS_CHILD | WS_VSCROLL | LBS_HASSTRINGS | LBS_NOTIFY | LBS_NOINTEGRALHEIGHT, 
 					    CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT,
 					    hwndParent, NULL, 
-					    (HINSTANCE)GetWindowLongA( hwndParent, GWL_HINSTANCE ), NULL);
+					    (HINSTANCE)GetWindowLongPtrW( hwndParent, GWLP_HINSTANCE ), NULL);
 					    
 	if (This->hwndListBox) {
 	    This->wpOrigLBoxProc = (WNDPROC) SetWindowLongPtrW( This->hwndListBox, GWLP_WNDPROC, (LONG_PTR) ACLBoxSubclassProc);
Index: wine/dlls/shell32/dialogs.c
===================================================================
RCS file: /home/wine/wine/dlls/shell32/dialogs.c,v
retrieving revision 1.20
diff -u -p -r1.20 dialogs.c
--- wine/dlls/shell32/dialogs.c	9 Aug 2004 19:46:47 -0000	1.20
+++ wine/dlls/shell32/dialogs.c	22 Sep 2004 17:01:46 -0000
@@ -109,8 +109,8 @@ void WINAPI RunFileDlg(
         return;
         }
 
-    DialogBoxIndirectParamA((HINSTANCE)GetWindowLongA( hwndOwner,
-						       GWL_HINSTANCE ),
+    DialogBoxIndirectParamA((HINSTANCE)GetWindowLongPtrW( hwndOwner,
+						       GWLP_HINSTANCE ),
 			    template, hwndOwner, RunDlgProc, (LPARAM)&rfdp);
 
 }
Index: wine/dlls/shell32/shell32_main.c
===================================================================
RCS file: /home/wine/wine/dlls/shell32/shell32_main.c,v
retrieving revision 1.137
diff -u -p -r1.137 shell32_main.c
--- wine/dlls/shell32/shell32_main.c	22 Sep 2004 04:00:43 -0000	1.137
+++ wine/dlls/shell32/shell32_main.c	22 Sep 2004 17:01:46 -0000
@@ -854,7 +858,7 @@ BOOL WINAPI ShellAboutW( HWND hWnd, LPCW
     SystemParametersInfoW( SPI_GETICONTITLELOGFONT, 0, &logFont, 0 );
     info.hFont = CreateFontIndirectW( &logFont );
 
-    bRet = DialogBoxIndirectParamW((HINSTANCE)GetWindowLongW( hWnd, GWL_HINSTANCE ),
+    bRet = DialogBoxIndirectParamW((HINSTANCE)GetWindowLongPtrW( hWnd, GWLP_HINSTANCE ),
                                    template, hWnd, AboutDlgProc, (LPARAM)&info );
     DeleteObject(info.hFont);
     return bRet;
Index: wine/dlls/shell32/shlview.c
===================================================================
RCS file: /home/wine/wine/dlls/shell32/shlview.c,v
retrieving revision 1.103
diff -u -p -r1.103 shlview.c
--- wine/dlls/shell32/shlview.c	9 Sep 2004 20:17:07 -0000	1.103
+++ wine/dlls/shell32/shlview.c	22 Sep 2004 17:01:47 -0000
@@ -1532,7 +1532,7 @@ static LRESULT ShellView_OnChange(IShell
 
 static LRESULT CALLBACK ShellView_WndProc(HWND hWnd, UINT uMessage, WPARAM wParam, LPARAM lParam)
 {
-	IShellViewImpl * pThis = (IShellViewImpl*)GetWindowLongA(hWnd, GWL_USERDATA);
+	IShellViewImpl * pThis = (IShellViewImpl*)GetWindowLongPtrW(hWnd, GWLP_USERDATA);
 	LPCREATESTRUCTA lpcs;
 
 	TRACE("(hwnd=%p msg=%x wparm=%x lparm=%lx)\n",hWnd, uMessage, wParam, lParam);
@@ -1542,7 +1542,7 @@ static LRESULT CALLBACK ShellView_WndPro
 	  case WM_NCCREATE:
 	    lpcs = (LPCREATESTRUCTA)lParam;
 	    pThis = (IShellViewImpl*)(lpcs->lpCreateParams);
-	    SetWindowLongA(hWnd, GWL_USERDATA, (LONG)pThis);
+	    SetWindowLongPtrW(hWnd, GWLP_USERDATA, (ULONG_PTR)pThis);
 	    pThis->hWnd = hWnd;        /*set the window handle*/
 	    break;
 


More information about the wine-patches mailing list