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

Caolán McNamara caolanm at redhat.com
Fri Mar 16 20:31:32 UTC 2018


 sw/inc/swabstdlg.hxx                            |    2 +-
 sw/source/ui/dialog/swdlgfact.cxx               |    4 ++--
 sw/source/ui/dialog/swdlgfact.hxx               |    2 +-
 sw/source/ui/table/convert.cxx                  |    2 +-
 sw/source/uibase/dialog/SignatureLineDialog.cxx |    5 +++--
 sw/source/uibase/inc/SignatureLineDialog.hxx    |    2 +-
 sw/source/uibase/uiview/viewdlg2.cxx            |    2 +-
 7 files changed, 10 insertions(+), 9 deletions(-)

New commits:
commit 28d73ca4b1297345cefed1a092d983bb59a6c445
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Fri Mar 16 13:30:47 2018 +0000

    can get the window from the SwView
    
    Change-Id: Ifa3033b928db817ccdc4337f8995179bc488fcb6
    Reviewed-on: https://gerrit.libreoffice.org/51425
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/sw/inc/swabstdlg.hxx b/sw/inc/swabstdlg.hxx
index 7c7861797d03..d11d882052b5 100644
--- a/sw/inc/swabstdlg.hxx
+++ b/sw/inc/swabstdlg.hxx
@@ -400,7 +400,7 @@ public:
         SwCharDlgMode nDialogMode, const OUString* pFormatStr = nullptr) = 0;
     virtual VclPtr<AbstractSwConvertTableDlg> CreateSwConvertTableDlg(SwView& rView, bool bToTable) = 0;
     virtual VclPtr<VclAbstractDialog> CreateSwCaptionDialog ( vcl::Window *pParent, SwView &rV) = 0;
