[Libreoffice-commits] core.git: 2 commits - dbaccess/source

Caolán McNamara (via logerrit) logerrit at kemper.freedesktop.org
Fri Aug 2 13:05:27 UTC 2019


 dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx |    8 ++---
 dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx |    8 ++---
 dbaccess/source/ui/dlg/admincontrols.cxx          |   34 +++++++++++-----------
 dbaccess/source/ui/dlg/admincontrols.hxx          |    6 +--
 dbaccess/source/ui/dlg/adminpages.cxx             |    2 -
 dbaccess/source/ui/dlg/adminpages.hxx             |    4 +-
 dbaccess/source/ui/dlg/detailpages.cxx            |    2 -
 dbaccess/source/ui/dlg/detailpages.hxx            |    4 +-
 8 files changed, 34 insertions(+), 34 deletions(-)

New commits:
commit d5220a535400440c657dc3000a7e078f17112861
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Fri Aug 2 10:19:16 2019 +0100
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Fri Aug 2 15:04:28 2019 +0200

    void* -> weld::Widget*
    
    Change-Id: I1341fa27fd184ff1302b867aea6c215c22fb477d
    Reviewed-on: https://gerrit.libreoffice.org/76847
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx b/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx
index dab449091e36..5bf0805206a0 100644
--- a/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx
+++ b/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx
@@ -218,7 +218,7 @@ using namespace ::com::sun::star;
         callModifiedHdl();
     }
 
-    void OLDAPConnectionPageSetup::callModifiedHdl(void *)
+    void OLDAPConnectionPageSetup::callModifiedHdl(weld::Widget*)
     {
         bool bRoadmapState = ((!m_xETHostServer->get_text().isEmpty() ) && ( !m_xETBaseDN->get_text().isEmpty() ) && (!m_xFTPortNumber->get_label().isEmpty() ));
         SetRoadmapStateValue(bRoadmapState);
@@ -344,7 +344,7 @@ using namespace ::com::sun::star;
         callModifiedHdl();
     }
 
-    void MySQLNativeSetupPage::callModifiedHdl(void*)
+    void MySQLNativeSetupPage::callModifiedHdl(weld::Widget*)
     {
         SetRoadmapStateValue( m_xMySQLSettings->canAdvance() );
 
@@ -512,7 +512,7 @@ using namespace ::com::sun::star;
         aMsg.run();
     }
 
-    void OGeneralSpecialJDBCConnectionPageSetup::callModifiedHdl(void* pControl)
+    void OGeneralSpecialJDBCConnectionPageSetup::callModifiedHdl(weld::Widget* pControl)
     {
         if (pControl == m_xETDriverClass.get())
             m_xPBTestJavaDriver->set_sensitive( !m_xETDriverClass->get_text().trim().isEmpty() );
diff --git a/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx b/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx
index 8cbe44c1297f..f5ae1a6fbaf8 100644
--- a/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx
+++ b/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx
@@ -80,7 +80,7 @@ namespace dbaui
         static VclPtr<OGenericAdministrationPage> CreateLDAPTabPage( TabPageParent pParent, const SfxItemSet& _rAttrSet );
         OLDAPConnectionPageSetup( TabPageParent pParent, const SfxItemSet& _rCoreAttrs );
         virtual ~OLDAPConnectionPageSetup() override;
-        virtual void callModifiedHdl(void* pControl = nullptr) override;
+        virtual void callModifiedHdl(weld::Widget* pControl = nullptr) override;
 
     protected:
         virtual void implInitControls(const SfxItemSet& _rSet, bool _bSaveValue) override;
@@ -121,7 +121,7 @@ namespace dbaui
         virtual bool FillItemSet( SfxItemSet* _rCoreAttrs ) override;
         virtual void implInitControls(const SfxItemSet& _rSet, bool _bSaveValue) override;
 
-        virtual void callModifiedHdl(void* pControl = nullptr) override;
+        virtual void callModifiedHdl(weld::Widget* pControl = nullptr) override;
     };
 
     // OGeneralSpecialJDBCConnectionPageSetup
@@ -144,7 +144,7 @@ namespace dbaui
         virtual void implInitControls(const SfxItemSet& _rSet, bool _bSaveValue) override;
         virtual void fillControls(std::vector< std::unique_ptr<ISaveValueWrapper> >& _rControlList) override;
         virtual void fillWindows(std::vector< std::unique_ptr<ISaveValueWrapper> >& _rControlList) override;
