sw/source/ui/index/swuiidxmrk.cxx | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-)
New commits: commit e624b539810301ad3bb78d44ef990ea95c778c40 Author: Caolán McNamara <[email protected]> AuthorDate: Mon Dec 15 11:39:33 2025 +0000 Commit: Caolán McNamara <[email protected]> CommitDate: Mon Dec 15 18:37:56 2025 +0100 make SwNewUserIdxDlg async Change-Id: I1198eaed112f0b0083cf7e5347e1a1128a015c91 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/195661 Reviewed-by: Szymon Kłos <[email protected]> Tested-by: Jenkins CollaboraOffice <[email protected]> diff --git a/sw/source/ui/index/swuiidxmrk.cxx b/sw/source/ui/index/swuiidxmrk.cxx index e3f61cf04b03..1d9a365c6150 100644 --- a/sw/source/ui/index/swuiidxmrk.cxx +++ b/sw/source/ui/index/swuiidxmrk.cxx @@ -661,13 +661,14 @@ IMPL_LINK( SwNewUserIdxDlg, ModifyHdl, weld::Entry&, rEdit, void) IMPL_LINK_NOARG(SwIndexMarkPane, NewUserIdxHdl, weld::Button&, void) { - SwNewUserIdxDlg aDlg(this, m_xDialog.get()); - if (aDlg.run() == RET_OK) - { - OUString sNewName(aDlg.GetName()); - m_xTypeDCB->append_text(sNewName); - m_xTypeDCB->set_active_text(sNewName); - } + auto xDlg = std::make_shared<SwNewUserIdxDlg>(this, m_xDialog.get()); + weld::GenericDialogController::runAsync(xDlg, [xDlg, this](sal_Int32 nResult){ + if (nResult == RET_OK) { + OUString sNewName(xDlg->GetName()); + m_xTypeDCB->append_text(sNewName); + m_xTypeDCB->set_active_text(sNewName); + } + }); } IMPL_LINK( SwIndexMarkPane, SearchTypeHdl, weld::Toggleable&, rBox, void)
