diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2013-12-11 15:16:51 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2013-12-12 08:26:40 +0100 |
commit | a62c2a5fa5d5be465b0edab6adeb1fd16ace462f (patch) | |
tree | 47cf29b4b7a0ba3ce321ce628a6b0a6175d978d7 /sw/source/filter/xml/wrtxml.cxx | |
parent | cff72ec4bf87c6484be97d954966309ba7a5eb8a (diff) |
Don't hold css::uno::Type instances by pointer
...in comphelper::PropertyMapEntry and SfxItemPropertyMapEntry. And as the
arrays of such need to be initialized dynamically anyway, also change their name
members to proper OUStrings while at it. Plus some const clean-up.
Change-Id: I67d4d7b5773fb020605f369daf39528bec930606
Diffstat (limited to 'sw/source/filter/xml/wrtxml.cxx')
-rw-r--r-- | sw/source/filter/xml/wrtxml.cxx | 67 |
1 files changed, 31 insertions, 36 deletions
diff --git a/sw/source/filter/xml/wrtxml.cxx b/sw/source/filter/xml/wrtxml.cxx index 2753b9621537..61594fffdf72 100644 --- a/sw/source/filter/xml/wrtxml.cxx +++ b/sw/source/filter/xml/wrtxml.cxx @@ -105,59 +105,54 @@ pGraphicHelper = SvXMLGraphicHelper::Create( xStg, // the user. // create XPropertySet with three properties for status indicator - comphelper::PropertyMapEntry aInfoMap[] = + comphelper::PropertyMapEntry const aInfoMap[] = { - { "ProgressRange", sizeof("ProgressRange")-1, 0, - &::getCppuType((sal_Int32*)0), + { OUString("ProgressRange"), 0, + ::getCppuType((sal_Int32*)0), beans::PropertyAttribute::MAYBEVOID, 0}, - { "ProgressMax", sizeof("ProgressMax")-1, 0, - &::getCppuType((sal_Int32*)0), + { OUString("ProgressMax"), 0, + ::getCppuType((sal_Int32*)0), beans::PropertyAttribute::MAYBEVOID, 0}, - { "ProgressCurrent", sizeof("ProgressCurrent")-1, 0, - &::getCppuType((sal_Int32*)0), + { OUString("ProgressCurrent"), 0, + ::getCppuType((sal_Int32*)0), beans::PropertyAttribute::MAYBEVOID, 0}, - { "WrittenNumberStyles", sizeof("WrittenNumberStyles")-1, 0, - &::getCppuType((uno::Sequence<sal_Int32> *)0), + { OUString("WrittenNumberStyles"), 0, + ::getCppuType((uno::Sequence<sal_Int32> *)0), beans::PropertyAttribute::MAYBEVOID, 0}, - { "UsePrettyPrinting", sizeof("UsePrettyPrinting")-1, 0, - &::getBooleanCppuType(), + { OUString("UsePrettyPrinting"), 0, + ::getBooleanCppuType(), beans::PropertyAttribute::MAYBEVOID, 0}, - { "ShowChanges", sizeof("ShowChanges")-1, 0, - &::getBooleanCppuType(), + { OUString("ShowChanges"), 0, + ::getBooleanCppuType(), beans::PropertyAttribute::MAYBEVOID, 0 }, - { "RedlineProtectionKey", sizeof("RedlineProtectionKey")-1, 0, -#if (defined(__SUNPRO_CC) && (__SUNPRO_CC == 0x500)) - new uno::Type(::getCppuType((Sequence<sal_Int8>*)0)), -#else - &::getCppuType((Sequence<sal_Int8>*)0), -#endif + { OUString("RedlineProtectionKey"), 0, + ::getCppuType((Sequence<sal_Int8>*)0), beans::PropertyAttribute::MAYBEVOID, 0 }, - { "BaseURI", sizeof("BaseURI")-1, 0, - &::getCppuType( (OUString *)0 ), + { OUString("BaseURI"), 0, + ::getCppuType( (OUString *)0 ), beans::PropertyAttribute::MAYBEVOID, 0 }, - { "StreamRelPath", sizeof("StreamRelPath")-1, 0, - &::getCppuType( (OUString *)0 ), + { OUString("StreamRelPath"), 0, + ::getCppuType( (OUString *)0 ), beans::PropertyAttribute::MAYBEVOID, 0 }, - { "StreamName", sizeof("StreamName")-1, 0, - &::getCppuType( (OUString *)0 ), + { OUString("StreamName"), 0, + ::getCppuType( (OUString *)0 ), beans::PropertyAttribute::MAYBEVOID, 0 }, - { "AutoTextMode", sizeof("AutoTextMode")-1, 0, - &::getBooleanCppuType(), + { OUString("AutoTextMode"), 0, + ::getBooleanCppuType(), beans::PropertyAttribute::MAYBEVOID, 0 }, - { "StyleNames", sizeof("StyleNames")-1, 0, - &::getCppuType( (Sequence<OUString>*)0 ), + { OUString("StyleNames"), 0, + ::getCppuType( (Sequence<OUString>*)0 ), beans::PropertyAttribute::MAYBEVOID, 0 }, - { "StyleFamilies", sizeof("StyleFamilies")-1, 0, - &::getCppuType( (Sequence<sal_Int32>*)0 ), + { OUString("StyleFamilies"), 0, + ::getCppuType( (Sequence<sal_Int32>*)0 ), beans::PropertyAttribute::MAYBEVOID, 0 }, // #i69627# - { "OutlineStyleAsNormalListStyle", sizeof("OutlineStyleAsNormalListStyle")-1, 0, - &::getBooleanCppuType(), + { OUString("OutlineStyleAsNormalListStyle"), 0, + ::getBooleanCppuType(), beans::PropertyAttribute::MAYBEVOID, 0 }, - { "TargetStorage", sizeof("TargetStorage")-1,0, &embed::XStorage::static_type(), + { OUString("TargetStorage"),0, embed::XStorage::static_type(), ::com::sun::star::beans::PropertyAttribute::MAYBEVOID, 0 }, - - { NULL, 0, 0, NULL, 0, 0 } + { OUString(), 0, css::uno::Type(), 0, 0 } }; uno::Reference< beans::XPropertySet > xInfoSet( comphelper::GenericPropertySet_CreateInstance( |