diff options
author | Noel Grandin <noelgrandin@gmail.com> | 2021-11-07 18:45:58 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-11-08 07:43:09 +0100 |
commit | a75324ccabcf09c0f1bc7a1a43256aa37f0da751 (patch) | |
tree | 6de2ef70e4c0a3006944454652681858c946b871 /include/oox | |
parent | 01878ce321dbbffbc877fbe9eb399dec95f99755 (diff) |
rtl::Instance->thread-safe static in PropertyNameVector
Change-Id: I3f595585b78c9e5ac32d9fc345c55a4eb14101c5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124824
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'include/oox')
-rw-r--r-- | include/oox/helper/propertymap.hxx | 5 | ||||
-rw-r--r-- | include/oox/token/propertynames.hxx | 18 |
2 files changed, 5 insertions, 18 deletions
diff --git a/include/oox/helper/propertymap.hxx b/include/oox/helper/propertymap.hxx index 85635f314d5e..3e48c9817fd1 100644 --- a/include/oox/helper/propertymap.hxx +++ b/include/oox/helper/propertymap.hxx @@ -22,6 +22,7 @@ #include <map> #include <utility> +#include <vector> #include <com/sun/star/uno/Any.hxx> #include <com/sun/star/uno/Reference.hxx> @@ -37,8 +38,6 @@ namespace com::sun::star::beans { namespace oox { -struct PropertyNameVector; - typedef ::std::map< OUString, css::uno::Any > PropertyNameMap; @@ -114,7 +113,7 @@ public: static void dumpData( const css::uno::Reference<css::beans::XPropertySet>& rXPropSet); #endif private: - const PropertyNameVector* mpPropNames; + const std::vector<OUString>* mpPropNames; protected: std::map< sal_Int32, css::uno::Any > maProperties; diff --git a/include/oox/token/propertynames.hxx b/include/oox/token/propertynames.hxx index 84077359e1fe..91e07cbdd33b 100644 --- a/include/oox/token/propertynames.hxx +++ b/include/oox/token/propertynames.hxx @@ -16,30 +16,18 @@ * except in compliance with the License. You may obtain a copy of * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ - -#ifndef INCLUDED_OOX_TOKEN_PROPERTYNAMES_HXX -#define INCLUDED_OOX_TOKEN_PROPERTYNAMES_HXX +#pragma once #include <vector> -#include <rtl/instance.hxx> #include <rtl/ustring.hxx> namespace oox { /** A vector that contains all predefined property names used in the filters. */ -struct PropertyNameVector : public ::std::vector<OUString> -{ - PropertyNameVector(); -}; - -/** Thread-save singleton of a vector of all supported property names. */ -struct StaticPropertyNameVector : public ::rtl::Static<PropertyNameVector, StaticPropertyNameVector> -{ -}; +/** Thread-safe singleton of a vector of all supported property names. */ +const std::vector<OUString>& GetPropertyNameVector(); } // namespace oox -#endif - /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |