sd/source/ui/animations/SlideTransitionPane.cxx | 5 +++-- sfx2/source/appl/opengrf.cxx | 4 +++- 2 files changed, 6 insertions(+), 3 deletions(-)
New commits: commit e6b2761cb7299d2e93ce5cfc5b53309c6588f2ee Author: Caolán McNamara <caol...@redhat.com> AuthorDate: Tue Jan 17 20:32:38 2023 +0000 Commit: Caolán McNamara <caol...@redhat.com> CommitDate: Wed Jan 18 10:49:23 2023 +0000 give message dialog a suitable parent Change-Id: I2eb21cbc9e89189ab0fa4090c04fec98f654a542 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145687 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caol...@redhat.com> diff --git a/sd/source/ui/animations/SlideTransitionPane.cxx b/sd/source/ui/animations/SlideTransitionPane.cxx index 30ccf1a51a7b..ac3f01762d50 100644 --- a/sd/source/ui/animations/SlideTransitionPane.cxx +++ b/sd/source/ui/animations/SlideTransitionPane.cxx @@ -683,7 +683,8 @@ void SlideTransitionPane::openSoundFileDialog() if( ! mxLB_SOUND->get_sensitive()) return; - SdOpenSoundFileDialog aFileDialog(GetFrameWeld()); + weld::Window* pDialogParent(GetFrameWeld()); + SdOpenSoundFileDialog aFileDialog(pDialogParent); DBG_ASSERT( mxLB_SOUND->get_active() == 2, "Dialog should only open when \"Other sound\" is selected" ); @@ -717,7 +718,7 @@ void SlideTransitionPane::openSoundFileDialog() { OUString aStrWarning(SdResId(STR_WARNING_NOSOUNDFILE)); aStrWarning = aStrWarning.replaceFirst("%", aFile); - std::unique_ptr<weld::MessageDialog> xWarn(Application::CreateMessageDialog(nullptr, + std::unique_ptr<weld::MessageDialog> xWarn(Application::CreateMessageDialog(pDialogParent, VclMessageType::Warning, VclButtonsType::NONE, aStrWarning)); xWarn->add_button(GetStandardText(StandardButtonType::Retry), RET_RETRY); commit 7ed2ddbb5c19451e65595becf9b25e6d583fc48b Author: Caolán McNamara <caol...@redhat.com> AuthorDate: Tue Jan 17 20:10:16 2023 +0000 Commit: Caolán McNamara <caol...@redhat.com> CommitDate: Wed Jan 18 10:49:14 2023 +0000 set a parent for this warning dialog Change-Id: Ia15a3cf7cc5136d2db7463f7486bcc14f4f6a6b7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145686 Tested-by: Caolán McNamara <caol...@redhat.com> Reviewed-by: Caolán McNamara <caol...@redhat.com> diff --git a/sfx2/source/appl/opengrf.cxx b/sfx2/source/appl/opengrf.cxx index 325c50422479..3c94ca7ffbc5 100644 --- a/sfx2/source/appl/opengrf.cxx +++ b/sfx2/source/appl/opengrf.cxx @@ -67,6 +67,7 @@ struct SvxOpenGrf_Impl sfx2::FileDialogHelper aFileDlg; OUString sDetectedFilter; + weld::Window* pDialogParent; uno::Reference < XFilePickerControlAccess > xCtrlAcc; }; @@ -74,6 +75,7 @@ struct SvxOpenGrf_Impl SvxOpenGrf_Impl::SvxOpenGrf_Impl(weld::Window* pPreferredParent, sal_Int16 nDialogType) : aFileDlg(nDialogType, FileDialogFlags::Graphic, pPreferredParent) + , pDialogParent(pPreferredParent) { uno::Reference < XFilePicker3 > xFP = aFileDlg.GetFilePicker(); xCtrlAcc.set(xFP, UNO_QUERY); @@ -152,7 +154,7 @@ ErrCode SvxOpenGraphicDialog::Execute() // could not load? if ( nFound == USHRT_MAX ) { - std::unique_ptr<weld::MessageDialog> xWarn(Application::CreateMessageDialog(nullptr, + std::unique_ptr<weld::MessageDialog> xWarn(Application::CreateMessageDialog(mpImpl->pDialogParent, VclMessageType::Warning, VclButtonsType::NONE, SfxResId(SvxOpenGrfErr2ResId(nImpRet)))); xWarn->add_button(GetStandardText(StandardButtonType::Retry), RET_RETRY);