diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2016-06-16 11:01:07 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2016-06-16 11:01:07 +0200 |
commit | e6ed4ba3ac4c5fae2bbdca9c21728d68a1f386fa (patch) | |
tree | 386a3573f8390e57d3cc6f31efc7f04aef57c48b /svtools/source | |
parent | f23dd396f515b0d82b0db77d01781f28dd7b2fc8 (diff) |
Local linkage for static var (and drop misleading "m_" prefix)
Change-Id: Ide9d2262192899f7a1444760c0df806d30514919
Diffstat (limited to 'svtools/source')
-rw-r--r-- | svtools/source/config/toolpanelopt.cxx | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/svtools/source/config/toolpanelopt.cxx b/svtools/source/config/toolpanelopt.cxx index 5294886095fe..1b8929bf5cc2 100644 --- a/svtools/source/config/toolpanelopt.cxx +++ b/svtools/source/config/toolpanelopt.cxx @@ -297,18 +297,22 @@ Sequence< OUString > SvtToolPanelOptions_Impl::GetPropertyNames() return Sequence< OUString >( pProperties, SAL_N_ELEMENTS( pProperties ) ); } -std::weak_ptr<SvtToolPanelOptions_Impl> m_pOptions; +namespace { + +std::weak_ptr<SvtToolPanelOptions_Impl> theOptions; + +} SvtToolPanelOptions::SvtToolPanelOptions() { // Global access, must be guarded (multithreading!). MutexGuard aGuard( GetInitMutex() ); - m_pImpl = m_pOptions.lock(); + m_pImpl = theOptions.lock(); if( !m_pImpl ) { m_pImpl = std::make_shared<SvtToolPanelOptions_Impl>(); - m_pOptions = m_pImpl; + theOptions = m_pImpl; } } |