Author: akhaldi
Date: Mon Oct 10 18:17:25 2011
New Revision: 54075
URL:
http://svn.reactos.org/svn/reactos?rev=54075&view=rev
Log:
[SHELL32]
* Improve the registration. By Johannes Anderwald.
Modified:
trunk/reactos/dll/win32/shell32/regsvr.c
trunk/reactos/dll/win32/shell32/shell32_main.cpp
trunk/reactos/dll/win32/shell32/shell32_main.h
Modified: trunk/reactos/dll/win32/shell32/regsvr.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/regsvr.c…
==============================================================================
--- trunk/reactos/dll/win32/shell32/regsvr.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/regsvr.c [iso-8859-1] Mon Oct 10 18:17:25 2011
@@ -816,10 +816,7 @@
{ NULL }
};
-/***********************************************************************
- * DllRegisterServer (SHELL32.@)
- */
-HRESULT WINAPI DllRegisterServer(void)
+HRESULT WINAPI DoRegisterServer(void)
{
HRESULT hr;
@@ -835,10 +832,7 @@
return hr;
}
-/***********************************************************************
- * DllUnregisterServer (SHELL32.@)
- */
-HRESULT WINAPI DllUnregisterServer(void)
+HRESULT WINAPI DoUnregisterServer(void)
{
HRESULT hr;
Modified: trunk/reactos/dll/win32/shell32/shell32_main.cpp
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/shell32_…
==============================================================================
--- trunk/reactos/dll/win32/shell32/shell32_main.cpp [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/shell32_main.cpp [iso-8859-1] Mon Oct 10 18:17:25
2011
@@ -1445,13 +1445,20 @@
TRACE("-- pointer to class factory: %p\n", *ppv);
return hResult;
}
-#if 0
+
/***********************************************************************
* DllRegisterServer (BROWSEUI.@)
*/
STDAPI DllRegisterServer()
{
- return gModule.DllRegisterServer(FALSE);
+ HRESULT hr;
+
+ hr = gModule.DllRegisterServer(FALSE);
+ if (FAILED(hr))
+ return hr;
+
+ // extra registration stuff for the IShellFolder
+ return DoRegisterServer();
}
/***********************************************************************
@@ -1459,9 +1466,16 @@
*/
STDAPI DllUnregisterServer()
{
- return gModule.DllUnregisterServer(FALSE);
-}
-#endif
+ HRESULT hr;
+
+ hr = gModule.DllUnregisterServer(FALSE);
+ if (FAILED(hr))
+ return hr;
+
+ // extra stuff which is performed for IShellFolder
+ return DoUnregisterServer();
+}
+
/*************************************************************************
* DllInstall [SHELL32.@]
*
Modified: trunk/reactos/dll/win32/shell32/shell32_main.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/shell32_…
==============================================================================
--- trunk/reactos/dll/win32/shell32/shell32_main.h [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/shell32_main.h [iso-8859-1] Mon Oct 10 18:17:25 2011
@@ -217,4 +217,9 @@
BOOL SH_ShowRecycleBinProperties(WCHAR sDrive);
BOOL SH_ShowPropertiesDialog(LPWSTR lpf, LPCITEMIDLIST pidlFolder, LPCITEMIDLIST *
apidl);
BOOL SH_ShowFolderProperties(LPWSTR pwszFolder, LPCITEMIDLIST pidlFolder, LPCITEMIDLIST *
apidl);
+
+
+EXTERN_C HRESULT WINAPI DoRegisterServer(void);
+EXTERN_C HRESULT WINAPI DoUnregisterServer(void);
+
#endif