-        virtual void callModifiedHdl(void* pControl = nullptr) override;
+        virtual void callModifiedHdl(weld::Widget* pControl = nullptr) override;
 
         DECL_LINK(OnTestJavaClickHdl, weld::Button&, void);
 
diff --git a/dbaccess/source/ui/dlg/admincontrols.cxx b/dbaccess/source/ui/dlg/admincontrols.cxx
index 6f16870a3158..3af6b2a6eb2c 100644
--- a/dbaccess/source/ui/dlg/admincontrols.cxx
+++ b/dbaccess/source/ui/dlg/admincontrols.cxx
@@ -30,7 +30,7 @@ namespace dbaui
 {
 
     // MySQLNativeSettings
-    MySQLNativeSettings::MySQLNativeSettings(weld::Widget* pParent, const Link<void*,void>& rControlModificationLink)
+    MySQLNativeSettings::MySQLNativeSettings(weld::Widget* pParent, const Link<weld::Widget*,void>& rControlModificationLink)
         : m_xBuilder(Application::CreateBuilder(pParent, "dbaccess/ui/mysqlnativesettings.ui"))
         , m_xContainer(m_xBuilder->weld_widget("MysqlNativeSettings"))
         , m_xDatabaseNameLabel(m_xBuilder->weld_label("dbnamelabel"))
diff --git a/dbaccess/source/ui/dlg/admincontrols.hxx b/dbaccess/source/ui/dlg/admincontrols.hxx
index 5b675d77cc13..219f93f0e6dd 100644
--- a/dbaccess/source/ui/dlg/admincontrols.hxx
+++ b/dbaccess/source/ui/dlg/admincontrols.hxx
@@ -45,13 +45,13 @@ namespace dbaui
         std::unique_ptr<weld::Label> m_xDefaultPort;
         std::unique_ptr<weld::Entry> m_xSocket;
         std::unique_ptr<weld::Entry> m_xNamedPipe;
-        Link<void*,void> m_aControlModificationLink;
+        Link<weld::Widget*,void> m_aControlModificationLink;
         DECL_LINK(RadioToggleHdl, weld::ToggleButton&, void);
         DECL_LINK(SpinModifyHdl, weld::SpinButton&, void);
         DECL_LINK(EditModifyHdl, weld::Entry&, void);
 
     public:
-        MySQLNativeSettings(weld::Widget* pParent, const Link<void*,void>& rControlModificationLink);
+        MySQLNativeSettings(weld::Widget* pParent, const Link<weld::Widget*,void>& rControlModificationLink);
         void fillControls( std::vector< std::unique_ptr<ISaveValueWrapper> >& _rControlList );
         void fillWindows( std::vector< std::unique_ptr<ISaveValueWrapper> >& _rControlList );
 
diff --git a/dbaccess/source/ui/dlg/adminpages.cxx b/dbaccess/source/ui/dlg/adminpages.cxx
index f68abd8e262a..58464f36643c 100644
--- a/dbaccess/source/ui/dlg/adminpages.cxx
+++ b/dbaccess/source/ui/dlg/adminpages.cxx
@@ -114,7 +114,7 @@ namespace dbaui
         _rReadonly = !_rValid || (pReadonly && pReadonly->GetValue());
     }
 
-    IMPL_LINK(OGenericAdministrationPage, OnControlModified, void*, pCtrl, void)
+    IMPL_LINK(OGenericAdministrationPage, OnControlModified, weld::Widget*, pCtrl, void)
     {
         callModifiedHdl(pCtrl);
     }
diff --git a/dbaccess/source/ui/dlg/adminpages.hxx b/dbaccess/source/ui/dlg/adminpages.hxx
index 1b41fbc18040..1bd217274066 100644
--- a/dbaccess/source/ui/dlg/adminpages.hxx
+++ b/dbaccess/source/ui/dlg/adminpages.hxx
@@ -182,7 +182,7 @@ namespace dbaui
         virtual void    ActivatePage() override;
 
     protected:
-        virtual void callModifiedHdl(void* /*pControl*/ = nullptr) { m_aModifiedHandler.Call(this); }
+        virtual void callModifiedHdl(weld::Widget* /*pControl*/ = nullptr) { m_aModifiedHandler.Call(this); }
 
         /// called from within DeactivatePage. The page is allowed to be deactivated if this method returns sal_True
         virtual bool prepareLeave() { return true; }
