From 95d351871886e8c72f34e68140dade4fc21ad18b Mon Sep 17 00:00:00 2001 From: Mike Kaganski Date: Mon, 6 Nov 2017 16:44:35 +0200 Subject: Use std::initializer_list to construct Sequence Change-Id: I5b3b97922befbe094c0ebe9adf4f195a83cd24af Reviewed-on: https://gerrit.libreoffice.org/44365 Tested-by: Jenkins Reviewed-by: Mike Kaganski --- dbaccess/source/core/dataaccess/ModelImpl.cxx | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/dbaccess/source/core/dataaccess/ModelImpl.cxx b/dbaccess/source/core/dataaccess/ModelImpl.cxx index 27b9f6fe8069..48643a9c4892 100644 --- a/dbaccess/source/core/dataaccess/ModelImpl.cxx +++ b/dbaccess/source/core/dataaccess/ModelImpl.cxx @@ -470,14 +470,14 @@ void ODatabaseModelImpl::impl_construct_nothrow() try { // the set of property value types in the bag is limited: - Sequence< Type > aAllowedTypes(6); - Type* pAllowedType = aAllowedTypes.getArray(); - *pAllowedType++ = ::cppu::UnoType::get(); - *pAllowedType++ = ::cppu::UnoType::get(); - *pAllowedType++ = ::cppu::UnoType::get(); - *pAllowedType++ = ::cppu::UnoType::get(); - *pAllowedType++ = ::cppu::UnoType::get(); - *pAllowedType++ = cppu::UnoType>::get(); + Sequence< Type > aAllowedTypes({ + cppu::UnoType::get(), + cppu::UnoType::get(), + cppu::UnoType::get(), + cppu::UnoType::get(), + cppu::UnoType::get(), + cppu::UnoType>::get(), + }); m_xSettings = PropertyBag::createWithTypes( m_aContext, aAllowedTypes, false/*AllowEmptyPropertyName*/, true/*AutomaticAddition*/ ); -- cgit reoffice-6-2 LibreOffice 核心代码仓库文档基金会
summaryrefslogtreecommitdiff