diff options
author | Kohei Yoshida <kohei.yoshida@gmail.com> | 2013-08-19 10:53:29 -0400 |
---|---|---|
committer | Kohei Yoshida <kohei.yoshida@gmail.com> | 2013-08-19 15:50:35 -0400 |
commit | 5f7ee4b7a32153f3141507de673f60c7f678f015 (patch) | |
tree | bb292852078f14d2141d37af45b50667df97800a /xmloff | |
parent | e69aa9572bb2206313cd2aa7edd13da91460f2c4 (diff) |
These can be file local.
Change-Id: I71193951ce7a1d1a63fc6931a12267f22cdb72c3
Diffstat (limited to 'xmloff')
-rw-r--r-- | xmloff/source/style/xmlexppr.cxx | 45 |
1 files changed, 25 insertions, 20 deletions
diff --git a/xmloff/source/style/xmlexppr.cxx b/xmloff/source/style/xmlexppr.cxx index 6888f6e01594..92e6baace0bb 100644 --- a/xmloff/source/style/xmlexppr.cxx +++ b/xmloff/source/style/xmlexppr.cxx @@ -47,6 +47,9 @@ using namespace ::com::sun::star::lang; using namespace ::xmloff::token; #define GET_PROP_TYPE( f ) static_cast<sal_uInt16>((f & XML_TYPE_PROP_MASK) >> XML_TYPE_PROP_SHIFT) +#define ENTRY(t) { GET_PROP_TYPE(XML_TYPE_PROP_##t), XML_##t##_PROPERTIES } + +namespace { struct XMLPropTokens_Impl { @@ -54,12 +57,11 @@ struct XMLPropTokens_Impl XMLTokenEnum eToken; }; -#define ENTRY(t) { GET_PROP_TYPE(XML_TYPE_PROP_##t), XML_##t##_PROPERTIES } const sal_uInt16 MAX_PROP_TYPES = (XML_TYPE_PROP_END >> XML_TYPE_PROP_SHIFT) - (XML_TYPE_PROP_START >> XML_TYPE_PROP_SHIFT); -static XMLPropTokens_Impl aPropTokens[MAX_PROP_TYPES] = +XMLPropTokens_Impl aPropTokens[MAX_PROP_TYPES] = { ENTRY(CHART), ENTRY(GRAPHIC), @@ -204,24 +206,6 @@ public: sal_uInt32 GetPropertyCount() const { return nCount; } }; -struct SvXMLExportPropertyMapper::Impl -{ - typedef boost::unordered_map<PropertySetInfoKey, FilterPropertiesInfo_Impl*, PropertySetInfoHash, PropertySetInfoHash> CacheType; - CacheType maCache; - - UniReference<SvXMLExportPropertyMapper> mxNextMapper; - UniReference<XMLPropertySetMapper> mxPropMapper; - - OUString maStyleName; - - ~Impl() - { - CacheType::iterator it = maCache.begin(), itEnd = maCache.end(); - for (; it != itEnd; ++it) - delete it->second; - } -}; - FilterPropertiesInfo_Impl::FilterPropertiesInfo_Impl() : nCount(0), aPropInfos(), @@ -248,6 +232,7 @@ void FilterPropertiesInfo_Impl::AddProperty( pApiNames = NULL; } } + const uno::Sequence<OUString>& FilterPropertiesInfo_Impl::GetApiNames() { OSL_ENSURE(nCount == aPropInfos.size(), "wrong property count"); @@ -531,6 +516,26 @@ void FilterPropertiesInfo_Impl::FillPropertyStateArray( aPropStates.FillPropertyStateVector(rPropStates); } +} + +struct SvXMLExportPropertyMapper::Impl +{ + typedef boost::unordered_map<PropertySetInfoKey, FilterPropertiesInfo_Impl*, PropertySetInfoHash, PropertySetInfoHash> CacheType; + CacheType maCache; + + UniReference<SvXMLExportPropertyMapper> mxNextMapper; + UniReference<XMLPropertySetMapper> mxPropMapper; + + OUString maStyleName; + + ~Impl() + { + CacheType::iterator it = maCache.begin(), itEnd = maCache.end(); + for (; it != itEnd; ++it) + delete it->second; + } +}; + // ctor/dtor , class SvXMLExportPropertyMapper SvXMLExportPropertyMapper::SvXMLExportPropertyMapper( |