incubator-ooo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From p..@apache.org
Subject svn commit: r1199233 - in /incubator/ooo/trunk/main/unotools: inc/unotools/configmgr.hxx source/config/configmgr.cxx
Date Tue, 08 Nov 2011 13:20:30 GMT
Author: pfg
Date: Tue Nov  8 13:20:29 2011
New Revision: 1199233

URL: http://svn.apache.org/viewvc?rev=1199233&view=rev
Log:
i112786 - revert r1182524 the patch was aood but it opens a can of worms (see issue 118576)
that we can't afford just yet.

Modified:
    incubator/ooo/trunk/main/unotools/inc/unotools/configmgr.hxx
    incubator/ooo/trunk/main/unotools/source/config/configmgr.cxx

Modified: incubator/ooo/trunk/main/unotools/inc/unotools/configmgr.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/unotools/inc/unotools/configmgr.hxx?rev=1199233&r1=1199232&r2=1199233&view=diff
==============================================================================
--- incubator/ooo/trunk/main/unotools/inc/unotools/configmgr.hxx (original)
+++ incubator/ooo/trunk/main/unotools/inc/unotools/configmgr.hxx Tue Nov  8 13:20:29 2011
@@ -50,6 +50,7 @@ namespace utl
                                 xConfigurationProvider;
             ConfigMgr_Impl*     pMgrImpl;
 
+            static  ConfigManager*  pConfigManager;
             static void getBasisAboutBoxProductVersion( rtl::OUString& rVersion );
 
         public:
@@ -76,6 +77,7 @@ namespace utl
             void StoreConfigItems();
 
             static ConfigManager*           GetConfigManager();
+            static void                     RemoveConfigManager();
             static rtl::OUString            GetConfigBaseURL();
 
             enum ConfigProperty

Modified: incubator/ooo/trunk/main/unotools/source/config/configmgr.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/unotools/source/config/configmgr.cxx?rev=1199233&r1=1199232&r2=1199233&view=diff
==============================================================================
--- incubator/ooo/trunk/main/unotools/source/config/configmgr.cxx (original)
+++ incubator/ooo/trunk/main/unotools/source/config/configmgr.cxx Tue Nov  8 13:20:29 2011
@@ -348,14 +348,28 @@ void ConfigManager::StoreConfigItems()
 		}
 	}
 }
+ConfigManager*	 ConfigManager::pConfigManager = 0;
 /* -----------------------------07.09.00 11:06--------------------------------
 
  ---------------------------------------------------------------------------*/
-struct theConfigManager : public rtl::Static<ConfigManager, theConfigManager> {};
+ConfigManager*	ConfigManager::GetConfigManager()
+{
+	if(!pConfigManager)
+	{
+		pConfigManager = new ConfigManager();
+	}
+	return pConfigManager;
+}
+/* -----------------------------07.09.00 11:06--------------------------------
 
-ConfigManager* ConfigManager::GetConfigManager()
+ ---------------------------------------------------------------------------*/
+void	ConfigManager::RemoveConfigManager()
 {
-    return &theConfigManager::get();
+	if(pConfigManager)
+	{
+		delete pConfigManager;
+		pConfigManager = 0;
+	}
 }
 /* -----------------------------08.09.00 13:22--------------------------------
 



Mime
View raw message