diff options
author | Gabor Kelemen <kelemen.gabor2@nisz.hu> | 2019-02-04 20:41:49 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.com> | 2019-02-08 12:30:06 +0100 |
commit | 43635b474cdce65e64fa9ca9d27a3cee6d96d50b (patch) | |
tree | 04d4223ebf161e2dc83f0842a1a81cef76d784d6 /xmloff/source/style | |
parent | 2d6313a9fac81340883b24fe3651781d31c6039d (diff) |
o3tl::make_unique -> std::make_unique in tools..xmloff
Since it is now possible to use C++14, it's time to replace
the temporary solution with the standard one
Change-Id: Ib3201f865d43f372007cdf381c7e244e9cbeae26
Reviewed-on: https://gerrit.libreoffice.org/67474
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Diffstat (limited to 'xmloff/source/style')
-rw-r--r-- | xmloff/source/style/impastpl.cxx | 8 | ||||
-rw-r--r-- | xmloff/source/style/xmlnumfi.cxx | 16 | ||||
-rw-r--r-- | xmloff/source/style/xmlnumi.cxx | 3 | ||||
-rw-r--r-- | xmloff/source/style/xmlstyle.cxx | 3 | ||||
-rw-r--r-- | xmloff/source/style/xmltabi.cxx | 3 |
5 files changed, 14 insertions, 19 deletions
diff --git a/xmloff/source/style/impastpl.cxx b/xmloff/source/style/impastpl.cxx index 7a5d0cba4292..5ae6085fec2f 100644 --- a/xmloff/source/style/impastpl.cxx +++ b/xmloff/source/style/impastpl.cxx @@ -35,7 +35,7 @@ #include <xmloff/xmltoken.hxx> #include "impastpl.hxx" -#include <o3tl/make_unique.hxx> + using namespace ::std; using namespace ::com::sun::star; @@ -430,7 +430,7 @@ void SvXMLAutoStylePoolP_Impl::AddFamily( } #endif - m_FamilySet.insert(o3tl::make_unique<XMLAutoStyleFamily>(nFamily, rStrName, rMapper, aPrefix, bAsFamily)); + m_FamilySet.insert(std::make_unique<XMLAutoStyleFamily>(nFamily, rStrName, rMapper, aPrefix, bAsFamily)); } void SvXMLAutoStylePoolP_Impl::SetFamilyPropSetMapper( @@ -515,7 +515,7 @@ bool SvXMLAutoStylePoolP_Impl::Add( if (it2 == rFamily.m_ParentSet.end()) { std::pair<XMLAutoStyleFamily::ParentSetType::iterator,bool> r = - rFamily.m_ParentSet.insert(o3tl::make_unique<XMLAutoStylePoolParent>( + rFamily.m_ParentSet.insert(std::make_unique<XMLAutoStylePoolParent>( rParentName)); it2 = r.first; } @@ -549,7 +549,7 @@ bool SvXMLAutoStylePoolP_Impl::AddNamed( if (it2 == rFamily.m_ParentSet.end()) { std::pair<XMLAutoStyleFamily::ParentSetType::iterator,bool> r = - rFamily.m_ParentSet.insert(o3tl::make_unique<XMLAutoStylePoolParent>( + rFamily.m_ParentSet.insert(std::make_unique<XMLAutoStylePoolParent>( rParentName)); it2 = r.first; } diff --git a/xmloff/source/style/xmlnumfi.cxx b/xmloff/source/style/xmlnumfi.cxx index 9294bf9f7fbb..1a7b81c6f311 100644 --- a/xmloff/source/style/xmlnumfi.cxx +++ b/xmloff/source/style/xmlnumfi.cxx @@ -17,8 +17,6 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ -#include <o3tl/make_unique.hxx> - #include <unotools/syslocale.hxx> #include <svl/zforlist.hxx> @@ -442,7 +440,7 @@ const SvXMLTokenMap& SvXMLNumImpData::GetStylesElemTokenMap() XML_TOKEN_MAP_END }; - pStylesElemTokenMap = o3tl::make_unique<SvXMLTokenMap>( aStylesElemMap ); + pStylesElemTokenMap = std::make_unique<SvXMLTokenMap>( aStylesElemMap ); } return *pStylesElemTokenMap; } @@ -480,7 +478,7 @@ const SvXMLTokenMap& SvXMLNumImpData::GetStyleElemTokenMap() XML_TOKEN_MAP_END }; - pStyleElemTokenMap = o3tl::make_unique<SvXMLTokenMap>( aStyleElemMap ); + pStyleElemTokenMap = std::make_unique<SvXMLTokenMap>( aStyleElemMap ); } return *pStyleElemTokenMap; } @@ -513,7 +511,7 @@ const SvXMLTokenMap& SvXMLNumImpData::GetStyleAttrTokenMap() XML_TOKEN_MAP_END }; - pStyleAttrTokenMap = o3tl::make_unique<SvXMLTokenMap>( aStyleAttrMap ); + pStyleAttrTokenMap = std::make_unique<SvXMLTokenMap>( aStyleAttrMap ); } return *pStyleAttrTokenMap; } @@ -559,7 +557,7 @@ const SvXMLTokenMap& SvXMLNumImpData::GetStyleElemAttrTokenMap() XML_TOKEN_MAP_END }; - pStyleElemAttrTokenMap = o3tl::make_unique<SvXMLTokenMap>( aStyleElemAttrMap ); + pStyleElemAttrTokenMap = std::make_unique<SvXMLTokenMap>( aStyleElemAttrMap ); } return *pStyleElemAttrTokenMap; } @@ -567,7 +565,7 @@ const SvXMLTokenMap& SvXMLNumImpData::GetStyleElemAttrTokenMap() const LocaleDataWrapper& SvXMLNumImpData::GetLocaleData( LanguageType nLang ) { if ( !pLocaleData ) - pLocaleData = o3tl::make_unique<LocaleDataWrapper>( + pLocaleData = std::make_unique<LocaleDataWrapper>( pFormatter ? pFormatter->GetComponentContext() : m_xContext, LanguageTag( nLang ) ); else @@ -2269,7 +2267,7 @@ SvXMLNumFmtHelper::SvXMLNumFmtHelper( if (pObj) pFormatter = pObj->GetNumberFormatter(); - pData = o3tl::make_unique<SvXMLNumImpData>( pFormatter, rxContext ); + pData = std::make_unique<SvXMLNumImpData>( pFormatter, rxContext ); } SvXMLNumFmtHelper::SvXMLNumFmtHelper( @@ -2278,7 +2276,7 @@ SvXMLNumFmtHelper::SvXMLNumFmtHelper( { SAL_WARN_IF( !rxContext.is(), "xmloff", "got no service manager" ); - pData = o3tl::make_unique<SvXMLNumImpData>( pNumberFormatter, rxContext ); + pData = std::make_unique<SvXMLNumImpData>( pNumberFormatter, rxContext ); } SvXMLNumFmtHelper::~SvXMLNumFmtHelper() diff --git a/xmloff/source/style/xmlnumi.cxx b/xmloff/source/style/xmlnumi.cxx index 2accb68325db..02e58ba4ecad 100644 --- a/xmloff/source/style/xmlnumi.cxx +++ b/xmloff/source/style/xmlnumi.cxx @@ -34,7 +34,6 @@ #include <com/sun/star/container/XIndexReplace.hpp> #include <o3tl/any.hxx> -#include <o3tl/make_unique.hxx> #include <rtl/ustrbuf.hxx> #include <sal/log.hxx> #include <osl/diagnose.h> @@ -1044,7 +1043,7 @@ SvXMLImportContextRef SvxXMLListStyleContext::CreateChildContext( new SvxXMLListLevelStyleContext_Impl( GetImport(), nPrefix, rLocalName, xAttrList )}; if( !pLevelStyles ) - pLevelStyles = o3tl::make_unique<SvxXMLListStyle_Impl>(); + pLevelStyles = std::make_unique<SvxXMLListStyle_Impl>(); pLevelStyles->push_back( xLevelStyle ); xContext = xLevelStyle.get(); diff --git a/xmloff/source/style/xmlstyle.cxx b/xmloff/source/style/xmlstyle.cxx index d2a4435cd643..34a46f401a7d 100644 --- a/xmloff/source/style/xmlstyle.cxx +++ b/xmloff/source/style/xmlstyle.cxx @@ -29,7 +29,6 @@ #include <com/sun/star/style/XAutoStylesSupplier.hpp> #include <com/sun/star/style/XAutoStyleFamily.hpp> #include "PageMasterPropMapper.hxx" -#include <o3tl/make_unique.hxx> #include <sal/log.hxx> #include <svl/itemset.hxx> #include <svl/style.hxx> @@ -299,7 +298,7 @@ const SvXMLStyleContext *SvXMLStylesContext_Impl::FindStyleChildContext( sal_uIn if( !pIndices && bCreateIndex && !aStyles.empty() ) { - pIndices = o3tl::make_unique<IndicesType>(aStyles.begin(), aStyles.end()); + pIndices = std::make_unique<IndicesType>(aStyles.begin(), aStyles.end()); SAL_WARN_IF(pIndices->size() != aStyles.size(), "xmloff.style", "Here is a duplicate Style"); #if OSL_DEBUG_LEVEL > 0 SAL_WARN_IF(0 != m_nIndexCreated, "xmloff.style", diff --git a/xmloff/source/style/xmltabi.cxx b/xmloff/source/style/xmltabi.cxx index 82a487fba1a4..5dbfcf1087aa 100644 --- a/xmloff/source/style/xmltabi.cxx +++ b/xmloff/source/style/xmltabi.cxx @@ -18,7 +18,6 @@ */ #include <com/sun/star/style/TabAlign.hpp> -#include <o3tl/make_unique.hxx> #include <rtl/ustrbuf.hxx> #include <xmloff/xmltkmap.hxx> #include <xmloff/nmspmap.hxx> @@ -186,7 +185,7 @@ SvXMLImportContextRef SvxXMLTabStopImportContext::CreateChildContext( // add new tabstop to array of tabstops if( !mpTabStops ) - mpTabStops = o3tl::make_unique<SvxXMLTabStopArray_Impl>(); + mpTabStops = std::make_unique<SvxXMLTabStopArray_Impl>(); mpTabStops->push_back( xTabStopContext ); |