Just use Any ctor instead of makeAny in filter
Change-Id: I68bbbc2cc80ac5efde78e10706b488bf78c058bf Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133816 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
This commit is contained in:
@@ -98,14 +98,14 @@ void XsltFilterTest::testXsltCopyNew()
|
||||
m_directories.getURLFromSrc(u"/filter/source/xsltfilter/xsltfilter.component"));
|
||||
uno::Sequence<uno::Any> args{
|
||||
uno::Any(beans::NamedValue("StylesheetURL",
|
||||
uno::makeAny(m_directories.getURLFromSrc(u"/filter/qa/cppunit/data/xslt/copy.xslt")))),
|
||||
uno::Any(beans::NamedValue("SourceURL", uno::makeAny(source))),
|
||||
uno::Any(beans::NamedValue("TargetURL", uno::makeAny(tempURL))),
|
||||
uno::Any(m_directories.getURLFromSrc(u"/filter/qa/cppunit/data/xslt/copy.xslt")))),
|
||||
uno::Any(beans::NamedValue("SourceURL", uno::Any(source))),
|
||||
uno::Any(beans::NamedValue("TargetURL", uno::Any(tempURL))),
|
||||
uno::Any(beans::NamedValue("SourceBaseURL",
|
||||
uno::makeAny(m_directories.getURLFromSrc(u"/filter/source/xsltfilter/")))),
|
||||
uno::Any(beans::NamedValue("TargetBaseURL", uno::makeAny(tempDirURL))),
|
||||
uno::Any(beans::NamedValue("SystemType", uno::makeAny(OUString()))),
|
||||
uno::Any(beans::NamedValue("PublicType", uno::makeAny(OUString())))
|
||||
uno::Any(m_directories.getURLFromSrc(u"/filter/source/xsltfilter/")))),
|
||||
uno::Any(beans::NamedValue("TargetBaseURL", uno::Any(tempDirURL))),
|
||||
uno::Any(beans::NamedValue("SystemType", uno::Any(OUString()))),
|
||||
uno::Any(beans::NamedValue("PublicType", uno::Any(OUString())))
|
||||
};
|
||||
|
||||
uno::Reference<ucb::XSimpleFileAccess3> xSFA =
|
||||
@@ -153,14 +153,14 @@ void XsltFilterTest::testXsltCopyOld()
|
||||
m_directories.getURLFromSrc(u"/filter/source/xsltfilter/xsltfilter.component"));
|
||||
uno::Sequence<uno::Any> args{
|
||||
uno::Any(beans::NamedValue("StylesheetURL",
|
||||
uno::makeAny(m_directories.getURLFromSrc(u"/filter/qa/cppunit/data/xslt/copy.xslt")))),
|
||||
uno::Any(beans::NamedValue("SourceURL", uno::makeAny(source))),
|
||||
uno::Any(beans::NamedValue("TargetURL", uno::makeAny(tempURL))),
|
||||
uno::Any(m_directories.getURLFromSrc(u"/filter/qa/cppunit/data/xslt/copy.xslt")))),
|
||||
uno::Any(beans::NamedValue("SourceURL", uno::Any(source))),
|
||||
uno::Any(beans::NamedValue("TargetURL", uno::Any(tempURL))),
|
||||
uno::Any(beans::NamedValue("SourceBaseURL",
|
||||
uno::makeAny(m_directories.getURLFromSrc(u"/filter/source/xsltfilter/")))),
|
||||
uno::Any(beans::NamedValue("TargetBaseURL", uno::makeAny(tempDirURL))),
|
||||
uno::Any(beans::NamedValue("SystemType", uno::makeAny(OUString()))),
|
||||
uno::Any(beans::NamedValue("PublicType", uno::makeAny(OUString())))
|
||||
uno::Any(m_directories.getURLFromSrc(u"/filter/source/xsltfilter/")))),
|
||||
uno::Any(beans::NamedValue("TargetBaseURL", uno::Any(tempDirURL))),
|
||||
uno::Any(beans::NamedValue("SystemType", uno::Any(OUString()))),
|
||||
uno::Any(beans::NamedValue("PublicType", uno::Any(OUString())))
|
||||
};
|
||||
|
||||
uno::Reference<ucb::XSimpleFileAccess3> xSFA =
|
||||
|
||||
+1
-1
@@ -430,7 +430,7 @@ void SAL_CALL BaseContainer::flush()
|
||||
|
||||
throw css::lang::WrappedTargetRuntimeException( "Flush rejected by internal container.",
|
||||
static_cast< OWeakObject* >(this),
|
||||
css::uno::makeAny(ex));
|
||||
css::uno::Any(ex));
|
||||
}
|
||||
|
||||
m_pFlushCache.reset();
|
||||
|
||||
+1
-1
@@ -75,7 +75,7 @@ css::uno::Reference< css::uno::XInterface > SAL_CALL ContentHandlerFactory::crea
|
||||
aHandler >> lConfig;
|
||||
|
||||
::std::vector< css::uno::Any > stlArguments(comphelper::sequenceToContainer< ::std::vector< css::uno::Any > >(lArguments));
|
||||
stlArguments.insert(stlArguments.begin(), css::uno::makeAny(lConfig));
|
||||
stlArguments.insert(stlArguments.begin(), css::uno::Any(lConfig));
|
||||
|
||||
xInit->initialize(comphelper::containerToSequence(stlArguments));
|
||||
}
|
||||
|
||||
+3
-3
@@ -623,7 +623,7 @@ void FilterCache::impl_flushByList(const css::uno::Reference< css::container::XN
|
||||
|
||||
CacheItemList::const_iterator pItem = rCache.find(item);
|
||||
impl_saveItem(xItem, eType, pItem->second);
|
||||
xAddRemoveSet->insertByName(item, css::uno::makeAny(xItem));
|
||||
xAddRemoveSet->insertByName(item, css::uno::Any(xItem));
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -890,14 +890,14 @@ css::uno::Reference< css::uno::XInterface > FilterCache::impl_createConfigAccess
|
||||
// set root path
|
||||
aParam.Name = "nodepath";
|
||||
aParam.Value <<= sRoot;
|
||||
lParams.push_back(css::uno::makeAny(aParam));
|
||||
lParams.push_back(css::uno::Any(aParam));
|
||||
|
||||
// enable "all locales mode" ... if required
|
||||
if (bLocalesMode)
|
||||
{
|
||||
aParam.Name = "locale";
|
||||
aParam.Value <<= OUString("*");
|
||||
lParams.push_back(css::uno::makeAny(aParam));
|
||||
lParams.push_back(css::uno::Any(aParam));
|
||||
}
|
||||
|
||||
// open it
|
||||
|
||||
+1
-1
@@ -103,7 +103,7 @@ css::uno::Reference< css::uno::XInterface > SAL_CALL FilterFactory::createInstan
|
||||
aFilter >> lConfig;
|
||||
|
||||
::std::vector< css::uno::Any > stlArguments(comphelper::sequenceToContainer< ::std::vector< css::uno::Any > >(lArguments));
|
||||
stlArguments.insert(stlArguments.begin(), css::uno::makeAny(lConfig));
|
||||
stlArguments.insert(stlArguments.begin(), css::uno::Any(lConfig));
|
||||
|
||||
xInit->initialize(comphelper::containerToSequence(stlArguments));
|
||||
}
|
||||
|
||||
+1
-1
@@ -73,7 +73,7 @@ css::uno::Reference< css::uno::XInterface > SAL_CALL FrameLoaderFactory::createI
|
||||
aLoader >> lConfig;
|
||||
|
||||
::std::vector< css::uno::Any > stlArguments(comphelper::sequenceToContainer< ::std::vector<css::uno::Any> >(lArguments));
|
||||
stlArguments.insert(stlArguments.begin(), css::uno::makeAny(lConfig));
|
||||
stlArguments.insert(stlArguments.begin(), css::uno::Any(lConfig));
|
||||
|
||||
xInit->initialize(comphelper::containerToSequence(stlArguments));
|
||||
}
|
||||
|
||||
@@ -102,7 +102,7 @@ CustomToolBarImportHelper::createCommandFromMacro( std::u16string_view sCmd )
|
||||
// create script url
|
||||
OUString scriptURL
|
||||
= OUString::Concat("vnd.sun.star.script:") + sCmd + "?language=Basic&location=document";
|
||||
return uno::makeAny( scriptURL );
|
||||
return uno::Any( scriptURL );
|
||||
}
|
||||
|
||||
OUString CustomToolBarImportHelper::MSOCommandToOOCommand( sal_Int16 msoCmd )
|
||||
@@ -132,7 +132,7 @@ CustomToolBarImportHelper::createMenu( const OUString& rName, const uno::Referen
|
||||
uno::Reference< container::XIndexContainer > xPopup( xCfgManager->createSettings(), uno::UNO_SET_THROW );
|
||||
uno::Reference< beans::XPropertySet > xProps( xPopup, uno::UNO_QUERY_THROW );
|
||||
// set name for menubar
|
||||
xProps->setPropertyValue("UIName", uno::makeAny( rName ) );
|
||||
xProps->setPropertyValue("UIName", uno::Any( rName ) );
|
||||
if ( xPopup.is() )
|
||||
{
|
||||
uno::Sequence< beans::PropertyValue > aPopupMenu{
|
||||
@@ -142,7 +142,7 @@ CustomToolBarImportHelper::createMenu( const OUString& rName, const uno::Referen
|
||||
comphelper::makePropertyValue("Type", sal_Int32( 0 ))
|
||||
};
|
||||
|
||||
xPopup->insertByIndex( xPopup->getCount(), uno::makeAny( aPopupMenu ) );
|
||||
xPopup->insertByIndex( xPopup->getCount(), uno::Any( aPopupMenu ) );
|
||||
xCfgManager->insertSettings( sMenuBar, xPopup );
|
||||
uno::Reference< ui::XUIConfigurationPersistence > xPersistence( xCfgManager, uno::UNO_QUERY_THROW );
|
||||
xPersistence->store();
|
||||
|
||||
@@ -7402,7 +7402,7 @@ static void ApplyCellAttributes( const SdrObject* pObj, Reference< XCell > const
|
||||
{
|
||||
eFS = css::drawing::FillStyle_SOLID;
|
||||
Color aFillColor( pObj->GetMergedItem( XATTR_FILLCOLOR ).GetColorValue() );
|
||||
xPropSet->setPropertyValue( "FillColor", makeAny( aFillColor ) );
|
||||
xPropSet->setPropertyValue( "FillColor", Any( aFillColor ) );
|
||||
}
|
||||
break;
|
||||
case drawing::FillStyle_GRADIENT :
|
||||
@@ -7435,16 +7435,16 @@ static void ApplyCellAttributes( const SdrObject* pObj, Reference< XCell > const
|
||||
const XFillBitmapItem & rXFillBitmapItem(pObj->GetMergedItem( XATTR_FILLBITMAP ));
|
||||
uno::Reference<graphic::XGraphic> xGraphic = rXFillBitmapItem.GetGraphicObject().GetGraphic().GetXGraphic();
|
||||
uno::Reference<awt::XBitmap> xBitmap(xGraphic, uno::UNO_QUERY);
|
||||
xPropSet->setPropertyValue("FillBitmap", uno::makeAny(xBitmap));
|
||||
xPropSet->setPropertyValue("FillBitmap", uno::Any(xBitmap));
|
||||
|
||||
const XFillBmpStretchItem & rStretchItem(pObj->GetMergedItem( XATTR_FILLBMP_STRETCH ));
|
||||
const XFillBmpTileItem & rTileItem(pObj->GetMergedItem( XATTR_FILLBMP_TILE ));
|
||||
if( rTileItem.GetValue() )
|
||||
xPropSet->setPropertyValue("FillBitmapMode", uno::makeAny(drawing::BitmapMode_REPEAT));
|
||||
xPropSet->setPropertyValue("FillBitmapMode", uno::Any(drawing::BitmapMode_REPEAT));
|
||||
else if( rStretchItem.GetValue() )
|
||||
xPropSet->setPropertyValue("FillBitmapMode", uno::makeAny(drawing::BitmapMode_STRETCH));
|
||||
xPropSet->setPropertyValue("FillBitmapMode", uno::Any(drawing::BitmapMode_STRETCH));
|
||||
else
|
||||
xPropSet->setPropertyValue("FillBitmapMode", uno::makeAny(drawing::BitmapMode_NO_REPEAT));
|
||||
xPropSet->setPropertyValue("FillBitmapMode", uno::Any(drawing::BitmapMode_NO_REPEAT));
|
||||
}
|
||||
break;
|
||||
default:
|
||||
|
||||
@@ -946,14 +946,14 @@ bool PDFExport::Export( const OUString& rFile, const Sequence< PropertyValue >&
|
||||
xViewProperties->getPropertyValue( sShowOnlineLayout ) >>= bReChangeToNormalView;
|
||||
if( bReChangeToNormalView )
|
||||
{
|
||||
xViewProperties->setPropertyValue( sShowOnlineLayout, uno::makeAny( false ) );
|
||||
xViewProperties->setPropertyValue( sShowOnlineLayout, uno::Any( false ) );
|
||||
}
|
||||
|
||||
// Also, disable hide-whitespace during export.
|
||||
xViewProperties->getPropertyValue(sHideWhitespace) >>= bReHideWhitespace;
|
||||
if (bReHideWhitespace)
|
||||
{
|
||||
xViewProperties->setPropertyValue(sHideWhitespace, uno::makeAny(false));
|
||||
xViewProperties->setPropertyValue(sHideWhitespace, uno::Any(false));
|
||||
}
|
||||
}
|
||||
catch( const uno::Exception& )
|
||||
@@ -1016,7 +1016,7 @@ bool PDFExport::Export( const OUString& rFile, const Sequence< PropertyValue >&
|
||||
{
|
||||
try
|
||||
{
|
||||
xViewProperties->setPropertyValue( sShowOnlineLayout, uno::makeAny( true ) );
|
||||
xViewProperties->setPropertyValue( sShowOnlineLayout, uno::Any( true ) );
|
||||
}
|
||||
catch( const uno::Exception& )
|
||||
{
|
||||
@@ -1026,7 +1026,7 @@ bool PDFExport::Export( const OUString& rFile, const Sequence< PropertyValue >&
|
||||
{
|
||||
try
|
||||
{
|
||||
xViewProperties->setPropertyValue( sHideWhitespace, uno::makeAny( true ) );
|
||||
xViewProperties->setPropertyValue( sHideWhitespace, uno::Any( true ) );
|
||||
}
|
||||
catch( const uno::Exception& )
|
||||
{
|
||||
|
||||
@@ -91,7 +91,7 @@ bool XmlFilterAdaptor::importImpl( const Sequence< css::beans::PropertyValue >&
|
||||
|
||||
Reference< XPropertySet > xInfoSet(
|
||||
GenericPropertySet_CreateInstance( new PropertySetInfo( aImportInfoMap ) ) );
|
||||
xInfoSet->setPropertyValue( "BaseURI", makeAny( aBaseURI ));
|
||||
xInfoSet->setPropertyValue( "BaseURI", Any( aBaseURI ));
|
||||
|
||||
OUString aFilterName;
|
||||
auto It = aMediaMap.find(OUString("FilterName"));
|
||||
@@ -101,7 +101,7 @@ bool XmlFilterAdaptor::importImpl( const Sequence< css::beans::PropertyValue >&
|
||||
PropertyValue EmptyDbFieldHidesPara("EmptyDbFieldHidesPara", 0, Any(false),
|
||||
PropertyState::PropertyState_DIRECT_VALUE);
|
||||
Sequence<PropertyValue> aSettings{ EmptyDbFieldHidesPara };
|
||||
xInfoSet->setPropertyValue("DefaultDocumentSettings", makeAny(aSettings));
|
||||
xInfoSet->setPropertyValue("DefaultDocumentSettings", Any(aSettings));
|
||||
}
|
||||
Sequence< Any > aAnys{ Any(xInfoSet) };
|
||||
|
||||
@@ -290,11 +290,11 @@ bool XmlFilterAdaptor::exportImpl( const Sequence< css::beans::PropertyValue >&
|
||||
|
||||
Reference< XPropertySet > xInfoSet(
|
||||
GenericPropertySet_CreateInstance( new PropertySetInfo( aImportInfoMap ) ) );
|
||||
xInfoSet->setPropertyValue("UsePrettyPrinting", makeAny( bPrettyPrint ));
|
||||
xInfoSet->setPropertyValue("UsePrettyPrinting", Any( bPrettyPrint ));
|
||||
xInfoSet->setPropertyValue(
|
||||
"ExportTextNumberElement",
|
||||
makeAny( bExportTextNumberElementForListItems ));
|
||||
xInfoSet->setPropertyValue("BaseURI", makeAny( aBaseURI ));
|
||||
Any( bExportTextNumberElementForListItems ));
|
||||
xInfoSet->setPropertyValue("BaseURI", Any( aBaseURI ));
|
||||
Sequence < Any > aAnys{ Any(xConverter), Any(xInfoSet) };
|
||||
|
||||
Reference< XExporter > xExporter( mxContext->getServiceManager()->createInstanceWithArgumentsAndContext(
|
||||
|
||||
@@ -109,7 +109,7 @@ static void addFile_( Reference< XInterface > const & xRootFolder, Reference< XS
|
||||
if( xSink.is() && xTunnel.is())
|
||||
{
|
||||
Reference< XNameContainer > xNameContainer(xRootFolder, UNO_QUERY );
|
||||
xNameContainer->insertByName(encodeZipUri( aName ), makeAny(xTunnel));
|
||||
xNameContainer->insertByName(encodeZipUri( aName ), Any(xTunnel));
|
||||
xSink->setInputStream( xInput );
|
||||
}
|
||||
}
|
||||
|
||||
@@ -514,7 +514,7 @@ bool XMLFilterSettingsDialog::insertOrEdit( filter_info_impl* pNewInfo, const fi
|
||||
// 4. insert new or replace existing filter
|
||||
try
|
||||
{
|
||||
Any aAny( makeAny( aFilterData ) );
|
||||
Any aAny( aFilterData );
|
||||
if( mxFilterContainer->hasByName( pFilterEntry->maFilterName ) )
|
||||
{
|
||||
mxFilterContainer->replaceByName( pFilterEntry->maFilterName, aAny );
|
||||
@@ -567,7 +567,7 @@ bool XMLFilterSettingsDialog::insertOrEdit( filter_info_impl* pNewInfo, const fi
|
||||
{
|
||||
try
|
||||
{
|
||||
Any aAny( makeAny( aValues ) );
|
||||
Any aAny( aValues );
|
||||
if( mxTypeDetection->hasByName( pFilterEntry->maType ) )
|
||||
{
|
||||
mxTypeDetection->replaceByName( pFilterEntry->maType, aAny );
|
||||
@@ -677,7 +677,7 @@ bool XMLFilterSettingsDialog::insertOrEdit( filter_info_impl* pNewInfo, const fi
|
||||
|
||||
aSequenceRange[nIndex].Value <<= aTypes;
|
||||
|
||||
mxExtendedTypeDetection->replaceByName( sFilterDetectService, makeAny( aSequence ) );
|
||||
mxExtendedTypeDetection->replaceByName( sFilterDetectService, Any( aSequence ) );
|
||||
|
||||
Reference< XFlushable > xFlushable( mxExtendedTypeDetection, UNO_QUERY );
|
||||
if( xFlushable.is() )
|
||||
|
||||
Reference in New Issue
Block a user