diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2017-06-19 09:32:45 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2017-06-19 09:38:05 +0200 |
commit | 1e3a00f0c772a76a1dd76b8272e2c35a1802d574 (patch) | |
tree | a1eadac1680f1e46c789964200aa8a61bb659189 /sw/source/ui/dbui | |
parent | 9fe114e78f1285397dcd2a0d2e3d6afc3024fa66 (diff) |
Make SfxItemSet ranges correct by construction: Fix static cases
...with the aid of an extended compilerplugins/clang/store/sfxitemsetrewrite.cxx
(which in turn needed a small addition to compilerplugins/clang/check.hxx).
Enable svl::detail::validGap check for the static case, but keep it disabled for
now for the dynamic case.
Change-Id: I4846ba8e99aff94a86518e2cb5044e575093386e
Diffstat (limited to 'sw/source/ui/dbui')
-rw-r--r-- | sw/source/ui/dbui/mmlayoutpage.cxx | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/sw/source/ui/dbui/mmlayoutpage.cxx b/sw/source/ui/dbui/mmlayoutpage.cxx index 0cd4bcaf7c02..7afde439fb37 100644 --- a/sw/source/ui/dbui/mmlayoutpage.cxx +++ b/sw/source/ui/dbui/mmlayoutpage.cxx @@ -283,12 +283,12 @@ SwFrameFormat* SwMailMergeLayoutPage::InsertAddressFrame( bool bExample) { // insert the address block and the greeting line - SfxItemSet aSet(rShell.GetAttrPool(), svl::Items<RES_ANCHOR, RES_ANCHOR, - RES_VERT_ORIENT, RES_VERT_ORIENT, - RES_HORI_ORIENT, RES_HORI_ORIENT, - RES_BOX, RES_BOX, - RES_FRM_SIZE, RES_FRM_SIZE, - RES_SURROUND, RES_SURROUND>{} ); + SfxItemSet aSet( + rShell.GetAttrPool(), + svl::Items< + RES_FRM_SIZE, RES_FRM_SIZE, + RES_SURROUND, RES_ANCHOR, + RES_BOX, RES_BOX>{} ); aSet.Put(SwFormatAnchor(RndStdIds::FLY_AT_PAGE, 1)); if(bAlignLeft) aSet.Put(SwFormatHoriOrient( 0, text::HoriOrientation::NONE, text::RelOrientation::PAGE_PRINT_AREA )); @@ -692,9 +692,9 @@ IMPL_LINK_NOARG(SwMailMergeLayoutPage, ChangeAddressHdl_Impl, SpinField&, void) long nLeft = static_cast< long >(m_pLeftMF->Denormalize(m_pLeftMF->GetValue(FUNIT_TWIP))); long nTop = static_cast< long >(m_pTopMF->Denormalize(m_pTopMF->GetValue(FUNIT_TWIP))); - SfxItemSet aSet(m_pExampleWrtShell->GetAttrPool(), svl::Items<RES_ANCHOR, RES_ANCHOR, - RES_VERT_ORIENT, RES_VERT_ORIENT, - RES_HORI_ORIENT, RES_HORI_ORIENT>{} ); + SfxItemSet aSet( + m_pExampleWrtShell->GetAttrPool(), + svl::Items<RES_VERT_ORIENT, RES_ANCHOR>{}); if(m_pAlignToBodyCB->IsChecked()) aSet.Put(SwFormatHoriOrient( 0, text::HoriOrientation::NONE, text::RelOrientation::PAGE_PRINT_AREA )); else |