[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.2' - chart2/source
Jan Holesovsky (via logerrit)
logerrit at kemper.freedesktop.org
Fri Jun 5 19:29:12 UTC 2020
chart2/source/controller/dialogs/dlg_CreationWizard_UNO.cxx | 7 +++++++
1 file changed, 7 insertions(+)
New commits:
commit fced46a2838d800a1eaa9328a7aa18b868bd6013
Author: Jan Holesovsky <kendy at collabora.com>
AuthorDate: Thu May 30 10:20:15 2019 +0200
Commit: Michael Meeks <michael.meeks at collabora.com>
CommitDate: Fri Jun 5 21:28:43 2020 +0200
chart lok: Assign a parent to the chart wizard if it has none.
Without this, the dialog was not routed, so only the chart has been
inserted, but wizard cancelled.
The pParent started to be nullptr after the recent "lok: Don't activate
chart on insert."
Change-Id: Ia04854599aa1387360048412f073e4eb903fb40e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/95613
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
Reviewed-by: Michael Meeks <michael.meeks at collabora.com>
diff --git a/chart2/source/controller/dialogs/dlg_CreationWizard_UNO.cxx b/chart2/source/controller/dialogs/dlg_CreationWizard_UNO.cxx
index ba08b5b7ed55..65bf64ea7b64 100644
--- a/chart2/source/controller/dialogs/dlg_CreationWizard_UNO.cxx
+++ b/chart2/source/controller/dialogs/dlg_CreationWizard_UNO.cxx
@@ -33,6 +33,7 @@
#include <comphelper/sequence.hxx>
#include <tools/diagnose_ex.h>
#include <comphelper/lok.hxx>
+#include <sfx2/viewfrm.hxx>
namespace chart
{
@@ -168,12 +169,18 @@ void CreationWizardUnoDlg::createDialogOnDemand()
m_xParentWindow = xFrame->getContainerWindow();
}
}
+
if( m_xParentWindow.is() )
{
VCLXWindow* pImplementation = VCLXWindow::GetImplementation(m_xParentWindow);
if (pImplementation)
pParent = pImplementation->GetWindow().get();
}
+ else if (comphelper::LibreOfficeKit::isActive())
+ {
+ pParent = &SfxViewFrame::Current()->GetWindow();
+ }
+
uno::Reference< XComponent > xComp( this );
if( m_xChartModel.is() )
m_pDialog = VclPtr<CreationWizard>::Create( pParent, m_xChartModel, m_xCC );
More information about the Libreoffice-commits
mailing list