summaryrefslogtreecommitdiff
path: root/configmgr
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2019-01-15 19:05:35 +0100
committerStephan Bergmann <sbergman@redhat.com>2019-01-16 09:20:26 +0100
commit939d744cee18642fec24d33436b211c92b8b46f8 (patch)
treee71e8e9d44dfa2141b554637816af9ca62412d0f /configmgr
parent77243437c425547302c45e781df1daf24634b08e (diff)
Replace uses of rtl/instance.hxx with plain local static vars in configmgr
Change-Id: Iebd72f1cfd2b3af54efaabba04a89d043eef28c8 Reviewed-on: https://gerrit.libreoffice.org/66405 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'configmgr')
-rw-r--r--configmgr/source/components.cxx12
1 files changed, 2 insertions, 10 deletions
diff --git a/configmgr/source/components.cxx b/configmgr/source/components.cxx
index e584a3c98589..9587fde1e7a5 100644
--- a/configmgr/source/components.cxx
+++ b/configmgr/source/components.cxx
@@ -48,7 +48,6 @@
#include <rtl/ref.hxx>
#include <rtl/ustrbuf.hxx>
#include <rtl/ustring.hxx>
-#include <rtl/instance.hxx>
#include <sal/log.hxx>
#include <sal/types.h>
#include <salhelper/thread.hxx>
@@ -196,19 +195,12 @@ void Components::WriteThread::execute() {
reference_->clear();
}
-class theComponentsSingleton :
- public rtl::StaticWithArg<
- Components,
- css::uno::Reference< css::uno::XComponentContext >,
- theComponentsSingleton>
-{
-};
-
Components & Components::getSingleton(
css::uno::Reference< css::uno::XComponentContext > const & context)
{
assert(context.is());
- return theComponentsSingleton::get(context);
+ static Components singleton(context);
+ return singleton;
}
bool Components::allLocales(OUString const & locale) {