diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-07-29 14:43:31 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-07-29 17:37:31 +0200 |
commit | 52b8697a1f6af99061984140ecbca36808ae4a55 (patch) | |
tree | 423905bd18653ec3301ffb06833caa0af40ffddd /sfx2 | |
parent | 962b6307da5d1248481bf9efa534a7bbd37f3a41 (diff) |
rtl::Static -> static local
Change-Id: Ib8d9a24659a37e6b94237d98f030cd2be00bcb39
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119665
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sfx2')
-rw-r--r-- | sfx2/source/appl/workwin.cxx | 9 | ||||
-rw-r--r-- | sfx2/source/bastyp/fltfnc.cxx | 14 | ||||
-rw-r--r-- | sfx2/source/dialog/dockwin.cxx | 6 |
3 files changed, 4 insertions, 25 deletions
diff --git a/sfx2/source/appl/workwin.cxx b/sfx2/source/appl/workwin.cxx index d647526d6141..387c6d9aeeac 100644 --- a/sfx2/source/appl/workwin.cxx +++ b/sfx2/source/appl/workwin.cxx @@ -326,17 +326,12 @@ namespace return OUString(); } }; - - class theFilledToolBarResIdToResourceURLMap - : public rtl::Static<FilledToolBarResIdToResourceURLMap, - theFilledToolBarResIdToResourceURLMap> - { - }; } static OUString GetResourceURLFromToolbarId(ToolbarId eId) { - return theFilledToolBarResIdToResourceURLMap::get().findURL(eId); + static FilledToolBarResIdToResourceURLMap theFilledToolBarResIdToResourceURLMap; + return theFilledToolBarResIdToResourceURLMap.findURL(eId); } static sal_uInt16 TbxMatch( sal_uInt16 nPos ) diff --git a/sfx2/source/bastyp/fltfnc.cxx b/sfx2/source/bastyp/fltfnc.cxx index 83b25b015e4d..00a9b3d517e6 100644 --- a/sfx2/source/bastyp/fltfnc.cxx +++ b/sfx2/source/bastyp/fltfnc.cxx @@ -75,17 +75,6 @@ using namespace com::sun::star; namespace { class theSfxFilterListener : public rtl::Static<SfxFilterListener, theSfxFilterListener> {}; - class SfxFilterArray - { - SfxFilterList_Impl aList; - public: - - SfxFilterList_Impl& getList() - { - return aList; - } - }; - class theSfxFilterArray : public rtl::Static<SfxFilterArray, theSfxFilterArray > {}; } static SfxFilterList_Impl* pFilterArr = nullptr; @@ -93,7 +82,8 @@ static bool bFirstRead = true; static void CreateFilterArr() { - pFilterArr = &theSfxFilterArray::get().getList(); + static SfxFilterList_Impl theSfxFilterArray; + pFilterArr = &theSfxFilterArray; theSfxFilterListener::get(); } diff --git a/sfx2/source/dialog/dockwin.cxx b/sfx2/source/dialog/dockwin.cxx index e2e39bed93ca..48e57efaacc4 100644 --- a/sfx2/source/dialog/dockwin.cxx +++ b/sfx2/source/dialog/dockwin.cxx @@ -27,7 +27,6 @@ #include <vcl/idle.hxx> #include <o3tl/safeint.hxx> #include <osl/diagnose.h> -#include <rtl/instance.hxx> #include <toolkit/helper/vclunohelper.hxx> #include <tools/debug.hxx> #include <comphelper/processfactory.hxx> @@ -288,11 +287,6 @@ void SfxTitleDockingWindow::Resizing( Size &rSize ) m_pWrappedWindow->SetSizePixel( GetOutputSizePixel() ); } -namespace -{ - struct ChildrenRegisteredMap : public rtl::Static< bool, ChildrenRegisteredMap > {}; -} - static bool lcl_checkDockingWindowID( sal_uInt16 nID ) { return nID >= SID_DOCKWIN_START && nID < o3tl::make_unsigned(SID_DOCKWIN_START+NUM_OF_DOCKINGWINDOWS); |