drawinglayer/source/tools/wmfemfhelper.cxx | 2 - include/svx/grfflt.hxx | 2 - sc/source/ui/view/viewfunc.cxx | 26 ++++++++++---------- slideshow/source/engine/animationnodes/basenode.cxx | 5 +-- svx/source/diagram/datamodel.cxx | 4 +-- svx/source/dialog/grfflt.cxx | 6 ++-- unoidl/source/sourceprovider-parser.y | 2 - vcl/source/app/settings.cxx | 4 +-- 8 files changed, 26 insertions(+), 25 deletions(-)
New commits: commit 0ba45589492c0fe542b75ebe5294fc1d3f27b9bb Author: Caolán McNamara <[email protected]> AuthorDate: Tue Aug 20 09:03:40 2024 +0100 Commit: Caolán McNamara <[email protected]> CommitDate: Wed Aug 21 09:31:36 2024 +0200 cid#1555812 COPY_INSTEAD_OF_MOVE and cid#1556056 COPY_INSTEAD_OF_MOVE cid#1556907 COPY_INSTEAD_OF_MOVE cid#1556957 COPY_INSTEAD_OF_MOVE cid#1556970 COPY_INSTEAD_OF_MOVE cid#1607095 COPY_INSTEAD_OF_MOVE Change-Id: I51112b3a63b8e9333e3eaaeb55b764e6c449a5ee Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172117 Tested-by: Jenkins Reviewed-by: Caolán McNamara <[email protected]> diff --git a/drawinglayer/source/tools/wmfemfhelper.cxx b/drawinglayer/source/tools/wmfemfhelper.cxx index 86182e1f1234..0e3c6e0611d2 100644 --- a/drawinglayer/source/tools/wmfemfhelper.cxx +++ b/drawinglayer/source/tools/wmfemfhelper.cxx @@ -1154,7 +1154,7 @@ namespace wmfemfhelper nTextStart, nTextLength, std::vector(rDXArray), - std::vector(rKashidaArray), + std::move(rKashidaArray), std::move(aFontAttribute), std::move(aLocale), aFontColor); diff --git a/include/svx/grfflt.hxx b/include/svx/grfflt.hxx index 13710ae4de55..b6f4662defbe 100644 --- a/include/svx/grfflt.hxx +++ b/include/svx/grfflt.hxx @@ -32,7 +32,7 @@ public: /// this will execute a dialog and then call function f with the output of the filtering operation static void ExecuteGrfFilterSlot( SfxRequest const & rReq, const GraphicObject& rInputObject, - const std::function<void(const GraphicObject&)>& f); + const std::function<void(const Graphic&)>& f); static void DisableGraphicFilterSlots( SfxItemSet& rSet ); }; diff --git a/sc/source/ui/view/viewfunc.cxx b/sc/source/ui/view/viewfunc.cxx index f061d3744f20..a0de9ffc3942 100644 --- a/sc/source/ui/view/viewfunc.cxx +++ b/sc/source/ui/view/viewfunc.cxx @@ -663,7 +663,7 @@ void ScViewFunc::EnterData( SCCOL nCol, SCROW nRow, SCTAB nTab, bool bMatrixExpand ) { ScDocument& rDoc = GetViewData().GetDocument(); - ScMarkData rMark(GetViewData().GetMarkData()); + ScMarkData aMark(GetViewData().GetMarkData()); bool bRecord = rDoc.IsUndoEnabled(); SCTAB i; @@ -671,7 +671,7 @@ void ScViewFunc::EnterData( SCCOL nCol, SCROW nRow, SCTAB nTab, ScDocFunc &rFunc = GetViewData().GetDocFunc(); std::shared_ptr<ScDocShellModificator> xModificator = std::make_shared<ScDocShellModificator>(*pDocSh); - ScEditableTester aTester( rDoc, nCol,nRow, nCol,nRow, rMark ); + ScEditableTester aTester( rDoc, nCol,nRow, nCol,nRow, aMark ); if (!aTester.IsEditable()) { ErrorMessage(aTester.GetMessageId()); @@ -722,23 +722,25 @@ void ScViewFunc::EnterData( SCCOL nCol, SCROW nRow, SCTAB nTab, bool bNumFmtChanged = false; if ( bFormula ) { // formula, compile with autoCorrection - i = rMark.GetFirstSelected(); - auto aPosPtr = std::make_shared<ScAddress>(nCol, nRow, i); - auto aCompPtr = std::make_shared<ScCompiler>(rDoc, *aPosPtr, rDoc.GetGrammar(), true, false); + i = aMark.GetFirstSelected(); + auto xPosPtr = std::make_shared<ScAddress>(nCol, nRow, i); + auto xCompPtr = std::make_shared<ScCompiler>(rDoc, *xPosPtr, rDoc.GetGrammar(), true, false); //2do: enable/disable autoCorrection via calcoptions - aCompPtr->SetAutoCorrection( true ); + xCompPtr->SetAutoCorrection( true ); if ( rString[0] == '+' || rString[0] == '-' ) { - aCompPtr->SetExtendedErrorDetection( ScCompiler::EXTENDED_ERROR_DETECTION_NAME_BREAK ); + xCompPtr->SetExtendedErrorDetection( ScCompiler::EXTENDED_ERROR_DETECTION_NAME_BREAK ); } OUString aFormula( rString ); FormulaProcessingContext context_instance{ - aPosPtr, aCompPtr, xModificator, nullptr, nullptr, pData, - rMark, *this, OUString(), aFormula, rString, nCol, - nRow, nTab, bMatrixExpand, bNumFmtChanged, bRecord + std::move(xPosPtr), std::move(xCompPtr), std::move(xModificator), nullptr, + nullptr, pData, std::move(aMark), *this, + OUString(), aFormula, rString, nCol, + nRow, nTab, bMatrixExpand, bNumFmtChanged, + bRecord }; parseAndCorrectFormula(std::make_shared<FormulaProcessingContext>(context_instance)); @@ -746,7 +748,7 @@ void ScViewFunc::EnterData( SCCOL nCol, SCROW nRow, SCTAB nTab, else { ScFieldEditEngine& rEngine = rDoc.GetEditEngine(); - for (const auto& rTab : rMark) + for (const auto& rTab : aMark) { bool bNumFmtSet = false; const ScAddress aScAddress(nCol, nRow, rTab); @@ -770,7 +772,7 @@ void ScViewFunc::EnterData( SCCOL nCol, SCROW nRow, SCTAB nTab, bNumFmtChanged = true; } } - performAutoFormatAndUpdate(rString, rMark, nCol, nRow, nTab, bNumFmtChanged, bRecord, xModificator, *this); + performAutoFormatAndUpdate(rString, aMark, nCol, nRow, nTab, bNumFmtChanged, bRecord, xModificator, *this); } } diff --git a/slideshow/source/engine/animationnodes/basenode.cxx b/slideshow/source/engine/animationnodes/basenode.cxx index 377520369997..dd8387eddb1b 100644 --- a/slideshow/source/engine/animationnodes/basenode.cxx +++ b/slideshow/source/engine/animationnodes/basenode.cxx @@ -538,7 +538,6 @@ void BaseNode::scheduleDeactivationEvent( EventSharedPtr const& pEvent ) // if anim base node has no activity, this is called to schedule deactivation, // but what if it does not schedule anything? - auto self(mpSelf); if (mxAnimationNode->getEnd().hasValue()) { // TODO: We may need to calculate the duration if the end value is numeric. @@ -547,7 +546,7 @@ void BaseNode::scheduleDeactivationEvent( EventSharedPtr const& pEvent ) // until we find a test case. mpCurrentEvent = generateEvent( mxAnimationNode->getEnd(), - [self] () { self->deactivate(); }, + [self=mpSelf] () { self->deactivate(); }, maContext, 0.0 ); } @@ -555,7 +554,7 @@ void BaseNode::scheduleDeactivationEvent( EventSharedPtr const& pEvent ) { mpCurrentEvent = generateEvent( mxAnimationNode->getDuration(), - [self] () { self->deactivate(); }, + [self=mpSelf] () { self->deactivate(); }, maContext, 0.0 ); } } diff --git a/svx/source/diagram/datamodel.cxx b/svx/source/diagram/datamodel.cxx index 0cf0541cd2a1..3f7e5864bfb1 100644 --- a/svx/source/diagram/datamodel.cxx +++ b/svx/source/diagram/datamodel.cxx @@ -126,13 +126,13 @@ bool DiagramData::removeNode(const OUString& rNodeId) // remove connections std::erase_if(maConnections, - [aIdsToRemove](const Connection& rCxn) { + [&aIdsToRemove](const Connection& rCxn) { return aIdsToRemove.count(rCxn.msSourceId) || aIdsToRemove.count(rCxn.msDestId); }); // remove data and presentation nodes std::erase_if(maPoints, - [aIdsToRemove](const Point& rPoint) { + [&aIdsToRemove](const Point& rPoint) { return aIdsToRemove.count(rPoint.msModelId); }); diff --git a/svx/source/dialog/grfflt.cxx b/svx/source/dialog/grfflt.cxx index 49e97a9017ee..425364fb0498 100644 --- a/svx/source/dialog/grfflt.cxx +++ b/svx/source/dialog/grfflt.cxx @@ -35,11 +35,11 @@ static void handleGraphicFilterDialog(const VclPtr<AbstractGraphicFilterDialog>& pDlg, const Graphic& aInputGraphic, - const std::function<void(const GraphicObject&)>& f); + const std::function<void(const Graphic&)>& f); void SvxGraphicFilter::ExecuteGrfFilterSlot( SfxRequest const & rReq, const GraphicObject& rInputObject, - const std::function<void(const GraphicObject&)>& f) + const std::function<void(const Graphic&)>& f) { Graphic aInputGraphic = rInputObject.GetGraphic(); @@ -260,7 +260,7 @@ void SvxGraphicFilter::ExecuteGrfFilterSlot( SfxRequest const & rReq, static void handleGraphicFilterDialog(const VclPtr<AbstractGraphicFilterDialog>& pDlg, const Graphic& aInputGraphic, - const std::function<void(const GraphicObject&)>& f) + const std::function<void(const Graphic&)>& f) { pDlg->StartExecuteAsync( [pDlg, aInputGraphic, f] (sal_Int32 nResult)->void diff --git a/unoidl/source/sourceprovider-parser.y b/unoidl/source/sourceprovider-parser.y index 28c13937561f..0ce80ac5d9ac 100644 --- a/unoidl/source/sourceprovider-parser.y +++ b/unoidl/source/sourceprovider-parser.y @@ -2360,7 +2360,7 @@ singleInterfaceBasedServiceDefn: } ctors.push_back( unoidl::SingleInterfaceBasedServiceEntity::Constructor( - i.name, std::vector(parms), std::vector(i.exceptions), std::vector(i.annotations))); + i.name, std::move(parms), std::vector(i.exceptions), std::vector(i.annotations))); } } else { assert(pad->constructors.empty()); diff --git a/vcl/source/app/settings.cxx b/vcl/source/app/settings.cxx index 38ea04d4d4ba..2372a380937c 100644 --- a/vcl/source/app/settings.cxx +++ b/vcl/source/app/settings.cxx @@ -661,9 +661,9 @@ void ImplStyleData::SetStandardStyles() maFieldFont = aStdFont; maIconFont = aStdFont; maTabFont = aStdFont; + aStdFont.SetWeight( WEIGHT_BOLD ); - maFloatTitleFont = aStdFont; - maTitleFont = aStdFont; + maFloatTitleFont = maTitleFont = std::move(aStdFont); maFaceColor = COL_LIGHTGRAY; maCheckedColor = Color( 0xCC, 0xCC, 0xCC );
