diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2021-07-19 11:04:45 +0300 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2021-07-19 16:33:01 +0200 |
commit | b1668edf7fa3ad8c32bcc4d73821770f2df011ca (patch) | |
tree | cb93a00ca59f770e616668af15fdc6a50e1627a1 /sw/source/filter/xml | |
parent | 5b3c530016927d3e91e3124e124f7b428ab285ac (diff) |
Move svl::Items to include/svl/whichranges.hxx, and unify its usage
... in WhichRangesContainer and SfxItemSet ctors. Now it's not needed
to explicitly use 'value' in WhichRangesContainer's ctor, or create an
instance for use in SfxItemSet ctor (svl::Items is already defined as
a template value of corresponding type).
Instead of
WhichRangesContainer Foo(svl::Items<1, 2>::value);
SfxItemSet Bar(rItemPool, svl::Items<1, 2>{});
now use:
WhichRangesContainer Foo(svl::Items<1, 2>);
SfxItemSet Bar(rItemPool, svl::Items<1, 2>);
Change-Id: I4681d952b6442732025e5a26768098878907a238
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119157
Tested-by: Mike Kaganski <mike.kaganski@collabora.com>
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'sw/source/filter/xml')
-rw-r--r-- | sw/source/filter/xml/xmlfmt.cxx | 2 | ||||
-rw-r--r-- | sw/source/filter/xml/xmltexti.cxx | 10 |
2 files changed, 6 insertions, 6 deletions
diff --git a/sw/source/filter/xml/xmlfmt.cxx b/sw/source/filter/xml/xmlfmt.cxx index b24748a82873..9dffac99c8c2 100644 --- a/sw/source/filter/xml/xmlfmt.cxx +++ b/sw/source/filter/xml/xmlfmt.cxx @@ -533,7 +533,7 @@ SvXMLImportContext *SwXMLItemSetStyleContext_Impl::CreateItemSetContext( m_pItemSet.reset( new SfxItemSet( rItemPool, aTableSetRange ) ); break; case XmlStyleFamily::TABLE_COLUMN: - m_pItemSet.reset( new SfxItemSet( rItemPool, svl::Items<RES_FRM_SIZE, RES_FRM_SIZE>{} ) ); + m_pItemSet.reset( new SfxItemSet( rItemPool, svl::Items<RES_FRM_SIZE, RES_FRM_SIZE> ) ); break; case XmlStyleFamily::TABLE_ROW: m_pItemSet.reset( new SfxItemSet( rItemPool, aTableLineSetRange ) ); diff --git a/sw/source/filter/xml/xmltexti.cxx b/sw/source/filter/xml/xmltexti.cxx index be863f65bfa3..97b1fbd9e1f2 100644 --- a/sw/source/filter/xml/xmltexti.cxx +++ b/sw/source/filter/xml/xmltexti.cxx @@ -241,7 +241,7 @@ uno::Reference< XPropertySet > SwXMLTextImportHelper::createAndInsertOLEObject( SwDoc *pDoc = SwImport::GetDocFromXMLImport( rImport ); SfxItemSet aItemSet( pDoc->GetAttrPool(), svl::Items<RES_FRMATR_BEGIN, - RES_FRMATR_END>{} ); + RES_FRMATR_END> ); Size aTwipSize( 0, 0 ); tools::Rectangle aVisArea( 0, 0, nWidth, nHeight ); lcl_putHeightAndWidth( aItemSet, nHeight, nWidth, @@ -553,7 +553,7 @@ uno::Reference< XPropertySet > SwXMLTextImportHelper::createAndInsertOOoLink( SwDoc *pDoc = SwImport::GetDocFromXMLImport( rImport ); SfxItemSet aItemSet( pDoc->GetAttrPool(), svl::Items<RES_FRMATR_BEGIN, - RES_FRMATR_END>{} ); + RES_FRMATR_END> ); Size aTwipSize( 0, 0 ); lcl_putHeightAndWidth( aItemSet, nHeight, nWidth, &aTwipSize ); @@ -645,7 +645,7 @@ uno::Reference< XPropertySet > SwXMLTextImportHelper::createAndInsertApplet( SwDoc *pDoc = pTextCursor->GetDoc(); SfxItemSet aItemSet( pDoc->GetAttrPool(), svl::Items<RES_FRMATR_BEGIN, - RES_FRMATR_END>{} ); + RES_FRMATR_END> ); lcl_putHeightAndWidth( aItemSet, nHeight, nWidth); SwApplet_Impl aAppletImpl ( aItemSet ); @@ -691,7 +691,7 @@ uno::Reference< XPropertySet > SwXMLTextImportHelper::createAndInsertPlugin( SwDoc *pDoc = pTextCursor->GetDoc(); SfxItemSet aItemSet( pDoc->GetAttrPool(), svl::Items<RES_FRMATR_BEGIN, - RES_FRMATR_END>{} ); + RES_FRMATR_END> ); lcl_putHeightAndWidth( aItemSet, nHeight, nWidth); // We'll need a (valid) URL, or we need a MIME type. If we don't have @@ -772,7 +772,7 @@ uno::Reference< XPropertySet > SwXMLTextImportHelper::createAndInsertFloatingFra SwDoc *pDoc = pTextCursor->GetDoc(); SfxItemSet aItemSet( pDoc->GetAttrPool(), svl::Items<RES_FRMATR_BEGIN, - RES_FRMATR_END>{} ); + RES_FRMATR_END> ); lcl_putHeightAndWidth( aItemSet, nHeight, nWidth); ScrollingMode eScrollMode = ScrollingMode::Auto; |