-    virtual VclPtr<VclAbstractDialog> CreateSignatureLineDialog(weld::Window* pParent, SwView& rView) = 0;
+    virtual VclPtr<VclAbstractDialog> CreateSignatureLineDialog(SwView& rView) = 0;
 
     virtual VclPtr<AbstractSwInsertDBColAutoPilot> CreateSwInsertDBColAutoPilot(SwView& rView,
         css::uno::Reference< css::sdbc::XDataSource> rxSource,
diff --git a/sw/source/ui/dialog/swdlgfact.cxx b/sw/source/ui/dialog/swdlgfact.cxx
index b0724dcf18e7..9000ad0380e1 100644
--- a/sw/source/ui/dialog/swdlgfact.cxx
+++ b/sw/source/ui/dialog/swdlgfact.cxx
@@ -728,9 +728,9 @@ VclPtr<VclAbstractDialog> SwAbstractDialogFactory_Impl::CreateSwCaptionDialog (
     return VclPtr<VclAbstractDialog_Impl>::Create( pDlg );
 }
 
-VclPtr<VclAbstractDialog> SwAbstractDialogFactory_Impl::CreateSignatureLineDialog(weld::Window* pParent, SwView& rV)
+VclPtr<VclAbstractDialog> SwAbstractDialogFactory_Impl::CreateSignatureLineDialog(SwView& rV)
 {
-    return VclPtr<AbstractSignatureLineDialog_Impl>::Create(new SignatureLineDialog(pParent, rV));
+    return VclPtr<AbstractSignatureLineDialog_Impl>::Create(new SignatureLineDialog(rV));
 }
 
 VclPtr<AbstractSwInsertDBColAutoPilot> SwAbstractDialogFactory_Impl::CreateSwInsertDBColAutoPilot( SwView& rView,
diff --git a/sw/source/ui/dialog/swdlgfact.hxx b/sw/source/ui/dialog/swdlgfact.hxx
index 33db10f8cb49..caf3059c86ac 100644
--- a/sw/source/ui/dialog/swdlgfact.hxx
+++ b/sw/source/ui/dialog/swdlgfact.hxx
@@ -451,7 +451,7 @@ public:
         SwCharDlgMode nDialogMode, const OUString* pFormatStr = nullptr) override;
     virtual VclPtr<AbstractSwConvertTableDlg> CreateSwConvertTableDlg(SwView& rView, bool bToTable) override;
     virtual VclPtr<VclAbstractDialog> CreateSwCaptionDialog ( vcl::Window *pParent, SwView &rV) override;
-    virtual VclPtr<VclAbstractDialog> CreateSignatureLineDialog(weld::Window* pParent, SwView& rView) override;
+    virtual VclPtr<VclAbstractDialog> CreateSignatureLineDialog(SwView& rView) override;
 
     virtual VclPtr<AbstractSwInsertDBColAutoPilot> CreateSwInsertDBColAutoPilot(SwView& rView,
         css::uno::Reference< css::sdbc::XDataSource> rxSource,
diff --git a/sw/source/ui/table/convert.cxx b/sw/source/ui/table/convert.cxx
index f33d262bba41..dd7007cf0a13 100644
--- a/sw/source/ui/table/convert.cxx
+++ b/sw/source/ui/table/convert.cxx
@@ -94,7 +94,7 @@ void SwConvertTableDlg::GetValues(  sal_Unicode& rDelim,
 }
 
 SwConvertTableDlg::SwConvertTableDlg(SwView& rView, bool bToTable)
-    : GenericDialogController(rView.GetViewFrame()->GetWindow().GetFrameWeld(),
+    : GenericDialogController(rView.GetFrameWeld(),
             "modules/swriter/ui/converttexttable.ui", "ConvertTextTableDialog")
     , m_xTabBtn(m_xBuilder->weld_radio_button("tabs"))
     , m_xSemiBtn(m_xBuilder->weld_radio_button("semicolons"))
diff --git a/sw/source/uibase/dialog/SignatureLineDialog.cxx b/sw/source/uibase/dialog/SignatureLineDialog.cxx
index 2b0f48a42703..8d3df885beff 100644
--- a/sw/source/uibase/dialog/SignatureLineDialog.cxx
+++ b/sw/source/uibase/dialog/SignatureLineDialog.cxx
@@ -37,8 +37,9 @@ using namespace css::view;
 using namespace css::drawing;
 using namespace css::graphic;
 
-SignatureLineDialog::SignatureLineDialog(weld::Window* pParent, SwView& rView)
-    : GenericDialogController(pParent, "modules/swriter/ui/signatureline.ui", "SignatureLineDialog")
+SignatureLineDialog::SignatureLineDialog(SwView& rView)
+    : GenericDialogController(rView.GetFrameWeld(), "modules/swriter/ui/signatureline.ui",
+                              "SignatureLineDialog")
     , m_xEditName(m_xBuilder->weld_entry("edit_name"))
     , m_xEditTitle(m_xBuilder->weld_entry("edit_title"))
     , m_xEditEmail(m_xBuilder->weld_entry("edit_email"))
diff --git a/sw/source/uibase/inc/SignatureLineDialog.hxx b/sw/source/uibase/inc/SignatureLineDialog.hxx
index f3da0ba0bad2..80d7cf87289d 100644
--- a/sw/source/uibase/inc/SignatureLineDialog.hxx
+++ b/sw/source/uibase/inc/SignatureLineDialog.hxx
@@ -21,7 +21,7 @@ class SwView;
 class SW_DLLPUBLIC SignatureLineDialog : public weld::GenericDialogController
 {
 public:
-    SignatureLineDialog(weld::Window* pParent, SwView& rView);
+    SignatureLineDialog(SwView& rView);
 
     short execute();
 
diff --git a/sw/source/uibase/uiview/viewdlg2.cxx b/sw/source/uibase/uiview/viewdlg2.cxx
index ec56e4df9c66..35a1409dd78b 100644
--- a/sw/source/uibase/uiview/viewdlg2.cxx
+++ b/sw/source/uibase/uiview/viewdlg2.cxx
@@ -67,7 +67,7 @@ void SwView::ExecDlgExt(SfxRequest const &rReq)
             SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create();
             assert(pFact && "SwAbstractDialogFactory fail!");
 
-            ScopedVclPtr<VclAbstractDialog> pDialog(pFact->CreateSignatureLineDialog(rMDI.GetFrameWeld(), *this));
+            ScopedVclPtr<VclAbstractDialog> pDialog(pFact->CreateSignatureLineDialog(*this));
             assert(pDialog && "Dialog creation failed!");
             if (pDialog)
                 pDialog->Execute();


More information about the Libreoffice-commits mailing list