cui/source/factory/dlgfact.cxx | 8 +++++++- include/svx/cuicharmap.hxx | 4 ++++ oox/source/drawingml/diagram/layoutnodecontext.cxx | 2 +- sc/source/core/tool/interpr1.cxx | 2 +- sd/source/ui/annotations/annotationmanager.cxx | 2 +- svgio/source/svgreader/svgcharacternode.cxx | 4 ++-- svx/source/dialog/cuicharmap.cxx | 6 +++++- sw/source/writerfilter/dmapper/DomainMapper_Impl.cxx | 2 +- 8 files changed, 22 insertions(+), 8 deletions(-)
New commits: commit 80a6f398eb19a5808b3b7c2a682be2e1bb0f17ed Author: Caolán McNamara <caolan.mcnam...@collabora.com> AuthorDate: Wed Jul 10 09:45:24 2024 +0100 Commit: Caolán McNamara <caolan.mcnam...@collabora.com> CommitDate: Wed Jul 10 17:29:07 2024 +0200 regain the SvxCharacterMap "pre-run" logic in async mode since: commit 6a5ef1a2b009f208745a251828bf8e8c51146bfe Date: Mon Jan 22 12:35:50 2024 +0200 make charmap dialog async Change-Id: I5fc13e759eb8f1d1e6ab7c09f39cabc1d4c4ad7e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170276 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnam...@collabora.com> diff --git a/cui/source/factory/dlgfact.cxx b/cui/source/factory/dlgfact.cxx index e3556334e6a3..ffb2ee562c10 100644 --- a/cui/source/factory/dlgfact.cxx +++ b/cui/source/factory/dlgfact.cxx @@ -115,7 +115,7 @@ IMPL_ABSTDLG_CLASS_ASYNC(AbstractLinksDialog, SvBaseLinksDlg) IMPL_ABSTDLG_CLASS(AbstractScreenshotAnnotationDlg) IMPL_ABSTDLG_CLASS_ASYNC(AbstractSignatureLineDialog, SignatureLineDialog) IMPL_ABSTDLG_CLASS_ASYNC(AbstractSignSignatureLineDialog, SignSignatureLineDialog) -IMPL_ABSTDLG_CLASS_ASYNC(AbstractSvxCharacterMapDialog, SvxCharacterMap) +IMPL_ABSTDLG_CLASS(AbstractSvxCharacterMapDialog) IMPL_ABSTDLG_CLASS(AbstractSecurityOptionsDialog) IMPL_ABSTDLG_CLASS(AbstractSvxHpLinkDlg) IMPL_ABSTDLG_CLASS(AbstractSvxJSearchOptionsDialog) @@ -164,6 +164,12 @@ void AbstractSvxCharacterMapDialog_Impl::SetText(const OUString& rStr) m_xDlg->set_title(rStr); } +bool AbstractSvxCharacterMapDialog_Impl::StartExecuteAsync(AsyncContext &rCtx) +{ + m_xDlg->prepForRun(); + return SvxCharacterMap::runAsync(m_xDlg, rCtx.maEndDialogFn); +} + void CuiAbstractTabController_Impl::SetCurPageId( const OUString &rName ) { m_xDlg->SetCurPageId( rName ); diff --git a/include/svx/cuicharmap.hxx b/include/svx/cuicharmap.hxx index 57f28615598a..0d95eb198e04 100644 --- a/include/svx/cuicharmap.hxx +++ b/include/svx/cuicharmap.hxx @@ -136,6 +136,10 @@ private: public: SvxCharacterMap(weld::Widget* pParent, const SfxItemSet* pSet, css::uno::Reference<css::frame::XFrame> xFrame); + + // for explicit use before AsyncRun + void prepForRun(); + virtual short run() override; void set_title(const OUString& rTitle) { m_xDialog->set_title(rTitle); } diff --git a/svx/source/dialog/cuicharmap.cxx b/svx/source/dialog/cuicharmap.cxx index c5f2a1b128c4..de115cf8332a 100644 --- a/svx/source/dialog/cuicharmap.cxx +++ b/svx/source/dialog/cuicharmap.cxx @@ -116,7 +116,7 @@ SvxCharacterMap::SvxCharacterMap(weld::Widget* pParent, const SfxItemSet* pSet, m_xSearchSet->Hide(); } -short SvxCharacterMap::run() +void SvxCharacterMap::prepForRun() { if( SvxShowCharSet::getSelectedChar() == ' ') { @@ -133,7 +133,11 @@ short SvxCharacterMap::run() setFavButtonState(aOUStr, m_aShowChar.GetFont().GetFamilyName()); m_xOKBtn->set_sensitive(true); } +} +short SvxCharacterMap::run() +{ + prepForRun(); return SfxDialogController::run(); } commit e6c4d733f15bb779f02afa910149408df8c7fda2 Author: Caolán McNamara <caolan.mcnam...@collabora.com> AuthorDate: Wed Jul 10 11:02:15 2024 +0100 Commit: Caolán McNamara <caolan.mcnam...@collabora.com> CommitDate: Wed Jul 10 17:28:56 2024 +0200 cid#1556474 COPY_INSTEAD_OF_MOVE and cid#1557319 COPY_INSTEAD_OF_MOVE cid#1557320 COPY_INSTEAD_OF_MOVE cid#1558101 COPY_INSTEAD_OF_MOVE cid#1606536 COPY_INSTEAD_OF_MOVE Change-Id: Ibe10ee3fad7f6ca1f3c5b316fdafe4bf15f0ead7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170280 Reviewed-by: Caolán McNamara <caolan.mcnam...@collabora.com> Tested-by: Jenkins diff --git a/oox/source/drawingml/diagram/layoutnodecontext.cxx b/oox/source/drawingml/diagram/layoutnodecontext.cxx index d822805ed2d6..ae893ed64cfa 100644 --- a/oox/source/drawingml/diagram/layoutnodecontext.cxx +++ b/oox/source/drawingml/diagram/layoutnodecontext.cxx @@ -244,7 +244,7 @@ LayoutNodeContext::onCreateContext( ::sal_Int32 aElement, ShapeAtomPtr pAtom = std::make_shared<ShapeAtom>(mpNode->getLayoutNode(), pShape); LayoutAtom::connect(mpNode, pAtom); - return new ShapeContext( *this, ShapePtr(), pShape ); + return new ShapeContext( *this, ShapePtr(), std::move(pShape) ); } case DGM_TOKEN( extLst ): return nullptr; diff --git a/sc/source/core/tool/interpr1.cxx b/sc/source/core/tool/interpr1.cxx index 73b25d541fa4..f4b9478cbb6b 100644 --- a/sc/source/core/tool/interpr1.cxx +++ b/sc/source/core/tool/interpr1.cxx @@ -386,7 +386,7 @@ void ScInterpreter::ScIfError( bool bNAonly ) } nR = 0; } - xNew = new ScJumpMatrixToken( pJumpMat ); + xNew = new ScJumpMatrixToken(std::move(pJumpMat)); GetTokenMatrixMap().emplace( pCur, xNew ); } nGlobalError = nOldGlobalError; diff --git a/sd/source/ui/annotations/annotationmanager.cxx b/sd/source/ui/annotations/annotationmanager.cxx index 940c763f73cc..c55cb5ae7567 100644 --- a/sd/source/ui/annotations/annotationmanager.cxx +++ b/sd/source/ui/annotations/annotationmanager.cxx @@ -1102,7 +1102,7 @@ void AnnotationManagerImpl::SyncAnnotationObjects() for (auto const& rPolygon : rInfo.maPolygons) aPolyPolygon.append(rPolygon); - pNewObject = new SdrPathObj(rModel, ekind, aPolyPolygon); + pNewObject = new SdrPathObj(rModel, ekind, std::move(aPolyPolygon)); applyAnnotationCommon(*pNewObject, xAnnotation); applyAnnotationProperties(*pNewObject, rInfo); diff --git a/svgio/source/svgreader/svgcharacternode.cxx b/svgio/source/svgreader/svgcharacternode.cxx index 632765d328c1..ca1f91ebb99a 100644 --- a/svgio/source/svgreader/svgcharacternode.cxx +++ b/svgio/source/svgreader/svgcharacternode.cxx @@ -396,7 +396,7 @@ namespace svgio::svgreader std::move(aTextArray), {}, aFontAttribute, - aLocale, + std::move(aLocale), aFill, COL_TRANSPARENT, @@ -425,7 +425,7 @@ namespace svgio::svgreader std::move(aTextArray), {}, aFontAttribute, - aLocale, + std::move(aLocale), aFill); } diff --git a/sw/source/writerfilter/dmapper/DomainMapper_Impl.cxx b/sw/source/writerfilter/dmapper/DomainMapper_Impl.cxx index 6d6d54d7ac4a..6cecc59dd4a4 100644 --- a/sw/source/writerfilter/dmapper/DomainMapper_Impl.cxx +++ b/sw/source/writerfilter/dmapper/DomainMapper_Impl.cxx @@ -1485,7 +1485,7 @@ uno::Any DomainMapper_Impl::GetPropertyFromStyleSheet(PropertyIds eId, StyleShee if (pEntry == pNewEntry) //fdo#49587 break; - pEntry = pNewEntry; + pEntry = std::move(pNewEntry); } // not found in style, try the document's DocDefault properties if ( bDocDefaults && bPara )