summaryrefslogtreecommitdiff
path: root/cui/source/factory/dlgfact.cxx
diff options
context:
space:
mode:
authorMatt K <mattkse@gmail.com>2021-04-03 01:24:30 -0500
committerHeiko Tietze <heiko.tietze@documentfoundation.org>2021-05-18 09:02:22 +0200
commit7f032b2f16fad56beea1df826eb59c6f85c71268 (patch)
treebbdc4e32f22c0fa9ddbe7dfec801120f29b2a29f /cui/source/factory/dlgfact.cxx
parent2c4dd73c4c9f471fa2083f9f99dd27a7148f3175 (diff)
tdf#127533 Make Tip-of-the-Day dialog non-modal and allow multiple tips to open
The Tip-of-the-Day dialog is made non-modal and stays on-top of the main window while allowing the user to interact with the rest of application. Change-Id: I51e1a3488ab74d8371b71a8585d1512ce051f637 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113782 Reviewed-by: Matt K <mattkse@gmail.com> Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org> Tested-by: Jenkins
Diffstat (limited to 'cui/source/factory/dlgfact.cxx')
-rw-r--r--cui/source/factory/dlgfact.cxx14
1 files changed, 12 insertions, 2 deletions
diff --git a/cui/source/factory/dlgfact.cxx b/cui/source/factory/dlgfact.cxx
index 6d0a44086d47..6d0e9e31f77f 100644
--- a/cui/source/factory/dlgfact.cxx
+++ b/cui/source/factory/dlgfact.cxx
@@ -106,6 +106,16 @@ short CuiAbstractController_Impl::Execute()
return m_xDlg->run();
}
+short CuiAbstractTipController_Impl::Execute()
+{
+ return m_xDlg->run();
+}
+
+bool CuiAbstractTipController_Impl::StartExecuteAsync(AsyncContext& rCtx)
+{
+ return weld::DialogController::runAsync(m_xDlg, rCtx.maEndDialogFn);
+}
+
short CuiAbstractSingleTabController_Impl::Execute()
{
return m_xDlg->run();
@@ -1682,8 +1692,8 @@ AbstractDialogFactory_Impl::CreateAboutDialog(weld::Window* pParent)
VclPtr<VclAbstractDialog>
AbstractDialogFactory_Impl::CreateTipOfTheDayDialog(weld::Window* pParent)
{
- return VclPtr<CuiAbstractController_Impl>::Create(
- std::make_unique<TipOfTheDayDialog>(pParent));
+ return VclPtr<CuiAbstractTipController_Impl>::Create(
+ std::make_shared<TipOfTheDayDialog>(pParent));
}
VclPtr<VclAbstractDialog>