dmapper: use PropNameSupplier in SectionPropertyMap::CloseSectionGroup()

This commit is contained in:
Miklos Vajna 2012-04-14 16:52:36 +02:00
parent 0ef7dbcb36
commit fd1bef82a9
3 changed files with 3 additions and 1 deletions

View File

@ -322,6 +322,7 @@ const rtl::OUString& PropertyNameSupplier::GetName( PropertyIds eId ) const
case PROP_FRM_DIRECTION: sName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FRMDirection")); break;
case PROP_EMBEDDED_OBJECT : sName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("EmbeddedObject")); break;
case PROP_IS_VISIBLE: sName = "IsVisible"; break;
case PROP_PAGE_STYLE_LAYOUT: sName = "PageStyleLayout"; break;
}
::std::pair<PropertyNameMap_t::iterator,bool> aInsertIt =
m_pImpl->aNameMap.insert( PropertyNameMap_t::value_type( eId, sName ));

View File

@ -295,6 +295,7 @@ enum PropertyIds
/*253*/ ,PROP_FRM_DIRECTION
,PROP_EMBEDDED_OBJECT
,PROP_PARA_CONTEXT_MARGIN
,PROP_PAGE_STYLE_LAYOUT
};
struct PropertyNameSupplier_Impl;
class PropertyNameSupplier

View File

@ -982,7 +982,7 @@ void SectionPropertyMap::CloseSectionGroup( DomainMapper_Impl& rDM_Impl )
else if (m_nBreakType == 4)
nPageStyleLayout = style::PageStyleLayout_RIGHT;
if (nPageStyleLayout)
xFollowPageStyle->setPropertyValue("PageStyleLayout", uno::makeAny(nPageStyleLayout));
xFollowPageStyle->setPropertyValue(rPropNameSupplier.GetName(PROP_PAGE_STYLE_LAYOUT), uno::makeAny(nPageStyleLayout));
if(m_bPageNoRestart || m_nPageNumber >= 0)
{
sal_Int16 nPageNumber = m_nPageNumber >= 0 ? static_cast< sal_Int16 >(m_nPageNumber) : 1;