summaryrefslogtreecommitdiff
path: root/dbaccess
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-09-09 11:41:20 +0200
committerNoel Grandin <noel@peralex.com>2015-09-10 11:38:30 +0200
commitf4e951a61a20edd6efbd244966e851aa378e66ad (patch)
treef4879e437b88432069001e7e3dadd2649cd33a14 /dbaccess
parent823150ff153a6e02781b1b2b09ea6eb528111d2e (diff)
convert Link<> to typed
Change-Id: I603463d0486d4d0f21ebbdc6eca900db58bb090f
Diffstat (limited to 'dbaccess')
-rw-r--r--dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx3
-rw-r--r--dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx2
-rw-r--r--dbaccess/source/ui/dlg/TextConnectionHelper.cxx3
-rw-r--r--dbaccess/source/ui/dlg/TextConnectionHelper.hxx2
-rw-r--r--dbaccess/source/ui/dlg/admincontrols.cxx12
-rw-r--r--dbaccess/source/ui/dlg/admincontrols.hxx3
6 files changed, 15 insertions, 10 deletions
diff --git a/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx b/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx
index 54ae2b4e6138..b8e744cbb373 100644
--- a/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx
+++ b/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx
@@ -271,10 +271,9 @@ using namespace ::com::sun::star;
OGenericAdministrationPage::dispose();
}
- IMPL_LINK(OMySQLIntroPageSetup, OnSetupModeSelected, RadioButton*, /*_pBox*/)
+ IMPL_LINK_NOARG_TYPED(OMySQLIntroPageSetup, OnSetupModeSelected, RadioButton&, void)
{
maClickHdl.Call( this );
- return long(true);
}
void OMySQLIntroPageSetup::implInitControls(const SfxItemSet& _rSet, bool /*_bSaveValue*/)
diff --git a/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx b/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx
index 2bdaef0aa384..4237fabec45f 100644
--- a/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx
+++ b/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx
@@ -232,7 +232,7 @@ namespace dbaui
VclPtr<RadioButton> m_pNATIVEDatabase;
Link<OMySQLIntroPageSetup *, void> maClickHdl;
- DECL_LINK(OnSetupModeSelected, RadioButton*);
+ DECL_LINK_TYPED(OnSetupModeSelected, RadioButton&, void);
};
diff --git a/dbaccess/source/ui/dlg/TextConnectionHelper.cxx b/dbaccess/source/ui/dlg/TextConnectionHelper.cxx
index a6b307dbed7e..8139d8805b83 100644
--- a/dbaccess/source/ui/dlg/TextConnectionHelper.cxx
+++ b/dbaccess/source/ui/dlg/TextConnectionHelper.cxx
@@ -192,13 +192,12 @@ namespace dbaui
return 0L;
}
- IMPL_LINK(OTextConnectionHelper, OnSetExtensionHdl, RadioButton*, /*_pRadioButton*/)
+ IMPL_LINK_NOARG_TYPED(OTextConnectionHelper, OnSetExtensionHdl, RadioButton&, void)
{
bool bDoEnable = m_pAccessOtherFiles->IsChecked();
m_pOwnExtension->Enable(bDoEnable);
m_pExtensionExample->Enable(bDoEnable);
m_aGetExtensionHandler.Call(this);
- return 0L;
}
void OTextConnectionHelper::fillControls(::std::vector< ISaveValueWrapper* >& _rControlList)
diff --git a/dbaccess/source/ui/dlg/TextConnectionHelper.hxx b/dbaccess/source/ui/dlg/TextConnectionHelper.hxx
index 135e4dc53102..6a2f1d90f8fb 100644
--- a/dbaccess/source/ui/dlg/TextConnectionHelper.hxx
+++ b/dbaccess/source/ui/dlg/TextConnectionHelper.hxx
@@ -82,7 +82,7 @@ namespace dbaui
protected:
void callModifiedHdl() const { if (m_aModifiedHandler.IsSet()) m_aModifiedHandler.Call(const_cast<OTextConnectionHelper *>(this)); }
Link<> getControlModifiedLink() { return LINK(this, OTextConnectionHelper, OnControlModified); }
- DECL_LINK(OnSetExtensionHdl,RadioButton*);
+ DECL_LINK_TYPED(OnSetExtensionHdl,RadioButton&,void);
DECL_LINK(OnControlModified,Control*);
DECL_LINK(OnEditModified,Edit*);
diff --git a/dbaccess/source/ui/dlg/admincontrols.cxx b/dbaccess/source/ui/dlg/admincontrols.cxx
index da655cad39cc..39db714b11c9 100644
--- a/dbaccess/source/ui/dlg/admincontrols.cxx
+++ b/dbaccess/source/ui/dlg/admincontrols.cxx
@@ -126,7 +126,8 @@ namespace dbaui
// MySQLNativeSettings
MySQLNativeSettings::MySQLNativeSettings( vcl::Window& _rParent, const Link<>& _rControlModificationLink )
- :TabPage( &_rParent, "MysqlNativeSettings", "dbaccess/ui/mysqlnativesettings.ui" )
+ :TabPage( &_rParent, "MysqlNativeSettings", "dbaccess/ui/mysqlnativesettings.ui" ),
+ m_aControlModificationLink(_rControlModificationLink)
{
get(m_pDatabaseNameLabel, "dbnamelabel");
get(m_pDatabaseName, "dbname");
@@ -147,8 +148,8 @@ namespace dbaui
m_pPort->SetModifyHdl( _rControlModificationLink );
m_pSocket->SetModifyHdl( _rControlModificationLink );
m_pNamedPipe->SetModifyHdl( _rControlModificationLink );
- m_pSocketRadio->SetToggleHdl( _rControlModificationLink );
- m_pNamedPipeRadio->SetToggleHdl( _rControlModificationLink );
+ m_pSocketRadio->SetToggleHdl( LINK(this, MySQLNativeSettings, RadioToggleHdl) );
+ m_pNamedPipeRadio->SetToggleHdl( LINK(this, MySQLNativeSettings, RadioToggleHdl) );
m_aControlDependencies.enableOnRadioCheck( *m_pHostPortRadio, *m_pHostNameLabel, *m_pHostName, *m_pPortLabel, *m_pPort, *m_pDefaultPort );
m_aControlDependencies.enableOnRadioCheck( *m_pSocketRadio, *m_pSocket );
@@ -168,6 +169,11 @@ namespace dbaui
#endif
}
+ IMPL_LINK_TYPED(MySQLNativeSettings, RadioToggleHdl, RadioButton&, rRadioButton, void)
+ {
+ m_aControlModificationLink.Call(&rRadioButton);
+ }
+
MySQLNativeSettings::~MySQLNativeSettings()
{
disposeOnce();
diff --git a/dbaccess/source/ui/dlg/admincontrols.hxx b/dbaccess/source/ui/dlg/admincontrols.hxx
index c4e805cd6fc2..d1865751a3bf 100644
--- a/dbaccess/source/ui/dlg/admincontrols.hxx
+++ b/dbaccess/source/ui/dlg/admincontrols.hxx
@@ -47,9 +47,10 @@ namespace dbaui
VclPtr<FixedText> m_pDefaultPort;
VclPtr<Edit> m_pSocket;
VclPtr<Edit> m_pNamedPipe;
-
+ Link<> m_aControlModificationLink;
::svt::ControlDependencyManager
m_aControlDependencies;
+ DECL_LINK_TYPED(RadioToggleHdl, RadioButton&, void);
public:
MySQLNativeSettings( vcl::Window& _rParent, const Link<>& _rControlModificationLink );