diff options
author | Caolán McNamara <caolanm@redhat.com> | 2017-11-09 16:11:25 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2017-11-10 11:27:15 +0100 |
commit | 31b26130d90d4746cbb126fd9b6c1cb3487f644f (patch) | |
tree | f155f49414e95d2b34727ced6bafafca4418a99e | |
parent | 394dbb7f637afe10041506975b5dbc2202a78b4d (diff) |
tdf#113647 bullet dialog has wrong modal parent
Change-Id: Ia2e6171a1aeb3b8ad679a547a63ccaeac20481df
Reviewed-on: https://gerrit.libreoffice.org/44554
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r-- | svx/sdi/svx.sdi | 2 | ||||
-rw-r--r-- | svx/source/tbxctrls/bulletsnumbering.cxx | 3 | ||||
-rw-r--r-- | sw/source/uibase/shells/txtnum.cxx | 8 |
3 files changed, 10 insertions, 3 deletions
diff --git a/svx/sdi/svx.sdi b/svx/sdi/svx.sdi index 3d684944a963..4737b1333dfe 100644 --- a/svx/sdi/svx.sdi +++ b/svx/sdi/svx.sdi @@ -5880,7 +5880,7 @@ SvxOrphansItem Orphan SID_ATTR_PARA_ORPHANS SfxVoidItem OutlineBullet SID_OUTLINE_BULLET -(SfxStringItem Page FN_PARAM_1) +(SfxStringItem Page FN_PARAM_1,SfxStringItem ParentWindow FN_PARAM_2) [ AutoUpdate = FALSE, FastCall = FALSE, diff --git a/svx/source/tbxctrls/bulletsnumbering.cxx b/svx/source/tbxctrls/bulletsnumbering.cxx index 07f48303600f..42714fae2bbb 100644 --- a/svx/source/tbxctrls/bulletsnumbering.cxx +++ b/svx/source/tbxctrls/bulletsnumbering.cxx @@ -180,7 +180,8 @@ void NumberingPopup::VSSelectHdl(void const * pControl) } else if ( getSelectedEntryId() == 1 ) { - auto aArgs( comphelper::InitPropertySequence( { { "Page", css::uno::makeAny( OUString("customize") ) } } ) ); + auto aArgs( comphelper::InitPropertySequence( { { "Page", css::uno::makeAny( OUString("customize") ) }, + { "ParentWindow", css::uno::makeAny( OUString::number(reinterpret_cast<sal_uInt64>(GetParent())) ) } } ) ); mrController.dispatchCommand( ".uno:OutlineBullet", aArgs ); } } diff --git a/sw/source/uibase/shells/txtnum.cxx b/sw/source/uibase/shells/txtnum.cxx index 2e3d4cbfc142..9fd26cfe69a0 100644 --- a/sw/source/uibase/shells/txtnum.cxx +++ b/sw/source/uibase/shells/txtnum.cxx @@ -183,8 +183,14 @@ void SwTextShell::ExecEnterNum(SfxRequest &rReq) pDocSh->PutItem(SfxUInt16Item(SID_HTML_MODE, ::GetHtmlMode(pDocSh))); SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create(); + + vcl::Window *pParent = GetView().GetWindow(); + const SfxStringItem* pParentItem = rReq.GetArg<SfxStringItem>(FN_PARAM_2); + if (pParentItem) + pParent = reinterpret_cast<vcl::Window*>(pParentItem->GetValue().toUInt64()); + assert(pFact && "Dialog creation failed!"); - ScopedVclPtr<SfxAbstractTabDialog> pDlg(pFact->CreateSvxNumBulletTabDialog(GetView().GetWindow(), &aSet, GetShell())); + ScopedVclPtr<SfxAbstractTabDialog> pDlg(pFact->CreateSvxNumBulletTabDialog(pParent, &aSet, GetShell())); assert(pDlg && "Dialog creation failed!"); const SfxStringItem* pPageItem = rReq.GetArg<SfxStringItem>(FN_PARAM_1); if ( pPageItem ) |