[Libreoffice-commits] core.git: svx/sdi svx/source sw/source

Caolán McNamara caolanm at redhat.com
Fri Nov 10 10:28:20 UTC 2017


 svx/sdi/svx.sdi                          |    2 +-
 svx/source/tbxctrls/bulletsnumbering.cxx |    3 ++-
 sw/source/uibase/shells/txtnum.cxx       |    8 +++++++-
 3 files changed, 10 insertions(+), 3 deletions(-)

New commits:
commit 31b26130d90d4746cbb126fd9b6c1cb3487f644f
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Nov 9 16:11:25 2017 +0000

    tdf#113647 bullet dialog has wrong modal parent
    
    Change-Id: Ia2e6171a1aeb3b8ad679a547a63ccaeac20481df
    Reviewed-on: https://gerrit.libreoffice.org/44554
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

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 )


More information about the Libreoffice-commits mailing list