summaryrefslogtreecommitdiff
path: root/reportdesign
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-09-17 12:56:50 +0200
committerNoel Grandin <noel@peralex.com>2015-09-17 14:41:58 +0200
commit363cf98b34f2a47d6b7659b680ae1c0e32f7b789 (patch)
tree7d09f0528448a2b1c3394f6d430bd3e8b2275539 /reportdesign
parent0110ce98b2ca5adab84e919328850869100479a9 (diff)
convert Link<> to typed
Change-Id: I2362e3cc4df53f95db405bcc2449f11bc1c16e89
Diffstat (limited to 'reportdesign')
-rw-r--r--reportdesign/source/ui/dlg/AddField.cxx4
-rw-r--r--reportdesign/source/ui/dlg/Formula.cxx8
-rw-r--r--reportdesign/source/ui/inc/AddField.hxx4
-rw-r--r--reportdesign/source/ui/inc/Formula.hxx2
-rw-r--r--reportdesign/source/ui/inc/ReportController.hxx2
-rw-r--r--reportdesign/source/ui/report/ReportController.cxx5
6 files changed, 11 insertions, 14 deletions
diff --git a/reportdesign/source/ui/dlg/AddField.cxx b/reportdesign/source/ui/dlg/AddField.cxx
index 521d574055f9..345665708544 100644
--- a/reportdesign/source/ui/dlg/AddField.cxx
+++ b/reportdesign/source/ui/dlg/AddField.cxx
@@ -267,7 +267,7 @@ bool OAddFieldWindow::PreNotify( NotifyEvent& _rNEvt )
{
if ( m_aCreateLink.IsSet() )
{
- m_aCreateLink.Call(this);
+ m_aCreateLink.Call(*this);
return true;
}
}
@@ -507,7 +507,7 @@ IMPL_LINK_NOARG_TYPED( OAddFieldWindow, OnClickHdl, Button*, void )
IMPL_LINK_NOARG_TYPED( OAddFieldWindow, OnDoubleClickHdl, SvTreeListBox*, bool )
{
if ( m_aCreateLink.IsSet() )
- m_aCreateLink.Call(this);
+ m_aCreateLink.Call(*this);
return false;
}
diff --git a/reportdesign/source/ui/dlg/Formula.cxx b/reportdesign/source/ui/dlg/Formula.cxx
index 6ee1da8aee58..55068a62077a 100644
--- a/reportdesign/source/ui/dlg/Formula.cxx
+++ b/reportdesign/source/ui/dlg/Formula.cxx
@@ -220,9 +220,9 @@ void FormulaDialog::ToggleCollapsed( RefEdit* _pEdit, RefButton* _pButton)
}
-IMPL_LINK( FormulaDialog, OnClickHdl, OAddFieldWindow* ,_pAddFieldDlg)
+IMPL_LINK_TYPED( FormulaDialog, OnClickHdl, OAddFieldWindow& ,_rAddFieldDlg, void)
{
- const uno::Sequence< beans::PropertyValue > aArgs = _pAddFieldDlg->getSelectedFieldDescriptors();
+ const uno::Sequence< beans::PropertyValue > aArgs = _rAddFieldDlg.getSelectedFieldDescriptors();
// we use this way to create undo actions
if ( m_pEdit && aArgs.getLength() == 1)
{
@@ -238,10 +238,8 @@ IMPL_LINK( FormulaDialog, OnClickHdl, OAddFieldWindow* ,_pAddFieldDlg)
}
}
m_pEdit = NULL;
- _pAddFieldDlg->Hide();
+ _rAddFieldDlg.Hide();
RefInputDoneAfter( true );
-
- return 0L;
}
uno::Reference< sheet::XFormulaParser> FormulaDialog::getFormulaParser() const
diff --git a/reportdesign/source/ui/inc/AddField.hxx b/reportdesign/source/ui/inc/AddField.hxx
index b9f3f03ca29f..77c296611c03 100644
--- a/reportdesign/source/ui/inc/AddField.hxx
+++ b/reportdesign/source/ui/inc/AddField.hxx
@@ -61,7 +61,7 @@ class OAddFieldWindow :public FloatingWindow
VclPtr<FixedText> m_aHelpText;
VclPtr<PushButton> m_aInsertButton;
- Link<> m_aCreateLink;
+ Link<OAddFieldWindow&,void> m_aCreateLink;
OUString m_aCommandName;
OUString m_sFilter;
sal_Int32 m_nCommandType;
@@ -89,7 +89,7 @@ public:
inline const OUString& GetCommand() const { return m_aCommandName; }
inline sal_Int32 GetCommandType() const { return m_nCommandType; }
inline bool GetEscapeProcessing() const { return m_bEscapeProcessing; }
- inline void SetCreateHdl(const Link<>& _aCreateLink) { m_aCreateLink = _aCreateLink; }
+ inline void SetCreateHdl(const Link<OAddFieldWindow&,void>& _aCreateLink) { m_aCreateLink = _aCreateLink; }
::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XConnection> getConnection() const;
diff --git a/reportdesign/source/ui/inc/Formula.hxx b/reportdesign/source/ui/inc/Formula.hxx
index 1a0245267e2e..bc70ba7b12de 100644
--- a/reportdesign/source/ui/inc/Formula.hxx
+++ b/reportdesign/source/ui/inc/Formula.hxx
@@ -58,7 +58,7 @@ class FormulaDialog : public formula::FormulaModalDialog,
svl::SharedStringPool& mrStringPool;
- DECL_LINK( OnClickHdl, OAddFieldWindow*);
+ DECL_LINK_TYPED( OnClickHdl, OAddFieldWindow&, void );
public:
FormulaDialog( vcl::Window* pParent
, const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory>& _xServiceFactory
diff --git a/reportdesign/source/ui/inc/ReportController.hxx b/reportdesign/source/ui/inc/ReportController.hxx
index 508bed217faa..ca891e6e02d3 100644
--- a/reportdesign/source/ui/inc/ReportController.hxx
+++ b/reportdesign/source/ui/inc/ReportController.hxx
@@ -335,7 +335,7 @@ namespace rptui
OReportController(::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > const & the_context);
DECL_LINK( EventLstHdl, VclWindowEvent* );
- DECL_LINK( OnCreateHdl, OAddFieldWindow*);
+ DECL_LINK_TYPED( OnCreateHdl, OAddFieldWindow&, void);
DECLARE_XINTERFACE( )
DECLARE_XTYPEPROVIDER( )
diff --git a/reportdesign/source/ui/report/ReportController.cxx b/reportdesign/source/ui/report/ReportController.cxx
index b72523f890d9..864b5da1e4a9 100644
--- a/reportdesign/source/ui/report/ReportController.cxx
+++ b/reportdesign/source/ui/report/ReportController.cxx
@@ -1751,16 +1751,15 @@ IMPL_LINK_NOARG_TYPED( OReportController, OnOpenHelpAgent, void*, void )
doOpenHelpAgent();
}
-IMPL_LINK( OReportController, OnCreateHdl, OAddFieldWindow* ,_pAddFieldDlg)
+IMPL_LINK_TYPED( OReportController, OnCreateHdl, OAddFieldWindow& ,_rAddFieldDlg, void)
{
WaitObject aObj( getDesignView() );
- uno::Sequence< beans::PropertyValue > aArgs = _pAddFieldDlg->getSelectedFieldDescriptors();
+ uno::Sequence< beans::PropertyValue > aArgs = _rAddFieldDlg.getSelectedFieldDescriptors();
// we use this way to create undo actions
if ( aArgs.getLength() )
{
executeChecked(SID_ADD_CONTROL_PAIR,aArgs);
}
- return 0L;
}