From b1668edf7fa3ad8c32bcc4d73821770f2df011ca Mon Sep 17 00:00:00 2001 From: Mike Kaganski <mike.kaganski@collabora.com> Date: Mon, 19 Jul 2021 11:04:45 +0300 Subject: 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> --- sw/source/uibase/shells/textsh.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'sw/source/uibase/shells/textsh.cxx') diff --git a/sw/source/uibase/shells/textsh.cxx b/sw/source/uibase/shells/textsh.cxx index 12f6f8d9bdad..0f19e33153d9 100644 --- a/sw/source/uibase/shells/textsh.cxx +++ b/sw/source/uibase/shells/textsh.cxx @@ -634,7 +634,7 @@ void SwTextShell::StateInsert( SfxItemSet &rSet ) case SID_HYPERLINK_GETLINK: { - SfxItemSet aSet(GetPool(), svl::Items<RES_TXTATR_INETFMT, RES_TXTATR_INETFMT>{}); + SfxItemSet aSet(GetPool(), svl::Items<RES_TXTATR_INETFMT, RES_TXTATR_INETFMT>); rSh.GetCurAttr( aSet ); SvxHyperlinkItem aHLinkItem; @@ -845,7 +845,7 @@ SfxItemSet SwTextShell::CreateInsertFrameItemSet(SwFlyFrameAttrMgr& rMgr) SID_COLOR_TABLE, SID_PATTERN_LIST, SID_HTML_MODE, SID_HTML_MODE, FN_GET_PRINT_AREA, FN_GET_PRINT_AREA, - FN_SET_FRM_NAME, FN_SET_FRM_NAME>{}); + FN_SET_FRM_NAME, FN_SET_FRM_NAME>); aSet.Put(SfxUInt16Item(SID_HTML_MODE, ::GetHtmlMode(GetView().GetDocShell()))); // For the Area tab page. @@ -895,7 +895,7 @@ void SwTextShell::InsertSymbol( SfxRequest& rReq ) SwWrtShell &rSh = GetShell(); SfxItemSet aSet( GetPool(), svl::Items<RES_CHRATR_FONT, RES_CHRATR_FONT, RES_CHRATR_CJK_FONT, RES_CHRATR_CJK_FONT, - RES_CHRATR_CTL_FONT, RES_CHRATR_CTL_FONT>{} ); + RES_CHRATR_CTL_FONT, RES_CHRATR_CTL_FONT> ); rSh.GetCurAttr( aSet ); SvtScriptType nScript = rSh.GetScriptType(); @@ -987,7 +987,7 @@ void SwTextShell::InsertSymbol( SfxRequest& rReq ) SfxItemSet aRestoreSet( GetPool(), svl::Items<RES_CHRATR_FONT, RES_CHRATR_FONT, RES_CHRATR_CJK_FONT, RES_CHRATR_CJK_FONT, - RES_CHRATR_CTL_FONT, RES_CHRATR_CTL_FONT>{} ); + RES_CHRATR_CTL_FONT, RES_CHRATR_CTL_FONT> ); nScript = g_pBreakIt->GetAllScriptsOfText( aChars ); if( SvtScriptType::LATIN & nScript ) -- cgit