cid#1545605 COPY_INSTEAD_OF_MOVE

and

cid#1545841 COPY_INSTEAD_OF_MOVE
cid#1554682 COPY_INSTEAD_OF_MOVE
cid#1554686 COPY_INSTEAD_OF_MOVE
cid#1554715 COPY_INSTEAD_OF_MOVE
cid#1554750 COPY_INSTEAD_OF_MOVE
cid#1554759 COPY_INSTEAD_OF_MOVE
cid#1554770 COPY_INSTEAD_OF_MOVE
cid#1554779 COPY_INSTEAD_OF_MOVE
cid#1554794 COPY_INSTEAD_OF_MOVE
cid#1554800 COPY_INSTEAD_OF_MOVE
cid#1554826 COPY_INSTEAD_OF_MOVE
cid#1554836 COPY_INSTEAD_OF_MOVE
cid#1554862 COPY_INSTEAD_OF_MOVE
cid#1554865 COPY_INSTEAD_OF_MOVE
cid#1554872 COPY_INSTEAD_OF_MOVE
cid#1554883 COPY_INSTEAD_OF_MOVE
cid#1554906 COPY_INSTEAD_OF_MOVE
cid#1554921 COPY_INSTEAD_OF_MOVE
cid#1554926 COPY_INSTEAD_OF_MOVE
cid#1554946 COPY_INSTEAD_OF_MOVE
cid#1554956 COPY_INSTEAD_OF_MOVE
cid#1554970 COPY_INSTEAD_OF_MOVE
cid#1554986 COPY_INSTEAD_OF_MOVE
cid#1554991 COPY_INSTEAD_OF_MOVE
cid#1555013 COPY_INSTEAD_OF_MOVE
cid#1555037 COPY_INSTEAD_OF_MOVE
cid#1555050 COPY_INSTEAD_OF_MOVE
cid#1555057 COPY_INSTEAD_OF_MOVE
cid#1555066 COPY_INSTEAD_OF_MOVE
cid#1555067 COPY_INSTEAD_OF_MOVE
cid#1555083 COPY_INSTEAD_OF_MOVE
cid#1555097 COPY_INSTEAD_OF_MOVE
cid#1555135 COPY_INSTEAD_OF_MOVE
cid#1555140 COPY_INSTEAD_OF_MOVE
cid#1555146 COPY_INSTEAD_OF_MOVE
cid#1555148 COPY_INSTEAD_OF_MOVE
cid#1555149 COPY_INSTEAD_OF_MOVE
cid#1555155 COPY_INSTEAD_OF_MOVE
cid#1555157 COPY_INSTEAD_OF_MOVE
cid#1555168 COPY_INSTEAD_OF_MOVE
cid#1555195 COPY_INSTEAD_OF_MOVE
cid#1555196 COPY_INSTEAD_OF_MOVE
cid#1555237 COPY_INSTEAD_OF_MOVE

