cid#1660220 Variable copied when it could be moved

and

cid#1660211 Variable copied when it could be moved
cid#1660204 Variable copied when it could be moved
cid#1660195 Variable copied when it could be moved
cid#1660194 Variable copied when it could be moved
cid#1660193 Variable copied when it could be moved
cid#1660191 Variable copied when it could be moved
cid#1660188 Variable copied when it could be moved
cid#1660187 Variable copied when it could be moved

Change-Id: Ifcb179f73723e2d43144e242fa9c1b5ac332cd4f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/188965
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
This commit is contained in:
Caolán McNamara
2025-08-05 22:12:32 +02:00
parent 2dd4057499
commit d356341535
9 changed files with 13 additions and 14 deletions
+1 -1
View File
@@ -282,7 +282,7 @@ namespace dbaui
OSL_ENSURE(end() == find(_rName), "OIndexCollection::insert: invalid new name!");
OIndex aNewIndex((OUString())); // the empty string indicates the index is a new one
aNewIndex.sName = _rName;
m_aIndexes.push_back(aNewIndex);
m_aIndexes.push_back(std::move(aNewIndex));
return m_aIndexes.end() - 1; // the last element is the new one ...
}
@@ -1906,7 +1906,7 @@ void ToolbarLayoutManager::implts_getDockingAreaElementInfos( ui::DockingArea eD
SingleRowColumnWindowData aRowColumnWindowData;
aRowColumnWindowData.nRowColumn = nCurrPos;
rRowColumnsWindowData.push_back( aRowColumnWindowData );
rRowColumnsWindowData.push_back(std::move(aRowColumnWindowData));
}
sal_Int32 nSpace( 0 );
@@ -1921,7 +1921,7 @@ void ToolbarLayoutManager::implts_getDockingAreaElementInfos( ui::DockingArea eD
nCurrPos = rElement.m_aDockedData.m_aPos.Y;
SingleRowColumnWindowData aRowColumnWindowData;
aRowColumnWindowData.nRowColumn = nCurrPos;
rRowColumnsWindowData.push_back( aRowColumnWindowData );
rRowColumnsWindowData.push_back(std::move(aRowColumnWindowData));
}
// Calc space before an element and store it
@@ -144,8 +144,7 @@ GtkWidget* GtvHelpers::createCommentBox(const boost::property_tree::ptree& aComm
std::string GtvHelpers::getDirPath(const std::string& filePath)
{
int position = filePath.find_last_of('/');
const std::string dirPath = filePath.substr(0, position + 1);
return dirPath;
return filePath.substr(0, position + 1);
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
+3 -3
View File
@@ -353,16 +353,16 @@ void XclImpPCField::ReadItem( XclImpStream& rStrm )
{
// there are 3 items after SXNUMGROUP that contain grouping limits and step count
if( maNumGroupItems.size() < 3 )
maNumGroupItems.push_back( xItem );
maNumGroupItems.push_back(std::move(xItem));
else
maOrigItems.push_back( xItem );
maOrigItems.push_back(std::move(xItem));
}
else if( HasInlineItems() || HasPostponedItems() )
{
maItems.push_back( xItem );
// visible item is original item in standard fields
if( IsStandardField() )
maOrigItems.push_back( xItem );
maOrigItems.push_back(std::move(xItem));
}
}
+1 -1
View File
@@ -384,7 +384,7 @@ ScCTBWrapper::Read( SvStream &rS)
ScCTB aCTB( ctbSet.ctbViews );
if ( !aCTB.Read( rS ) )
return false;
rCTB.push_back( aCTB );
rCTB.push_back(std::move(aCTB));
}
return true;
}
+2 -2
View File
@@ -1331,7 +1331,7 @@ bool ImpSvNumberInputScan::IsAcceptedDatePattern( sal_uInt16 nStartPatternAt )
assert(mpFormat->GetLanguage() == aSaveLocale.getLanguageType()); // prerequisite
// Obtain formatter's locale's (e.g. system) patterns.
xLocaleData.changeLocale( LanguageTag( mrCurrentLanguageData.GetIniLanguage()));
const css::uno::Sequence<OUString> aLocalePatterns( xLocaleData->getDateAcceptancePatterns());
css::uno::Sequence<OUString> aLocalePatterns( xLocaleData->getDateAcceptancePatterns());
// Reset to format's locale.
xLocaleData.changeLocale( aSaveLocale);
// When concatenating don't care about duplicates, combining
@@ -1343,7 +1343,7 @@ bool ImpSvNumberInputScan::IsAcceptedDatePattern( sal_uInt16 nStartPatternAt )
assert(!"shouldn't reach here");
break;
case NfEvalDateFormat::International:
sDateAcceptancePatterns = aLocalePatterns;
sDateAcceptancePatterns = std::move(aLocalePatterns);
break;
case NfEvalDateFormat::InternationalThenFormat:
sDateAcceptancePatterns = comphelper::concatSequences(
+1 -1
View File
@@ -1541,7 +1541,7 @@ void SwSpellIter::CreatePortion(uno::Reference< XSpellAlternatives > const & xAl
SwPaM *pCursor = GetSh()->GetCursor();
aPosition.nLeft = pCursor->Start()->GetContentIndex();
aPosition.nRight = pCursor->End()->GetContentIndex();
m_aLastPortions.push_back(aPortion);
m_aLastPortions.push_back(std::move(aPortion));
m_aLastPositions.push_back(aPosition);
}
+1 -1
View File
@@ -293,7 +293,7 @@ void XSecController::setDescription(sal_Int32 nSecurityId, const OUString& rDesc
{
InternalSignatureInformation aInformation(nSecurityId, nullptr);
aInformation.signatureInfor.ouDescription = rDescription;
m_vInternalSignatureInformations.push_back(aInformation);
m_vInternalSignatureInformations.push_back(std::move(aInformation));
}
else
{
+1 -1
View File
@@ -289,7 +289,7 @@ void XSecController::setX509Data(
}
if (!data.empty())
{
isi.signatureInfor.X509Datas.push_back(data);
isi.signatureInfor.X509Datas.push_back(std::move(data));
}
}