@@ -256,7 +256,7 @@ namespace dbaui
         /** This link be used for controls where the tabpage does not need to take any special action when the control
             is modified. The implementation just calls callModifiedHdl.
         */
-        DECL_LINK(OnControlModified, void*, void);
+        DECL_LINK(OnControlModified, weld::Widget*, void);
         DECL_LINK(OnControlEntryModifyHdl, weld::Entry&, void);
         DECL_LINK(OnControlSpinButtonModifyHdl, weld::SpinButton&, void);
         DECL_LINK(OnControlModifiedButtonClick, weld::ToggleButton&, void);
diff --git a/dbaccess/source/ui/dlg/detailpages.cxx b/dbaccess/source/ui/dlg/detailpages.cxx
index aab7e8d8d80f..b8453c87f6bf 100644
--- a/dbaccess/source/ui/dlg/detailpages.cxx
+++ b/dbaccess/source/ui/dlg/detailpages.cxx
@@ -489,7 +489,7 @@ namespace dbaui
         aMsg.run();
     }
 
-    void OGeneralSpecialJDBCDetailsPage::callModifiedHdl(void* pControl)
+    void OGeneralSpecialJDBCDetailsPage::callModifiedHdl(weld::Widget* pControl)
     {
         if (m_bUseClass && pControl == m_xEDDriverClass.get())
             m_xTestJavaDriver->set_sensitive(!m_xEDDriverClass->get_text().trim().isEmpty());
diff --git a/dbaccess/source/ui/dlg/detailpages.hxx b/dbaccess/source/ui/dlg/detailpages.hxx
index 2e895d1fb412..af535194ee20 100644
--- a/dbaccess/source/ui/dlg/detailpages.hxx
+++ b/dbaccess/source/ui/dlg/detailpages.hxx
@@ -172,7 +172,7 @@ namespace dbaui
 
         virtual bool FillItemSet( SfxItemSet* _rCoreAttrs ) override;
         virtual void implInitControls(const SfxItemSet& _rSet, bool _bSaveValue) override;
-        virtual void callModifiedHdl(void* pControl = nullptr) override;
+        virtual void callModifiedHdl(weld::Widget* pControl = nullptr) override;
 
         DECL_LINK(OnTestJavaClickHdl, weld::Button&, void);
 
commit cad0716b35da8920e9270db121add091f7cd1b3e
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Fri Aug 2 10:13:58 2019 +0100
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Fri Aug 2 15:04:12 2019 +0200

    rename DBMySQLNativeSettings back to MySQLNativeSettings
    
    Change-Id: I00d6de729a1d650d479663b6e1d05f8087e7fe9a
    Reviewed-on: https://gerrit.libreoffice.org/76846
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx b/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx
index 2287be7a8934..dab449091e36 100644
--- a/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx
+++ b/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx
@@ -298,7 +298,7 @@ using namespace ::com::sun::star;
         : OGenericAdministrationPage(pParent, "dbaccess/ui/dbwizmysqlnativepage.ui", "DBWizMysqlNativePage", rCoreAttrs)
         , m_xHelpText(m_xBuilder->weld_label("helptext"))
         , m_xSettingsContainer(m_xBuilder->weld_container("MySQLSettingsContainer"))
-        , m_xMySQLSettings(new DBMySQLNativeSettings(m_xSettingsContainer.get(), LINK(this, OGenericAdministrationPage, OnControlModified)))
+        , m_xMySQLSettings(new MySQLNativeSettings(m_xSettingsContainer.get(), LINK(this, OGenericAdministrationPage, OnControlModified)))
     {
         SetRoadmapStateValue(false);
     }
diff --git a/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx b/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx
index dd0717f47a54..8cbe44c1297f 100644
--- a/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx
+++ b/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx
@@ -105,7 +105,7 @@ namespace dbaui
     private:
         std::unique_ptr<weld::Label> m_xHelpText;
         std::unique_ptr<weld::Container> m_xSettingsContainer;
-        std::unique_ptr<DBMySQLNativeSettings> m_xMySQLSettings;
+        std::unique_ptr<MySQLNativeSettings> m_xMySQLSettings;
 
     public:
         MySQLNativeSetupPage(TabPageParent pParent, const SfxItemSet& rCoreAttrs);
diff --git a/dbaccess/source/ui/dlg/admincontrols.cxx b/dbaccess/source/ui/dlg/admincontrols.cxx
index 33bd77cb27c4..6f16870a3158 100644
--- a/dbaccess/source/ui/dlg/admincontrols.cxx
+++ b/dbaccess/source/ui/dlg/admincontrols.cxx
@@ -30,7 +30,7 @@ namespace dbaui
 {
 
     // MySQLNativeSettings
-    DBMySQLNativeSettings::DBMySQLNativeSettings(weld::Widget* pParent, const Link<void*,void>& rControlModificationLink)
+    MySQLNativeSettings::MySQLNativeSettings(weld::Widget* pParent, const Link<void*,void>& rControlModificationLink)
         : m_xBuilder(Application::CreateBuilder(pParent, "dbaccess/ui/mysqlnativesettings.ui"))
         , m_xContainer(m_xBuilder->weld_widget("MysqlNativeSettings"))
         , m_xDatabaseNameLabel(m_xBuilder->weld_label("dbnamelabel"))
@@ -47,14 +47,14 @@ namespace dbaui
         , m_xNamedPipe(m_xBuilder->weld_entry("namedpipe"))
         , m_aControlModificationLink(rControlModificationLink)
     {
-        m_xDatabaseName->connect_changed( LINK(this, DBMySQLNativeSettings, EditModifyHdl) );
-        m_xHostName->connect_changed( LINK(this, DBMySQLNativeSettings, EditModifyHdl) );
-        m_xPort->connect_value_changed( LINK(this, DBMySQLNativeSettings, SpinModifyHdl) );
-        m_xSocket->connect_changed( LINK(this, DBMySQLNativeSettings, EditModifyHdl) );
-        m_xNamedPipe->connect_changed( LINK(this, DBMySQLNativeSettings, EditModifyHdl) );
-        m_xSocketRadio->connect_toggled( LINK(this, DBMySQLNativeSettings, RadioToggleHdl) );
-        m_xNamedPipeRadio->connect_toggled( LINK(this, DBMySQLNativeSettings, RadioToggleHdl) );
-        m_xHostPortRadio->connect_toggled( LINK(this, DBMySQLNativeSettings, RadioToggleHdl) );
+        m_xDatabaseName->connect_changed( LINK(this, MySQLNativeSettings, EditModifyHdl) );
+        m_xHostName->connect_changed( LINK(this, MySQLNativeSettings, EditModifyHdl) );
+        m_xPort->connect_value_changed( LINK(this, MySQLNativeSettings, SpinModifyHdl) );
+        m_xSocket->connect_changed( LINK(this, MySQLNativeSettings, EditModifyHdl) );
+        m_xNamedPipe->connect_changed( LINK(this, MySQLNativeSettings, EditModifyHdl) );
+        m_xSocketRadio->connect_toggled( LINK(this, MySQLNativeSettings, RadioToggleHdl) );
+        m_xNamedPipeRadio->connect_toggled( LINK(this, MySQLNativeSettings, RadioToggleHdl) );
+        m_xHostPortRadio->connect_toggled( LINK(this, MySQLNativeSettings, RadioToggleHdl) );
 
         // sockets are available on Unix systems only, named pipes only on Windows
 #ifdef UNX
@@ -67,7 +67,7 @@ namespace dbaui
         m_xContainer->show();
     }
 
-    IMPL_LINK(DBMySQLNativeSettings, RadioToggleHdl, weld::ToggleButton&, rRadioButton, void)
+    IMPL_LINK(MySQLNativeSettings, RadioToggleHdl, weld::ToggleButton&, rRadioButton, void)
     {
         m_aControlModificationLink.Call(&rRadioButton);
 
@@ -82,17 +82,17 @@ namespace dbaui
         m_xNamedPipe->set_sensitive(m_xNamedPipeRadio->get_active());
     }
 
-    IMPL_LINK(DBMySQLNativeSettings, EditModifyHdl, weld::Entry&, rEdit, void)
+    IMPL_LINK(MySQLNativeSettings, EditModifyHdl, weld::Entry&, rEdit, void)
     {
         m_aControlModificationLink.Call(&rEdit);
     }
 
-    IMPL_LINK(DBMySQLNativeSettings, SpinModifyHdl, weld::SpinButton&, rEdit, void)
+    IMPL_LINK(MySQLNativeSettings, SpinModifyHdl, weld::SpinButton&, rEdit, void)
     {
         m_aControlModificationLink.Call(&rEdit);
     }
 
-    void DBMySQLNativeSettings::fillControls( std::vector< std::unique_ptr<ISaveValueWrapper> >& _rControlList )
+    void MySQLNativeSettings::fillControls( std::vector< std::unique_ptr<ISaveValueWrapper> >& _rControlList )
     {
         _rControlList.emplace_back(new OSaveValueWidgetWrapper<weld::Entry>(m_xDatabaseName.get()));
         _rControlList.emplace_back(new OSaveValueWidgetWrapper<weld::Entry>(m_xHostName.get()));
@@ -101,7 +101,7 @@ namespace dbaui
         _rControlList.emplace_back(new OSaveValueWidgetWrapper<weld::Entry>(m_xNamedPipe.get()));
     }
 
-    void DBMySQLNativeSettings::fillWindows( std::vector< std::unique_ptr<ISaveValueWrapper> >& _rControlList )
+    void MySQLNativeSettings::fillWindows( std::vector< std::unique_ptr<ISaveValueWrapper> >& _rControlList )
     {
         _rControlList.emplace_back( new ODisableWidgetWrapper<weld::Label>( m_xDatabaseNameLabel.get() ) );
         _rControlList.emplace_back( new ODisableWidgetWrapper<weld::Label>( m_xHostNameLabel.get() ) );
@@ -111,7 +111,7 @@ namespace dbaui
         _rControlList.emplace_back( new ODisableWidgetWrapper<weld::RadioButton>( m_xNamedPipeRadio.get() ) );
     }
 
-    bool DBMySQLNativeSettings::FillItemSet( SfxItemSet* _rSet )
+    bool MySQLNativeSettings::FillItemSet( SfxItemSet* _rSet )
     {
         bool bChangedSomething = false;
 
@@ -127,7 +127,7 @@ namespace dbaui
         return bChangedSomething;
     }
 
-    void DBMySQLNativeSettings::implInitControls(const SfxItemSet& _rSet )
+    void MySQLNativeSettings::implInitControls(const SfxItemSet& _rSet )
     {
         const SfxBoolItem* pInvalid = _rSet.GetItem<SfxBoolItem>(DSID_INVALID_SELECTION);
         bool bValid = !pInvalid || !pInvalid->GetValue();
@@ -171,7 +171,7 @@ namespace dbaui
             m_xHostPortRadio->set_active(true);
     }
 
-    bool DBMySQLNativeSettings::canAdvance() const
+    bool MySQLNativeSettings::canAdvance() const
     {
         if (m_xDatabaseName->get_text().isEmpty())
             return false;
diff --git a/dbaccess/source/ui/dlg/admincontrols.hxx b/dbaccess/source/ui/dlg/admincontrols.hxx
index 0c406498e5dc..5b675d77cc13 100644
--- a/dbaccess/source/ui/dlg/admincontrols.hxx
+++ b/dbaccess/source/ui/dlg/admincontrols.hxx
@@ -28,7 +28,7 @@ namespace dbaui
 {
 
     // MySQLNativeSettings
-    class DBMySQLNativeSettings
+    class MySQLNativeSettings
     {
     private:
         std::unique_ptr<weld::Builder> m_xBuilder;
@@ -51,7 +51,7 @@ namespace dbaui
         DECL_LINK(EditModifyHdl, weld::Entry&, void);
 
     public:
-        DBMySQLNativeSettings(weld::Widget* pParent, const Link<void*,void>& rControlModificationLink);
+        MySQLNativeSettings(weld::Widget* pParent, const Link<void*,void>& rControlModificationLink);
         void fillControls( std::vector< std::unique_ptr<ISaveValueWrapper> >& _rControlList );
         void fillWindows( std::vector< std::unique_ptr<ISaveValueWrapper> >& _rControlList );
 
diff --git a/dbaccess/source/ui/dlg/detailpages.hxx b/dbaccess/source/ui/dlg/detailpages.hxx
index 8de9f2f3e757..2e895d1fb412 100644
--- a/dbaccess/source/ui/dlg/detailpages.hxx
+++ b/dbaccess/source/ui/dlg/detailpages.hxx
@@ -198,7 +198,7 @@ namespace dbaui
 
     private:
         std::unique_ptr<weld::Widget> m_xMySQLSettingsContainer;
-        DBMySQLNativeSettings m_aMySQLSettings;
+        MySQLNativeSettings m_aMySQLSettings;
         std::unique_ptr<weld::Label> m_xSeparator1;
         std::unique_ptr<weld::Label> m_xSeparator2;
         std::unique_ptr<weld::Label> m_xUserNameLabel;


More information about the Libreoffice-commits mailing list