Change-Id: I90531c19c28dca77fe99c72efdfc0972c311da98
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/175377
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
This commit is contained in:
Caolán McNamara
2024-10-22 11:56:02 +02:00
parent 28c187c8f9
commit 2bafc7384b
42 changed files with 50 additions and 57 deletions
@@ -349,10 +349,7 @@ namespace accessibility
return Application::GetSettings().GetLanguageTag().getLocale();
}
// XAccessibleComponent
Reference< XAccessible > AccessibleTabBar::getAccessibleAtPoint( const awt::Point& rPoint )
{
OExternalLockGuard aGuard( this );
@@ -370,7 +367,7 @@ namespace accessibility
Point aPos = VCLUnoHelper::ConvertToVCLPoint(rPoint);
if ( aRect.Contains( aPos ) )
{
xChild = xAcc;
xChild = std::move(xAcc);
break;
}
}
@@ -380,7 +377,6 @@ namespace accessibility
return xChild;
}
void AccessibleTabBar::grabFocus( )
{
OExternalLockGuard aGuard( this );
+1 -1
View File
@@ -319,7 +319,7 @@ Reference< XAccessibleContext > AccessibleFactory::createAccessibleContext( VCLX
if ( pWindow->GetType() == WindowType::MENUBARWINDOW ||
( xCont.is() && xCont->getAccessibleRole() == AccessibleRole::POPUP_MENU ) )
{
xContext = xCont;
xContext = std::move(xCont);
}
}
}
+1 -1
View File
@@ -1205,7 +1205,7 @@ void SbiRuntime::PushForEach()
else if (aAny >>= xIndexAccess)
{
p->eForType = ForType::EachXIndexAccess;
p->xIndexAccess = xIndexAccess;
p->xIndexAccess = std::move(xIndexAccess);
p->nCurCollectionIndex = 0;
}
else if ( isVBAEnabled() && pUnoObj->isNativeCOMObject() )
@@ -545,7 +545,7 @@ bool DataPointItemConverter::ApplySpecialItem(
GetPropertySet()->getPropertyValue( u"Symbol"_ustr ) >>= aSymbol;
if( aSymbol.Graphic != xGraphic )
{
aSymbol.Graphic = xGraphic;
aSymbol.Graphic = std::move(xGraphic);
GetPropertySet()->setPropertyValue( u"Symbol"_ustr , uno::Any( aSymbol ));
bChanged = true;
}
+1 -1
View File
@@ -66,7 +66,7 @@ Reference< beans::XPropertySetInfo > SAL_CALL WrappedPropertySet::getPropertySet
{
xInfo = ::cppu::OPropertySetHelper::createPropertySetInfo( getInfoHelper() );
OSL_DOUBLE_CHECKED_LOCKING_MEMORY_BARRIER();
m_xInfo = xInfo;
m_xInfo = std::move(xInfo);
}
}
else
@@ -179,7 +179,7 @@ void OConnection::construct(const OUString& url,const Sequence< PropertyValue >&
{
Reference<XContent> xParent(Reference<XChild>(aFile.get(),UNO_QUERY_THROW)->getParent(),UNO_QUERY_THROW);
Reference<XContentIdentifier> xIdent = xParent->getIdentifier();
m_xContent = xParent;
m_xContent = std::move(xParent);
::ucbhelper::Content aParent(xIdent->getContentIdentifier(), Reference< XCommandEnvironment >(), comphelper::getProcessComponentContext());
m_xDir = aParent.createDynamicCursor(aProps, ::ucbhelper::INCLUDE_DOCUMENTS_ONLY );
+1 -1
View File
@@ -547,7 +547,7 @@ extern "C" { static void s_createComponentContext_v(va_list * pParam)
}
else
{
xContext = xDelegate;
xContext = std::move(xDelegate);
}
*ppContext = pTarget2curr->mapInterface(xContext.get(), cppu::UnoType<decltype(xContext)>::get());
+2 -2
View File
@@ -1961,8 +1961,8 @@ void cppuhelper::ServiceManager::preloadImplementations() {
if (!rEntry.second->constructorName.isEmpty() && fpFactory)
rEntry.second->constructorFn = WrapperConstructorFn(reinterpret_cast<ImplementationConstructorFn *>(fpFactory));
rEntry.second->factory1 = xSCFactory;
rEntry.second->factory2 = xSSFactory;
rEntry.second->factory1 = std::move(xSCFactory);
rEntry.second->factory2 = std::move(xSSFactory);
rEntry.second->status = Data::Implementation::STATUS_LOADED;
}
+1 -1
View File
@@ -169,7 +169,7 @@ void getDefaultUpdateInfos(
dp_misc::GREATER)
{
j->second.version = v;
j->second.info = node;
j->second.info = std::move(node);
}
}
}
+1 -1
View File
@@ -804,7 +804,7 @@ bool UpdateHandler::showWarning( const OUString &rWarningText ) const
aDescriptor.Type = awt::WindowClass_MODALTOP;
aDescriptor.WindowServiceName = "warningbox";
aDescriptor.ParentIndex = -1;
aDescriptor.Parent = xPeer;
aDescriptor.Parent = std::move(xPeer);
aDescriptor.Bounds = awt::Rectangle( 10, 10, 250, 150 );
aDescriptor.WindowAttributes = nWindowAttributes;
+1 -1
View File
@@ -1726,7 +1726,7 @@ bool PPTConvertOCXControls::InsertControl(
{
xControlShape->setControl( xControlModel );
if (pShape)
*pShape = xShape;
*pShape = std::move(xShape);
bRetValue = true;
}
}
+1 -1
View File
@@ -284,7 +284,7 @@ sal_Bool SAL_CALL OGridControlModel::select(const Any& rElement)
}
if ( xSel != m_xSelection )
{
m_xSelection = xSel;
m_xSelection = std::move(xSel);
aGuard.clear();
m_aSelectListeners.notifyEach( &XSelectionChangeListener::selectionChanged, EventObject( *this ) );
return true;
@@ -99,7 +99,7 @@ namespace frm
break;
}
xChainWalk = xSlave;
xChainWalk = std::move(xSlave);
}
}
@@ -126,7 +126,7 @@ void SAL_CALL PropertySetContainer::replaceByIndex( sal_Int32 Index, const css::
static_cast<OWeakObject *>(this), 2 );
}
m_aPropertySetVector[ Index ] = aPropertySetElement;
m_aPropertySetVector[ Index ] = std::move(aPropertySetElement);
}
// XIndexAccess
@@ -516,7 +516,7 @@ bool ToolbarLayoutManager::createToolbar( const OUString& rResourceURL )
// Reuse a local entry so we are able to use the latest
// UI changes for this document.
implts_setElementData(rElement, xDockWindow);
rElement.m_xUIElement = xUIElement;
rElement.m_xUIElement = std::move(xUIElement);
bVisible = rElement.m_bVisible;
bFloating = rElement.m_bFloating;
}
+2 -2
View File
@@ -236,13 +236,13 @@ static Reference< XDictionaryEntry > lcl_GetRulingDictionaryEntry(
Reference< XDictionaryEntry > xNegEntry( SearchDicList( xDList,
rWord, nLanguage, false, true ) );
if (xNegEntry.is())
xRes = xNegEntry;
xRes = std::move(xNegEntry);
else
{
Reference< XDictionaryEntry > xPosEntry( SearchDicList( xDList,
rWord, nLanguage, true, true ) );
if (xPosEntry.is())
xRes = xPosEntry;
xRes = std::move(xPosEntry);
}
}
+1 -1
View File
@@ -2740,7 +2740,7 @@ Reference< XControlModel > EmbeddedForm::convertAndInsert( const EmbeddedControl
// convert the control properties
if( rControl.convertProperties( xCtrlModel, maControlConv ) )
xRet = xCtrlModel;
xRet = std::move(xCtrlModel);
// insert the control into the form
Reference< XIndexContainer > xFormIC( createXForm(), UNO_SET_THROW );
rnCtrlIndex = xFormIC->getCount();
+2 -3
View File
@@ -1201,18 +1201,17 @@ uno::Reference< style::XStyle> getUsedStyle(const uno::Reference< report::XRepor
uno::Reference<container::XNameAccess> xStyles = _xReport->getStyleFamilies();
uno::Reference<container::XNameAccess> xPageStyles(xStyles->getByName(u"PageStyles"_ustr),uno::UNO_QUERY);
uno::Reference< style::XStyle> xReturn;
const uno::Sequence< OUString> aSeq = xPageStyles->getElementNames();
for(const OUString& rName : aSeq)
{
uno::Reference< style::XStyle> xStyle(xPageStyles->getByName(rName),uno::UNO_QUERY);
if ( xStyle->isInUse() )
{
xReturn = xStyle;
return xStyle;
break;
}
}
return xReturn;
return nullptr;
}
+1 -1
View File
@@ -72,7 +72,7 @@ ScParserFactoryMap::ScParserFactoryMap() :
// store factory in the map
OUString aNamespace = xParser->getSupportedNamespace();
if( !aNamespace.isEmpty() )
maFactories[ aNamespace ] = xCompFactory;
maFactories[ aNamespace ] = std::move(xCompFactory);
}
catch( Exception& )
{
+1 -1
View File
@@ -2498,7 +2498,7 @@ void ScXMLExport::collectAutoStyles()
OUString sName( rTextEntry.maName );
GetAutoStylePool()->AddNamed(sName, XmlStyleFamily::TEXT_TEXT, OUString(), std::move(aPropStates));
GetAutoStylePool()->RegisterName(XmlStyleFamily::TEXT_TEXT, sName);
xPrevCursorProp = xCursorProp;
xPrevCursorProp = std::move(xCursorProp);
aPrevPos = aPos;
}
}
@@ -1035,7 +1035,7 @@ void ScShapeChildren::FillShapes(const tools::Rectangle& aPixelPaintRect, const
if(!aClippedPixelPaintRect.GetIntersection(aRect).IsEmpty())
{
ScShapeChild aShape;
aShape.mxShape = xShape;
aShape.mxShape = std::move(xShape);
aShape.mnRangeId = nRangeId;
if (pObj->GetLayer().anyOf(SC_LAYER_INTERN, SC_LAYER_FRONT))
{
+1 -1
View File
@@ -112,7 +112,7 @@ PresenterPaneContainer::SharedPaneDescriptor
{
Reference<awt::XWindow> xWindow (rxPane->getWindow());
pDescriptor->mxContentWindow = xWindow;
pDescriptor->mxPaneId = xPaneId;
pDescriptor->mxPaneId = std::move(xPaneId);
pDescriptor->mxPane = rxPane;
pDescriptor->mxPane->SetTitle(pDescriptor->msTitle);
+1 -1
View File
@@ -2542,7 +2542,7 @@ void EffectSequenceHelper::createTextGroupParagraphEffects( const CustomAnimatio
}
ParagraphTarget aTarget;
aTarget.Shape = xTarget;
aTarget.Shape = std::move(xTarget);
for( const auto i : aParaList )
{
@@ -280,7 +280,7 @@ uno::Reference<XAccessible > SAL_CALL
&& (aPoint.X < aBBox.X+aBBox.Width)
&& (aPoint.Y < aBBox.Y+aBBox.Height) )
{
xChildAtPosition = xChild;
xChildAtPosition = std::move(xChild);
break;
}
}
+1 -1
View File
@@ -621,7 +621,7 @@ uno::Reference< drawing::XShape > SdUnoSearchReplaceShape::GetShape( const uno:
if(!xParent.is() || xText.get() == xParent.get())
return xShape;
xText = xParent;
xText = std::move(xParent);
}
} while( !xShape.is() );
}
+1 -1
View File
@@ -171,7 +171,7 @@ static void ImpAddFillBitmapEntity( const Reference< XComponentContext >& rxMSF,
}
GraphicCollector::GraphicUser aUser;
aUser.mxPropertySet = rxPropertySet;
aUser.mxGraphic = xGraphic;
aUser.mxGraphic = std::move(xGraphic);
aUser.mbFillBitmap = true;
aUser.maLogicalSize = aLogicalSize;
aUser.mxPagePropertySet = rxPagePropertySet;
+2 -2
View File
@@ -575,8 +575,8 @@ static SfxHelpWindow_Impl* impl_createHelp(Reference< XFrame2 >& rHelpTask ,
xHelpContent->setName(u"OFFICE_HELP"_ustr);
rHelpTask = xHelpTask;
rHelpContent = xHelpContent;
rHelpTask = std::move(xHelpTask);
rHelpContent = std::move(xHelpContent);
return pHelpWindow;
}
+1 -1
View File
@@ -1928,7 +1928,7 @@ SfxDocumentMetaData::loadFromStorage(
css::uno::Reference<css::lang::XMultiComponentFactory> xMsf (
m_xContext->getServiceManager());
css::xml::sax::InputSource input;
input.aInputStream = xInStream;
input.aInputStream = std::move(xInStream);
sal_uInt64 version = SotStorage::GetVersion( xStorage );
// Oasis is also the default (0)
+1 -1
View File
@@ -62,7 +62,7 @@ css::uno::Reference<css::frame::XDispatch>& LokChartHelper::GetXDispatcher()
::css::uno::Reference< ::css::frame::XDispatch > xDispatcher( xChartController, uno::UNO_QUERY );
if( xDispatcher.is() )
{
mxDispatcher = xDispatcher;
mxDispatcher = std::move(xDispatcher);
}
}
}
@@ -95,7 +95,7 @@ AnimationCommandNode::AnimationCommandNode( uno::Reference<animations::XAnimatio
uno::UNO_QUERY );
ShapeSharedPtr pShape( getContext().mpSubsettableShapeManager->lookupShape( xShape ) );
mpShape = ::std::dynamic_pointer_cast< IExternalMediaShapeBase >( pShape );
mxShape = xShape;
mxShape = std::move(xShape);
}
void AnimationCommandNode::dispose()
@@ -671,7 +671,7 @@ void OServiceManager::setPropertyValue(
}
MutexGuard aGuard( m_aMutex );
m_xContext = xContext;
m_xContext = std::move(xContext);
}
Any OServiceManager::getPropertyValue(const OUString& PropertyName)
+1 -1
View File
@@ -2529,7 +2529,7 @@ void FmXGridPeer::releaseDispatchProviderInterceptor(const Reference< css::frame
}
}
xChainWalk = xSlave;
xChainWalk = std::move(xSlave);
}
// our interceptor chain has changed and we're alive ?
if (!isDesignMode())
+2 -2
View File
@@ -2072,7 +2072,7 @@ void FmXFormShell::startListening_Lock()
break;
}
}
m_xNavigationController = xParent;
m_xNavigationController = std::move(xParent);
}
break;
@@ -2522,7 +2522,7 @@ void FmXFormShell::UpdateForms_Lock(bool _bInvalidate)
if ( m_xForms != xForms )
{
RemoveElement_Lock( m_xForms );
m_xForms = xForms;
m_xForms = std::move(xForms);
AddElement_Lock(m_xForms);
}
+1 -1
View File
@@ -402,7 +402,7 @@ SdrTableObjImpl& SdrTableObjImpl::operator=( const SdrTableObjImpl& rSource )
}
// set that TableStyle
mxTableStyle = xNewTableStyle;
mxTableStyle = std::move(xNewTableStyle);
// Apply Style to Cells
ApplyCellStyles();
+1 -1
View File
@@ -764,7 +764,7 @@ bool SwView::ExecSpellPopup(const Point& rPt)
{
// Execute dispatch asynchronously
ExecuteInfo* pExecuteInfo = new ExecuteInfo;
pExecuteInfo->xDispatch = xDispatch;
pExecuteInfo->xDispatch = std::move(xDispatch);
pExecuteInfo->aTargetURL = std::move(aURL);
Application::PostUserEvent( LINK(nullptr, AsyncExecute , ExecuteHdl_Impl), pExecuteInfo );
}
+3 -5
View File
@@ -5226,20 +5226,18 @@ gboolean GtkInstDropTarget::signalDragDrop(GtkDropTargetAsync* context, GdkDrop*
if (!(mask & (GDK_CONTROL_MASK | GDK_SHIFT_MASK)))
aEvent.DropAction |= css::datatransfer::dnd::DNDConstants::ACTION_DEFAULT;
css::uno::Reference<css::datatransfer::XTransferable> xTransferable;
// For LibreOffice internal D&D we provide the Transferable without Gtk
// intermediaries as a shortcut, see tdf#100097 for how dbaccess depends on this
if (GtkInstDragSource::g_ActiveDragSource)
xTransferable = GtkInstDragSource::g_ActiveDragSource->GetTransferable();
aEvent.Transferable = GtkInstDragSource::g_ActiveDragSource->GetTransferable();
else
{
#if GTK_CHECK_VERSION(4,0,0)
xTransferable = new GtkDnDTransferable(drop);
aEvent.Transferable = new GtkDnDTransferable(drop);
#else
xTransferable = new GtkDnDTransferable(context, time, pWidget, this);
aEvent.Transferable = new GtkDnDTransferable(context, time, pWidget, this);
#endif
}
aEvent.Transferable = xTransferable;
fire_drop(aEvent);
+2 -2
View File
@@ -692,7 +692,7 @@ void SAL_CALL SvXMLExport::initialize( const uno::Sequence< uno::Any >& aArgumen
uno::Reference<beans::XPropertySet> xTmpPropertySet(
xValue, UNO_QUERY );
if( xTmpPropertySet.is() )
mxExportInfo = xTmpPropertySet;
mxExportInfo = std::move(xTmpPropertySet);
}
if( !mxExportInfo.is() )
@@ -1288,7 +1288,7 @@ ErrCode SvXMLExport::exportDoc( enum ::xmloff::token::XMLTokenEnum eClass )
SAL_WARN_IF(!xTmpDocHandler.is(), "xmloff.core", "can't instantiate OASIS transformer component" );
if( xTmpDocHandler.is() )
{
mxHandler = xTmpDocHandler;
mxHandler = std::move(xTmpDocHandler);
mxExtHandler.set( mxHandler, UNO_QUERY );
}
}
+1 -1
View File
@@ -990,7 +990,7 @@ void SAL_CALL SvXMLImport::initialize( const uno::Sequence< uno::Any >& aArgumen
uno::Reference<beans::XPropertySet> xTmpPropSet( xValue, UNO_QUERY );
if( xTmpPropSet.is() )
{
mxImportInfo = xTmpPropSet;
mxImportInfo = std::move(xTmpPropSet);
uno::Reference< beans::XPropertySetInfo > xPropertySetInfo = mxImportInfo->getPropertySetInfo();
if (xPropertySetInfo.is())
{
+1 -1
View File
@@ -285,7 +285,7 @@ void XMLShapeExport::collectShapeAutoStyles(const uno::Reference< drawing::XShap
uno::Reference< drawing::XShape > xCustomShapeReplacement = checkForCustomShapeReplacement( xShape );
if ( xCustomShapeReplacement.is() )
aShapeInfo.xCustomShapeReplacement = xCustomShapeReplacement;
aShapeInfo.xCustomShapeReplacement = std::move(xCustomShapeReplacement);
// first compute the shapes type
ImpCalcShapeType(xShape, aShapeInfo.meShapeType);
+1 -1
View File
@@ -425,7 +425,7 @@ namespace xmloff
aContainerHistory.push(xLoop);
aIndexHistory.push(nChildPos);
xLoop = xNextContainer;
xLoop = std::move(xNextContainer);
nChildPos = -1; // will be incremented below
}
++nChildPos;
@@ -135,7 +135,7 @@ void XMLPersAttrListTContext::StartElement(
}
else if( pMutableAttrList )
{
m_xAttrList = xAttrList;
m_xAttrList = std::move(xAttrList);
}
else
{
+1 -1
View File
@@ -379,7 +379,7 @@ void DocumentHandlerImpl::initialize(
{
throw RuntimeException( u"missing root instance!"_ustr );
}
m_xRoot = xRoot;
m_xRoot = std::move(xRoot);
}
// XNamespaceMapping