wine/dlls/shell32 brsfolder.c

Alexandre Julliard julliard at wine.codeweavers.com
Wed Nov 9 04:30:28 CST 2005


ChangeSet ID:	21183
CVSROOT:	/opt/cvs-commit
Module name:	wine
Changes by:	julliard at winehq.org	2005/11/09 04:30:28

Modified files:
	dlls/shell32   : brsfolder.c 

Log message:
	Michael Jung <mjung at iss.tu-darmstadt.de>
	Initialize COM prior to displaying the SHBrowseForFolder dialog.

Patch: http://cvs.winehq.org/patch.py?id=21183

Old revision  New revision  Changes     Path
 1.65          1.66          +4 -0       wine/dlls/shell32/brsfolder.c

Index: wine/dlls/shell32/brsfolder.c
diff -u -p wine/dlls/shell32/brsfolder.c:1.65 wine/dlls/shell32/brsfolder.c:1.66
--- wine/dlls/shell32/brsfolder.c:1.65	9 Nov 2005 10:30:28 -0000
+++ wine/dlls/shell32/brsfolder.c	9 Nov 2005 10:30:28 -0000
@@ -672,14 +672,18 @@ LPITEMIDLIST WINAPI SHBrowseForFolderW (
 {
     browse_info info;
     DWORD r;
+    HRESULT hr;
 
     info.hWnd = 0;
     info.pidlRet = NULL;
     info.lpBrowseInfo = lpbi;
     info.hwndTreeView = NULL;
 
+    hr = CoInitialize(NULL);
     r = DialogBoxParamW( shell32_hInstance, swBrowseTemplateName, lpbi->hwndOwner,
 	                 BrsFolderDlgProc, (LPARAM)&info );
+    if (SUCCEEDED(hr)) 
+        CoUninitialize();
     if (!r)
         return NULL;
 



More information about the wine-cvs mailing list