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 /sc | |
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 'sc')
37 files changed, 65 insertions, 65 deletions
diff --git a/sc/qa/unit/tiledrendering/tiledrendering.cxx b/sc/qa/unit/tiledrendering/tiledrendering.cxx index aed61f58a6cf..83791382d69c 100644 --- a/sc/qa/unit/tiledrendering/tiledrendering.cxx +++ b/sc/qa/unit/tiledrendering/tiledrendering.cxx @@ -1542,8 +1542,8 @@ void ScTiledRenderingTest::testDisableUndoRepair() SfxViewShell* pView2 = SfxViewShell::Current(); CPPUNIT_ASSERT(pView1 != pView2); { - SfxItemSet aSet1(pView1->GetPool(), svl::Items<SID_UNDO, SID_UNDO>{}); - SfxItemSet aSet2(pView2->GetPool(), svl::Items<SID_UNDO, SID_UNDO>{}); + SfxItemSet aSet1(pView1->GetPool(), svl::Items<SID_UNDO, SID_UNDO>); + SfxItemSet aSet2(pView2->GetPool(), svl::Items<SID_UNDO, SID_UNDO>); pView1->GetSlotState(SID_UNDO, nullptr, &aSet1); pView2->GetSlotState(SID_UNDO, nullptr, &aSet2); CPPUNIT_ASSERT_EQUAL(SfxItemState::DISABLED, aSet1.GetItemState(SID_UNDO)); @@ -1558,8 +1558,8 @@ void ScTiledRenderingTest::testDisableUndoRepair() pModelObj->postKeyEvent(LOK_KEYEVENT_KEYUP, 0, awt::Key::RETURN); Scheduler::ProcessEventsToIdle(); { - SfxItemSet aSet1(pView1->GetPool(), svl::Items<SID_UNDO, SID_UNDO>{}); - SfxItemSet aSet2(pView2->GetPool(), svl::Items<SID_UNDO, SID_UNDO>{}); + SfxItemSet aSet1(pView1->GetPool(), svl::Items<SID_UNDO, SID_UNDO>); + SfxItemSet aSet2(pView2->GetPool(), svl::Items<SID_UNDO, SID_UNDO>); pView1->GetSlotState(SID_UNDO, nullptr, &aSet1); pView2->GetSlotState(SID_UNDO, nullptr, &aSet2); CPPUNIT_ASSERT_EQUAL(SfxItemState::SET, aSet1.GetItemState(SID_UNDO)); @@ -1580,8 +1580,8 @@ void ScTiledRenderingTest::testDisableUndoRepair() pModelObj->postKeyEvent(LOK_KEYEVENT_KEYUP, 0, awt::Key::RETURN); Scheduler::ProcessEventsToIdle(); { - SfxItemSet aSet1(pView1->GetPool(), svl::Items<SID_UNDO, SID_UNDO>{}); - SfxItemSet aSet2(pView2->GetPool(), svl::Items<SID_UNDO, SID_UNDO>{}); + SfxItemSet aSet1(pView1->GetPool(), svl::Items<SID_UNDO, SID_UNDO>); + SfxItemSet aSet2(pView2->GetPool(), svl::Items<SID_UNDO, SID_UNDO>); pView1->GetSlotState(SID_UNDO, nullptr, &aSet1); pView2->GetSlotState(SID_UNDO, nullptr, &aSet2); CPPUNIT_ASSERT_EQUAL(SfxItemState::SET, aSet1.GetItemState(SID_UNDO)); diff --git a/sc/qa/unit/ucalc_formula.cxx b/sc/qa/unit/ucalc_formula.cxx index c13aadc566e8..1dd346d23e28 100644 --- a/sc/qa/unit/ucalc_formula.cxx +++ b/sc/qa/unit/ucalc_formula.cxx @@ -4589,7 +4589,7 @@ void TestFormula::testFormulaRefUpdateValidity() SfxUInt32Item aItem(ATTR_VALIDDATA, nIndex); ScPatternAttr aNewAttrs( - SfxItemSet(*m_pDoc->GetPool(), svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END>{})); + SfxItemSet(*m_pDoc->GetPool(), svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END>)); aNewAttrs.GetItemSet().Put(aItem); m_pDoc->ApplyPattern(0, 1, 0, aNewAttrs); diff --git a/sc/source/core/data/docpool.cxx b/sc/source/core/data/docpool.cxx index 6ad0c97574e1..ee4f81c337e4 100644 --- a/sc/source/core/data/docpool.cxx +++ b/sc/source/core/data/docpool.cxx @@ -208,7 +208,7 @@ ScDocumentPool::ScDocumentPool() ATTR_BORDER, ATTR_SHADOW, ATTR_LRSPACE, ATTR_ULSPACE, ATTR_PAGE_SIZE, ATTR_PAGE_SIZE, - ATTR_PAGE_ON, ATTR_PAGE_SHARED_FIRST>{} ); + ATTR_PAGE_ON, ATTR_PAGE_SHARED_FIRST> ); pGlobalBorderInnerAttr->SetLine(nullptr, SvxBoxInfoItemLine::HORI); pGlobalBorderInnerAttr->SetLine(nullptr, SvxBoxInfoItemLine::VERT); @@ -282,11 +282,11 @@ ScDocumentPool::ScDocumentPool() if ( ScGlobal::GetEmptyBrushItem() ) mvPoolDefaults[ ATTR_PATTERN - ATTR_STARTINDEX ] = - new ScPatternAttr( SfxItemSet( *this, svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END>{} ), + new ScPatternAttr( SfxItemSet( *this, svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END> ), ScResId(STR_STYLENAME_STANDARD) ); else mvPoolDefaults[ ATTR_PATTERN - ATTR_STARTINDEX ] = - new ScPatternAttr( SfxItemSet( *this, svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END>{} ), + new ScPatternAttr( SfxItemSet( *this, svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END> ), STRING_STANDARD ); // FIXME: without name? mvPoolDefaults[ ATTR_LRSPACE - ATTR_STARTINDEX ] = new SvxLRSpaceItem( ATTR_LRSPACE ); diff --git a/sc/source/core/data/documen8.cxx b/sc/source/core/data/documen8.cxx index d9321a6634cb..932b287beb2a 100644 --- a/sc/source/core/data/documen8.cxx +++ b/sc/source/core/data/documen8.cxx @@ -119,7 +119,7 @@ SfxPrinter* ScDocument::GetPrinter(bool bCreateIfNotExist) svl::Items<SID_PRINTER_NOTFOUND_WARN, SID_PRINTER_NOTFOUND_WARN, SID_PRINTER_CHANGESTODOC, SID_PRINTER_CHANGESTODOC, SID_PRINT_SELECTEDSHEET, SID_PRINT_SELECTEDSHEET, - SID_SCPRINTOPTIONS, SID_SCPRINTOPTIONS>{} ); + SID_SCPRINTOPTIONS, SID_SCPRINTOPTIONS> ); SfxPrinterChangeFlags nFlags = SfxPrinterChangeFlags::NONE; if (officecfg::Office::Common::Print::Warning::PaperOrientation::get()) diff --git a/sc/source/core/data/patattr.cxx b/sc/source/core/data/patattr.cxx index a73758288ce1..fb8e7aee033f 100644 --- a/sc/source/core/data/patattr.cxx +++ b/sc/source/core/data/patattr.cxx @@ -82,7 +82,7 @@ ScPatternAttr::ScPatternAttr( SfxItemSet&& pItemSet ) } ScPatternAttr::ScPatternAttr( SfxItemPool* pItemPool ) - : SfxSetItem ( ATTR_PATTERN, SfxItemSet( *pItemPool, svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END>{} ) ), + : SfxSetItem ( ATTR_PATTERN, SfxItemSet( *pItemPool, svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END> ) ), pStyle ( nullptr ), mnKey(0) { diff --git a/sc/source/core/data/stlsheet.cxx b/sc/source/core/data/stlsheet.cxx index 20f4399dd98b..883e222173ce 100644 --- a/sc/source/core/data/stlsheet.cxx +++ b/sc/source/core/data/stlsheet.cxx @@ -144,7 +144,7 @@ SfxItemSet& ScStyleSheet::GetItemSet() ATTR_WRITINGDIR, ATTR_WRITINGDIR, ATTR_BACKGROUND, ATTR_BACKGROUND, ATTR_BORDER, ATTR_SHADOW, - ATTR_LRSPACE, ATTR_PAGE_SCALETO>{} ); + ATTR_LRSPACE, ATTR_PAGE_SCALETO> ); // If being loaded also the set is then filled in from the file, // so the defaults do not need to be set. @@ -221,7 +221,7 @@ SfxItemSet& ScStyleSheet::GetItemSet() case SfxStyleFamily::Para: default: - pSet = new SfxItemSet( GetPool()->GetPool(), svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END>{} ); + pSet = new SfxItemSet( GetPool()->GetPool(), svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END> ); break; } bMySet = true; diff --git a/sc/source/core/data/table2.cxx b/sc/source/core/data/table2.cxx index 1074fe1f65a1..2af1cad94471 100644 --- a/sc/source/core/data/table2.cxx +++ b/sc/source/core/data/table2.cxx @@ -467,7 +467,7 @@ void ScTable::DeleteSelection( InsertDeleteFlags nDelFlag, const ScMarkData& rMa if ( IsProtected() && (nDelFlag & InsertDeleteFlags::ATTRIB) ) { ScDocumentPool* pPool = rDocument.GetPool(); - SfxItemSet aSet( *pPool, svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END>{} ); + SfxItemSet aSet( *pPool, svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END> ); aSet.Put( ScProtectionAttr( false ) ); SfxItemPoolCache aCache( pPool, &aSet ); ApplySelectionCache( &aCache, rMark ); diff --git a/sc/source/core/tool/detfunc.cxx b/sc/source/core/tool/detfunc.cxx index fc5014440645..8013ac29ab76 100644 --- a/sc/source/core/tool/detfunc.cxx +++ b/sc/source/core/tool/detfunc.cxx @@ -139,11 +139,11 @@ static bool lcl_HasThickLine( const SdrObject& rObj ) } ScDetectiveData::ScDetectiveData( SdrModel* pModel ) : - aBoxSet( pModel->GetItemPool(), svl::Items<SDRATTR_START, SDRATTR_END>{} ), - aArrowSet( pModel->GetItemPool(), svl::Items<SDRATTR_START, SDRATTR_END>{} ), - aToTabSet( pModel->GetItemPool(), svl::Items<SDRATTR_START, SDRATTR_END>{} ), - aFromTabSet( pModel->GetItemPool(), svl::Items<SDRATTR_START, SDRATTR_END>{} ), - aCircleSet( pModel->GetItemPool(), svl::Items<SDRATTR_START, SDRATTR_END>{} ), + aBoxSet( pModel->GetItemPool(), svl::Items<SDRATTR_START, SDRATTR_END> ), + aArrowSet( pModel->GetItemPool(), svl::Items<SDRATTR_START, SDRATTR_END> ), + aToTabSet( pModel->GetItemPool(), svl::Items<SDRATTR_START, SDRATTR_END> ), + aFromTabSet( pModel->GetItemPool(), svl::Items<SDRATTR_START, SDRATTR_END> ), + aCircleSet( pModel->GetItemPool(), svl::Items<SDRATTR_START, SDRATTR_END> ), nMaxLevel(0) { @@ -198,7 +198,7 @@ ScDetectiveData::ScDetectiveData( SdrModel* pModel ) : } ScCommentData::ScCommentData( ScDocument& rDoc, SdrModel* pModel ) : - aCaptionSet( pModel->GetItemPool(), svl::Items<SDRATTR_START, SDRATTR_END, EE_ITEMS_START, EE_ITEMS_END>{} ) + aCaptionSet( pModel->GetItemPool(), svl::Items<SDRATTR_START, SDRATTR_END, EE_ITEMS_START, EE_ITEMS_END> ) { basegfx::B2DPolygon aTriangle; aTriangle.append(basegfx::B2DPoint(10.0, 0.0)); diff --git a/sc/source/filter/excel/xehelper.cxx b/sc/source/filter/excel/xehelper.cxx index cae981a5e622..51e0fe9121d9 100644 --- a/sc/source/filter/excel/xehelper.cxx +++ b/sc/source/filter/excel/xehelper.cxx @@ -428,7 +428,7 @@ XclExpStringRef lclCreateFormattedString( // font buffer and helper item set for edit engine -> Calc item conversion XclExpFontBuffer& rFontBuffer = rRoot.GetFontBuffer(); - SfxItemSet aItemSet( *rRoot.GetDoc().GetPool(), svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END>{} ); + SfxItemSet aItemSet( *rRoot.GetDoc().GetPool(), svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END> ); // script type handling Reference< XBreakIterator > xBreakIt = rRoot.GetDoc().GetBreakIterator(); @@ -682,7 +682,7 @@ void XclExpHFConverter::AppendPortion( const EditTextObject* pTextObj, sal_Unico OUString aText; sal_Int32 nHeight = 0; - SfxItemSet aItemSet( *GetDoc().GetPool(), svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END>{} ); + SfxItemSet aItemSet( *GetDoc().GetPool(), svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END> ); // edit engine bool bOldUpdateMode = mrEE.GetUpdateMode(); diff --git a/sc/source/filter/excel/xlroot.cxx b/sc/source/filter/excel/xlroot.cxx index a965a5e16d2c..8d0b494b7806 100644 --- a/sc/source/filter/excel/xlroot.cxx +++ b/sc/source/filter/excel/xlroot.cxx @@ -381,7 +381,7 @@ ScHeaderEditEngine& XclRoot::GetHFEditEngine() const // set Calc header/footer defaults auto pEditSet = std::make_unique<SfxItemSet>( rEE.GetEmptyItemSet() ); - SfxItemSet aItemSet( *GetDoc().GetPool(), svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END>{} ); + SfxItemSet aItemSet( *GetDoc().GetPool(), svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END> ); ScPatternAttr::FillToEditItemSet( *pEditSet, aItemSet ); // FillToEditItemSet() adjusts font height to 1/100th mm, we need twips pEditSet->Put( aItemSet.Get( ATTR_FONT_HEIGHT ).CloneSetWhich(EE_CHAR_FONTHEIGHT) ); diff --git a/sc/source/ui/app/scmod.cxx b/sc/source/ui/app/scmod.cxx index bccf25f7ec9b..2c9d932f3690 100644 --- a/sc/source/ui/app/scmod.cxx +++ b/sc/source/ui/app/scmod.cxx @@ -349,7 +349,7 @@ void ScModule::Execute( SfxRequest& rReq ) bSet = !GetDocOptions().IsAutoSpell(); } - SfxItemSet aSet( GetPool(), svl::Items<SID_AUTOSPELL_CHECK, SID_AUTOSPELL_CHECK>{} ); + SfxItemSet aSet( GetPool(), svl::Items<SID_AUTOSPELL_CHECK, SID_AUTOSPELL_CHECK> ); aSet.Put( SfxBoolItem( SID_AUTOSPELL_CHECK, bSet ) ); ModifyOptions( aSet ); rReq.Done(); @@ -1891,7 +1891,7 @@ std::unique_ptr<SfxItemSet> ScModule::CreateItemSet( sal_uInt16 nId ) SID_SC_INPUT_TEXTWYSIWYG, SID_SC_INPUT_TEXTWYSIWYG, SID_SC_INPUT_REPLCELLSWARN, SID_SC_INPUT_REPLCELLSWARN, // TP_VIEW: - SID_SC_OPT_SYNCZOOM, SID_SC_OPT_KEY_BINDING_COMPAT>{}); + SID_SC_OPT_SYNCZOOM, SID_SC_OPT_KEY_BINDING_COMPAT>); const ScAppOptions& rAppOpt = GetAppOptions(); diff --git a/sc/source/ui/attrdlg/tabpages.cxx b/sc/source/ui/attrdlg/tabpages.cxx index 633db59f7688..899a56b011d9 100644 --- a/sc/source/ui/attrdlg/tabpages.cxx +++ b/sc/source/ui/attrdlg/tabpages.cxx @@ -26,7 +26,7 @@ #include <osl/diagnose.h> const WhichRangesContainer ScTabPageProtection::pProtectionRanges( - svl::Items<SID_SCATTR_PROTECTION, SID_SCATTR_PROTECTION>::value); + svl::Items<SID_SCATTR_PROTECTION, SID_SCATTR_PROTECTION>); // Zellschutz-Tabpage: diff --git a/sc/source/ui/dbgui/validate.cxx b/sc/source/ui/dbgui/validate.cxx index a3fca1d8822f..5fa84ab3d5cb 100644 --- a/sc/source/ui/dbgui/validate.cxx +++ b/sc/source/ui/dbgui/validate.cxx @@ -78,7 +78,7 @@ namespace ValidListType = css::sheet::TableValidationVisibility; const WhichRangesContainer ScTPValidationValue::pValueRanges(svl::Items< FID_VALID_LISTTYPE, FID_VALID_LISTTYPE, FID_VALID_MODE, FID_VALID_ERRTEXT ->::value); +>); ScValidationDlg::ScValidationDlg(weld::Window* pParent, const SfxItemSet* pArgSet, ScTabViewShell *pTabViewSh) diff --git a/sc/source/ui/docshell/docsh3.cxx b/sc/source/ui/docshell/docsh3.cxx index 39808c00aa3f..97f685fe1591 100644 --- a/sc/source/ui/docshell/docsh3.cxx +++ b/sc/source/ui/docshell/docsh3.cxx @@ -646,7 +646,7 @@ void ScDocShell::ExecuteChangeCommentDialog( ScChangeAction* pAction, weld::Wind ScGlobal::getLocaleDataPtr()->getTime( aDT, false ); SfxItemSet aSet( - GetPool(), svl::Items<SID_ATTR_POSTIT_AUTHOR, SID_ATTR_POSTIT_TEXT>{}); + GetPool(), svl::Items<SID_ATTR_POSTIT_AUTHOR, SID_ATTR_POSTIT_TEXT>); aSet.Put( SvxPostItTextItem ( aComment, SID_ATTR_POSTIT_TEXT ) ); aSet.Put( SvxPostItAuthorItem( aAuthor, SID_ATTR_POSTIT_AUTHOR ) ); diff --git a/sc/source/ui/drawfunc/drawsh.cxx b/sc/source/ui/drawfunc/drawsh.cxx index d843ae6984a3..93ece6954f56 100644 --- a/sc/source/ui/drawfunc/drawsh.cxx +++ b/sc/source/ui/drawfunc/drawsh.cxx @@ -198,7 +198,7 @@ void ScDrawShell::ExecDrawAttr( SfxRequest& rReq ) case SID_TEXT_STANDARD: // delete hard text attributes { - SfxItemSet aEmptyAttr(GetPool(), svl::Items<EE_ITEMS_START, EE_ITEMS_END>{}); + SfxItemSet aEmptyAttr(GetPool(), svl::Items<EE_ITEMS_START, EE_ITEMS_END>); pView->SetAttributes(aEmptyAttr, true); } break; @@ -442,7 +442,7 @@ void ScDrawShell::ExecuteMacroAssign(SdrObject* pObj, weld::Window* pWin) } // create empty itemset for macro-dlg - SfxItemSet aItemSet(SfxGetpApp()->GetPool(), svl::Items<SID_ATTR_MACROITEM, SID_ATTR_MACROITEM, SID_EVENTCONFIG, SID_EVENTCONFIG>{} ); + SfxItemSet aItemSet(SfxGetpApp()->GetPool(), svl::Items<SID_ATTR_MACROITEM, SID_ATTR_MACROITEM, SID_EVENTCONFIG, SID_EVENTCONFIG> ); aItemSet.Put ( aItem ); SfxEventNamesItem aNamesItem(SID_EVENTCONFIG); diff --git a/sc/source/ui/drawfunc/drawsh5.cxx b/sc/source/ui/drawfunc/drawsh5.cxx index 94e87dd29d27..baaf81d28e5b 100644 --- a/sc/source/ui/drawfunc/drawsh5.cxx +++ b/sc/source/ui/drawfunc/drawsh5.cxx @@ -455,7 +455,7 @@ void ScDrawShell::ExecDrawFunc( SfxRequest& rReq ) const SfxBoolItem* pItem = rReq.GetArg<SfxBoolItem>(SID_ENABLE_HYPHENATION); if( pItem ) { - SfxItemSet aSet( GetPool(), svl::Items<EE_PARA_HYPHENATE, EE_PARA_HYPHENATE>{} ); + SfxItemSet aSet( GetPool(), svl::Items<EE_PARA_HYPHENATE, EE_PARA_HYPHENATE> ); bool bValue = pItem->GetValue(); aSet.Put( SfxBoolItem( EE_PARA_HYPHENATE, bValue ) ); pView->SetAttributes( aSet ); diff --git a/sc/source/ui/drawfunc/drtxtob.cxx b/sc/source/ui/drawfunc/drtxtob.cxx index c9f09e6d74b2..553c6dc8370b 100644 --- a/sc/source/ui/drawfunc/drtxtob.cxx +++ b/sc/source/ui/drawfunc/drtxtob.cxx @@ -798,7 +798,7 @@ void ScDrawTextObjectBar::ExecuteAttr( SfxRequest &rReq ) if ( pOutView ) pOutView->Paint( tools::Rectangle() ); - SfxItemSet aEmptyAttr( *aEditAttr.GetPool(), svl::Items<EE_ITEMS_START, EE_ITEMS_END>{} ); + SfxItemSet aEmptyAttr( *aEditAttr.GetPool(), svl::Items<EE_ITEMS_START, EE_ITEMS_END> ); pView->SetAttributes( aEmptyAttr, true ); if ( pOutView ) @@ -922,7 +922,7 @@ void ScDrawTextObjectBar::ExecuteAttr( SfxRequest &rReq ) sal_uInt16 nId = SID_ATTR_PARA_LRSPACE; const SvxLRSpaceItem& rItem = static_cast<const SvxLRSpaceItem&>( pArgs->Get( nId )); - SfxItemSet aAttr( GetPool(), svl::Items<EE_PARA_LRSPACE, EE_PARA_LRSPACE>{} ); + SfxItemSet aAttr( GetPool(), svl::Items<EE_PARA_LRSPACE, EE_PARA_LRSPACE> ); nId = EE_PARA_LRSPACE; SvxLRSpaceItem aLRSpaceItem( rItem.GetLeft(), rItem.GetRight(), rItem.GetTextLeft(), @@ -934,7 +934,7 @@ void ScDrawTextObjectBar::ExecuteAttr( SfxRequest &rReq ) { SvxLineSpacingItem aLineSpaceItem = static_cast<const SvxLineSpacingItem&>(pArgs->Get( GetPool().GetWhich(nSlot))); - SfxItemSet aAttr( GetPool(), svl::Items<EE_PARA_SBL, EE_PARA_SBL>{} ); + SfxItemSet aAttr( GetPool(), svl::Items<EE_PARA_SBL, EE_PARA_SBL> ); aAttr.Put( aLineSpaceItem ); pView->SetAttributes( aAttr ); } @@ -942,7 +942,7 @@ void ScDrawTextObjectBar::ExecuteAttr( SfxRequest &rReq ) { SvxULSpaceItem aULSpaceItem = static_cast<const SvxULSpaceItem&>(pArgs->Get( GetPool().GetWhich(nSlot))); - SfxItemSet aAttr( GetPool(), svl::Items<EE_PARA_ULSPACE, EE_PARA_ULSPACE>{} ); + SfxItemSet aAttr( GetPool(), svl::Items<EE_PARA_ULSPACE, EE_PARA_ULSPACE> ); aULSpaceItem.SetWhich(EE_PARA_ULSPACE); aAttr.Put( aULSpaceItem ); pView->SetAttributes( aAttr ); diff --git a/sc/source/ui/drawfunc/drtxtob1.cxx b/sc/source/ui/drawfunc/drtxtob1.cxx index 2e3a76d9f425..077c5209ae28 100644 --- a/sc/source/ui/drawfunc/drtxtob1.cxx +++ b/sc/source/ui/drawfunc/drtxtob1.cxx @@ -68,7 +68,7 @@ bool ScDrawTextObjectBar::ExecuteParaDlg( const SfxItemSet& rArgs, *pArgPool, svl::Items< EE_ITEMS_START, EE_ITEMS_END, - SID_ATTR_PARA_PAGEBREAK, SID_ATTR_PARA_WIDOWS>{}); + SID_ATTR_PARA_PAGEBREAK, SID_ATTR_PARA_WIDOWS>); aNewAttr.Put( rArgs ); // Values have been taken over once to show the dialog. diff --git a/sc/source/ui/drawfunc/drtxtob2.cxx b/sc/source/ui/drawfunc/drtxtob2.cxx index 5dbfb4ade3d5..a09f59718de8 100644 --- a/sc/source/ui/drawfunc/drtxtob2.cxx +++ b/sc/source/ui/drawfunc/drtxtob2.cxx @@ -82,7 +82,7 @@ void ScDrawTextObjectBar::ExecuteGlobal( SfxRequest &rReq ) case SID_TEXTDIRECTION_LEFT_TO_RIGHT: case SID_TEXTDIRECTION_TOP_TO_BOTTOM: { - SfxItemSet aAttr( pView->GetModel()->GetItemPool(), svl::Items<SDRATTR_TEXTDIRECTION, SDRATTR_TEXTDIRECTION>{} ); + SfxItemSet aAttr( pView->GetModel()->GetItemPool(), svl::Items<SDRATTR_TEXTDIRECTION, SDRATTR_TEXTDIRECTION> ); aAttr.Put( SvxWritingModeItem( nSlot == SID_TEXTDIRECTION_LEFT_TO_RIGHT ? css::text::WritingMode_LR_TB : css::text::WritingMode_TB_RL, @@ -98,7 +98,7 @@ void ScDrawTextObjectBar::ExecuteGlobal( SfxRequest &rReq ) const SfxBoolItem* pItem = rReq.GetArg<SfxBoolItem>(SID_ENABLE_HYPHENATION); if( pItem ) { - SfxItemSet aSet( GetPool(), svl::Items<EE_PARA_HYPHENATE, EE_PARA_HYPHENATE>{} ); + SfxItemSet aSet( GetPool(), svl::Items<EE_PARA_HYPHENATE, EE_PARA_HYPHENATE> ); bool bValue = pItem->GetValue(); aSet.Put( SfxBoolItem( EE_PARA_HYPHENATE, bValue ) ); pView->SetAttributes( aSet ); @@ -155,7 +155,7 @@ void ScDrawTextObjectBar::ExecuteExtra( SfxRequest &rReq ) { SfxItemSet aAttr( pView->GetModel()->GetItemPool(), svl::Items<EE_PARA_WRITINGDIR, EE_PARA_WRITINGDIR, - EE_PARA_JUST, EE_PARA_JUST>{} ); + EE_PARA_JUST, EE_PARA_JUST> ); bool bLeft = ( nSlot == SID_ATTR_PARA_LEFT_TO_RIGHT ); aAttr.Put( SvxFrameDirectionItem( bLeft ? SvxFrameDirection::Horizontal_LR_TB : SvxFrameDirection::Horizontal_RL_TB, diff --git a/sc/source/ui/drawfunc/fuconcustomshape.cxx b/sc/source/ui/drawfunc/fuconcustomshape.cxx index a3888f166d31..b9cea7984a97 100644 --- a/sc/source/ui/drawfunc/fuconcustomshape.cxx +++ b/sc/source/ui/drawfunc/fuconcustomshape.cxx @@ -169,7 +169,7 @@ void FuConstCustomShape::SetAttributes( SdrObject* pObj ) SDRATTR_GRAF_FIRST, SDRATTR_CUSTOMSHAPE_LAST, // Range from SdrTextObj: - EE_ITEMS_START, EE_ITEMS_END>{}); + EE_ITEMS_START, EE_ITEMS_END>); aDest.Set( rSource ); pObj->SetMergedItemSet( aDest ); Degree100 nAngle = pSourceObj->GetRotateAngle(); diff --git a/sc/source/ui/drawfunc/futext.cxx b/sc/source/ui/drawfunc/futext.cxx index 27eeab0e09e9..e80ecb39bbf3 100644 --- a/sc/source/ui/drawfunc/futext.cxx +++ b/sc/source/ui/drawfunc/futext.cxx @@ -395,7 +395,7 @@ bool FuText::MouseButtonUp(const MouseEvent& rMEvt) // set needed attributes for scrolling SfxItemSet aItemSet( pDrDoc->GetItemPool(), - svl::Items<SDRATTR_MISC_FIRST, SDRATTR_MISC_LAST>{}); + svl::Items<SDRATTR_MISC_FIRST, SDRATTR_MISC_LAST>); aItemSet.Put( makeSdrTextAutoGrowWidthItem( false ) ); aItemSet.Put( makeSdrTextAutoGrowHeightItem( false ) ); @@ -662,7 +662,7 @@ SdrObjectUniquePtr FuText::CreateDefaultObject(const sal_uInt16 nID, const tools if(bMarquee) { - SfxItemSet aSet(pDrDoc->GetItemPool(), svl::Items<SDRATTR_MISC_FIRST, SDRATTR_MISC_LAST>{}); + SfxItemSet aSet(pDrDoc->GetItemPool(), svl::Items<SDRATTR_MISC_FIRST, SDRATTR_MISC_LAST>); aSet.Put( makeSdrTextAutoGrowWidthItem( false ) ); aSet.Put( makeSdrTextAutoGrowHeightItem( false ) ); diff --git a/sc/source/ui/pagedlg/tphf.cxx b/sc/source/ui/pagedlg/tphf.cxx index b62fca5feeaa..bc4457870c76 100644 --- a/sc/source/ui/pagedlg/tphf.cxx +++ b/sc/source/ui/pagedlg/tphf.cxx @@ -42,7 +42,7 @@ ScHFPage::ScHFPage(weld::Container* pPage, weld::DialogController* pController, const SfxItemSet& rSet, sal_uInt16 nSetId) : SvxHFPage(pPage, pController, rSet, nSetId) - , aDataSet(*rSet.GetPool(), svl::Items<ATTR_PAGE, ATTR_PAGE, ATTR_PAGE_HEADERLEFT, ATTR_PAGE_FOOTERFIRST>{}) + , aDataSet(*rSet.GetPool(), svl::Items<ATTR_PAGE, ATTR_PAGE, ATTR_PAGE_HEADERLEFT, ATTR_PAGE_FOOTERFIRST>) , nPageUsage(SvxPageUsage::All) , pStyleDlg(nullptr) , m_xBtnEdit(m_xBuilder->weld_button("buttonEdit")) diff --git a/sc/source/ui/pagedlg/tptable.cxx b/sc/source/ui/pagedlg/tptable.cxx index cb4c19c4d549..de63dd437fc7 100644 --- a/sc/source/ui/pagedlg/tptable.cxx +++ b/sc/source/ui/pagedlg/tptable.cxx @@ -31,7 +31,7 @@ // Static Data const WhichRangesContainer ScTablePage::pPageTableRanges( - svl::Items<ATTR_PAGE_NOTES, ATTR_PAGE_FIRSTPAGENO>::value); + svl::Items<ATTR_PAGE_NOTES, ATTR_PAGE_FIRSTPAGENO>); static bool lcl_PutVObjModeItem(sal_uInt16 nWhich, SfxItemSet& rCoreSet, diff --git a/sc/source/ui/unoobj/confuno.cxx b/sc/source/ui/unoobj/confuno.cxx index 2f9550812260..6c52c2c3ddf7 100644 --- a/sc/source/ui/unoobj/confuno.cxx +++ b/sc/source/ui/unoobj/confuno.cxx @@ -242,7 +242,7 @@ void SAL_CALL ScDocumentConfiguration::setPropertyValue( svl::Items<SID_PRINTER_NOTFOUND_WARN, SID_PRINTER_NOTFOUND_WARN, SID_PRINTER_CHANGESTODOC, SID_PRINTER_CHANGESTODOC, SID_PRINT_SELECTEDSHEET, SID_PRINT_SELECTEDSHEET, - SID_SCPRINTOPTIONS, SID_SCPRINTOPTIONS>{} ); + SID_SCPRINTOPTIONS, SID_SCPRINTOPTIONS> ); SfxPrinter* pPrinter = pDocShell->GetPrinter(); bool bPreferPrinterPapersize = false; diff --git a/sc/source/ui/view/cellsh1.cxx b/sc/source/ui/view/cellsh1.cxx index 1fac839ac367..fa0b55d75e66 100644 --- a/sc/source/ui/view/cellsh1.cxx +++ b/sc/source/ui/view/cellsh1.cxx @@ -3272,7 +3272,7 @@ void ScCellShell::ExecuteSubtotals(SfxRequest& rReq) ScopedVclPtr<SfxAbstractTabDialog> pDlg; ScSubTotalParam aSubTotalParam; - SfxItemSet aArgSet( GetPool(), svl::Items<SCITEM_SUBTDATA, SCITEM_SUBTDATA>{} ); + SfxItemSet aArgSet( GetPool(), svl::Items<SCITEM_SUBTDATA, SCITEM_SUBTDATA> ); bool bAnonymous; diff --git a/sc/source/ui/view/cellsh2.cxx b/sc/source/ui/view/cellsh2.cxx index b8ba37cc9244..241477511629 100644 --- a/sc/source/ui/view/cellsh2.cxx +++ b/sc/source/ui/view/cellsh2.cxx @@ -500,7 +500,7 @@ void ScCellShell::ExecuteDB( SfxRequest& rReq ) if( lcl_GetSortParam( rData, aSortParam ) ) { ScDocument& rDoc = GetViewData().GetDocument(); - SfxItemSet aArgSet( GetPool(), svl::Items<SCITEM_SORTDATA, SCITEM_SORTDATA>{} ); + SfxItemSet aArgSet( GetPool(), svl::Items<SCITEM_SORTDATA, SCITEM_SORTDATA> ); pDBData->GetSortParam( aSortParam ); bool bHasHeader = rDoc.HasColHeader( aSortParam.nCol1, aSortParam.nRow1, aSortParam.nCol2, aSortParam.nRow2, rData.GetTabNo() ); diff --git a/sc/source/ui/view/cellsh3.cxx b/sc/source/ui/view/cellsh3.cxx index 25c808886443..e3f9c79368e0 100644 --- a/sc/source/ui/view/cellsh3.cxx +++ b/sc/source/ui/view/cellsh3.cxx @@ -456,11 +456,11 @@ void ScCellShell::Execute( SfxRequest& rReq ) SfxItemSet aEmptySet( *pReqArgs->GetPool(), svl::Items<ATTR_PATTERN_START, - ATTR_PATTERN_END>{} ); + ATTR_PATTERN_END> ); SfxItemSet aNewSet( *pReqArgs->GetPool(), svl::Items<ATTR_PATTERN_START, - ATTR_PATTERN_END>{} ); + ATTR_PATTERN_END> ); const SfxPoolItem* pAttr = nullptr; sal_uInt16 nWhich = 0; diff --git a/sc/source/ui/view/drawview.cxx b/sc/source/ui/view/drawview.cxx index c8829737f589..61261477a109 100644 --- a/sc/source/ui/view/drawview.cxx +++ b/sc/source/ui/view/drawview.cxx @@ -1136,7 +1136,7 @@ SdrObject* ScDrawView::ApplyGraphicToObject( { AddUndo(std::make_unique<SdrUndoAttrObj>(rHitObject)); - SfxItemSet aSet(GetModel()->GetItemPool(), svl::Items<XATTR_FILLSTYLE, XATTR_FILLBITMAP>{}); + SfxItemSet aSet(GetModel()->GetItemPool(), svl::Items<XATTR_FILLSTYLE, XATTR_FILLBITMAP>); aSet.Put(XFillStyleItem(drawing::FillStyle_BITMAP)); aSet.Put(XFillBitmapItem(OUString(), rGraphic)); diff --git a/sc/source/ui/view/formatsh.cxx b/sc/source/ui/view/formatsh.cxx index a418f3185c8a..cb67ced9817f 100644 --- a/sc/source/ui/view/formatsh.cxx +++ b/sc/source/ui/view/formatsh.cxx @@ -1233,7 +1233,7 @@ void ScFormatShell::ExecuteNumFormat( SfxRequest& rReq ) const SfxItemSet& rOldSet = pTabViewShell->GetSelectionPattern()->GetItemSet(); SfxItemPool* pDocPool = GetViewData().GetDocument().GetPool(); - SfxItemSet aNewSet( *pDocPool, svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END>{} ); + SfxItemSet aNewSet( *pDocPool, svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END> ); aNewSet.Put( *pItem ); pTabViewShell->ApplyAttributes( &aNewSet, &rOldSet ); } @@ -1899,10 +1899,10 @@ void ScFormatShell::ExecuteAttr( SfxRequest& rReq ) const ScPatternAttr* pOldAttrs = pTabViewShell->GetSelectionPattern(); SfxItemSet aOldSet( *rDoc.GetPool(), svl::Items<ATTR_PATTERN_START, - ATTR_PATTERN_END>{} ); + ATTR_PATTERN_END> ); SfxItemSet aNewSet( *rDoc.GetPool(), svl::Items<ATTR_PATTERN_START, - ATTR_PATTERN_END>{} ); + ATTR_PATTERN_END> ); const SfxPoolItem& rBorderAttr = pOldAttrs->GetItemSet(). Get( ATTR_BORDER ); diff --git a/sc/source/ui/view/gridwin2.cxx b/sc/source/ui/view/gridwin2.cxx index bf1b7597b185..f9a29bb3b5d7 100644 --- a/sc/source/ui/view/gridwin2.cxx +++ b/sc/source/ui/view/gridwin2.cxx @@ -196,7 +196,7 @@ void ScGridWindow::DoPushPivotButton( SCCOL nCol, SCROW nRow, const MouseEvent& } SfxItemSet aArgSet( mrViewData.GetViewShell()->GetPool(), - svl::Items<SCITEM_QUERYDATA, SCITEM_QUERYDATA>{} ); + svl::Items<SCITEM_QUERYDATA, SCITEM_QUERYDATA> ); aArgSet.Put( ScQueryItem( SCITEM_QUERYDATA, &mrViewData, &aQueryParam ) ); ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create(); diff --git a/sc/source/ui/view/gridwin3.cxx b/sc/source/ui/view/gridwin3.cxx index ae60b18a5cbf..25d8eb0729c6 100644 --- a/sc/source/ui/view/gridwin3.cxx +++ b/sc/source/ui/view/gridwin3.cxx @@ -340,7 +340,7 @@ void ScGridWindow::UpdateStatusPosSize() if (!pPV) return; // shouldn't be called in that case either - SfxItemSet aSet(mrViewData.GetViewShell()->GetPool(), svl::Items<SID_ATTR_POSITION, SID_ATTR_SIZE>{}); + SfxItemSet aSet(mrViewData.GetViewShell()->GetPool(), svl::Items<SID_ATTR_POSITION, SID_ATTR_SIZE>); // Fill items for position and size: // show action rectangle during action, diff --git a/sc/source/ui/view/pivotsh.cxx b/sc/source/ui/view/pivotsh.cxx index 654ad6f279f8..eb21ece4e33c 100644 --- a/sc/source/ui/view/pivotsh.cxx +++ b/sc/source/ui/view/pivotsh.cxx @@ -95,7 +95,7 @@ void ScPivotShell::Execute( const SfxRequest& rReq ) ScViewData& rViewData = pViewShell->GetViewData(); SfxItemSet aArgSet( pViewShell->GetPool(), - svl::Items<SCITEM_QUERYDATA, SCITEM_QUERYDATA>{} ); + svl::Items<SCITEM_QUERYDATA, SCITEM_QUERYDATA> ); aArgSet.Put( ScQueryItem( SCITEM_QUERYDATA, &rViewData, &aQueryParam ) ); ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create(); diff --git a/sc/source/ui/view/prevwsh.cxx b/sc/source/ui/view/prevwsh.cxx index c2495c24386f..56f0277e03ff 100644 --- a/sc/source/ui/view/prevwsh.cxx +++ b/sc/source/ui/view/prevwsh.cxx @@ -635,7 +635,7 @@ void ScPreviewShell::Execute( SfxRequest& rReq ) } else { - SfxItemSet aSet ( GetPool(), svl::Items<SID_ATTR_ZOOM, SID_ATTR_ZOOM>{} ); + SfxItemSet aSet ( GetPool(), svl::Items<SID_ATTR_ZOOM, SID_ATTR_ZOOM> ); SvxZoomItem aZoomItem( SvxZoomType::PERCENT, pPreview->GetZoom(), SID_ATTR_ZOOM ); aSet.Put( aZoomItem ); diff --git a/sc/source/ui/view/tabvwsh3.cxx b/sc/source/ui/view/tabvwsh3.cxx index 7bbbd9647a4e..e0b5a6e2d44a 100644 --- a/sc/source/ui/view/tabvwsh3.cxx +++ b/sc/source/ui/view/tabvwsh3.cxx @@ -756,7 +756,7 @@ void ScTabViewShell::Execute( SfxRequest& rReq ) } else { - SfxItemSet aSet ( GetPool(), svl::Items<SID_ATTR_ZOOM, SID_ATTR_ZOOM>{} ); + SfxItemSet aSet ( GetPool(), svl::Items<SID_ATTR_ZOOM, SID_ATTR_ZOOM> ); SvxZoomItem aZoomItem( eOldZoomType, nOldZoom, SID_ATTR_ZOOM ); ScopedVclPtr<AbstractSvxZoomDialog> pDlg; ScMarkData& rMark = GetViewData().GetMarkData(); diff --git a/sc/source/ui/view/tabvwshc.cxx b/sc/source/ui/view/tabvwshc.cxx index 2249f25decb2..43313394b2b5 100644 --- a/sc/source/ui/view/tabvwshc.cxx +++ b/sc/source/ui/view/tabvwshc.cxx @@ -276,7 +276,7 @@ std::shared_ptr<SfxModelessDialogController> ScTabViewShell::CreateRefDialogCont { SfxItemSet aArgSet( GetPool(), svl::Items<SCITEM_CONSOLIDATEDATA, - SCITEM_CONSOLIDATEDATA>{} ); + SCITEM_CONSOLIDATEDATA> ); const ScConsolidateParam* pDlgData = rDoc.GetConsolidateDlgData(); @@ -315,7 +315,7 @@ std::shared_ptr<SfxModelessDialogController> ScTabViewShell::CreateRefDialogCont ScQueryParam aQueryParam; SfxItemSet aArgSet( GetPool(), svl::Items<SCITEM_QUERYDATA, - SCITEM_QUERYDATA>{} ); + SCITEM_QUERYDATA> ); ScDBData* pDBData = GetDBData(false, SC_DB_MAKE, ScGetDBSelection::RowDown); pDBData->ExtendDataArea(rDoc); @@ -340,7 +340,7 @@ std::shared_ptr<SfxModelessDialogController> ScTabViewShell::CreateRefDialogCont ScQueryParam aQueryParam; SfxItemSet aArgSet( GetPool(), svl::Items<SCITEM_QUERYDATA, - SCITEM_QUERYDATA>{} ); + SCITEM_QUERYDATA> ); ScDBData* pDBData = GetDBData(false, SC_DB_MAKE, ScGetDBSelection::RowDown); pDBData->ExtendDataArea(rDoc); diff --git a/sc/source/ui/view/viewfun2.cxx b/sc/source/ui/view/viewfun2.cxx index b87e60becb3f..293199e4c455 100644 --- a/sc/source/ui/view/viewfun2.cxx +++ b/sc/source/ui/view/viewfun2.cxx @@ -3334,10 +3334,10 @@ void ScViewFunc::SetSelectionFrameLines( const SvxBorderLine* pLine, { SfxItemSet aOldSet( *rDoc.GetPool(), svl::Items<ATTR_PATTERN_START, - ATTR_PATTERN_END>{} ); + ATTR_PATTERN_END> ); SfxItemSet aNewSet(*rDoc.GetPool(), svl::Items<ATTR_PATTERN_START, - ATTR_PATTERN_END>{} ); + ATTR_PATTERN_END> ); SvxBorderLine aLine; diff --git a/sc/source/ui/view/viewfunc.cxx b/sc/source/ui/view/viewfunc.cxx index acea298aab32..22f2d26cd98a 100644 --- a/sc/source/ui/view/viewfunc.cxx +++ b/sc/source/ui/view/viewfunc.cxx @@ -1006,7 +1006,7 @@ void ScViewFunc::ApplyAttr( const SfxPoolItem& rAttrItem, bool bAdjustBlockHeigh } ScPatternAttr aNewAttrs( SfxItemSet( *GetViewData().GetDocument().GetPool(), - svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END>{} ) ); + svl::Items<ATTR_PATTERN_START, ATTR_PATTERN_END> ) ); aNewAttrs.GetItemSet().Put( rAttrItem ); // if justify is set (with Buttons), always indentation 0 |