From 59418d8eac185a54a181c1300e8dca66170def4d Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Fri, 16 Oct 2015 15:09:47 +0200 Subject: convert Link<> to typed Change-Id: I66ad4562f33b68172557d759a26b9e19d19e2c0e --- extensions/source/propctrlr/commoncontrol.cxx | 3 +-- extensions/source/propctrlr/commoncontrol.hxx | 3 +-- extensions/source/propctrlr/standardcontrol.hxx | 6 +++--- extensions/source/propctrlr/usercontrol.cxx | 2 +- 4 files changed, 6 insertions(+), 8 deletions(-) (limited to 'extensions') diff --git a/extensions/source/propctrlr/commoncontrol.cxx b/extensions/source/propctrlr/commoncontrol.cxx index c591761f5802..8ace458122d8 100644 --- a/extensions/source/propctrlr/commoncontrol.cxx +++ b/extensions/source/propctrlr/commoncontrol.cxx @@ -100,10 +100,9 @@ namespace pcr setModified(); } - IMPL_LINK_NOARG( CommonBehaviourControlHelper, ModifiedHdl ) + IMPL_LINK_NOARG_TYPED( CommonBehaviourControlHelper, ModifiedHdl, ListBox&, void ) { setModified(); - return 0; } IMPL_LINK_NOARG_TYPED( CommonBehaviourControlHelper, GetFocusHdl, Control&, void ) diff --git a/extensions/source/propctrlr/commoncontrol.hxx b/extensions/source/propctrlr/commoncontrol.hxx index fc39aec21412..5fe2e994074a 100644 --- a/extensions/source/propctrlr/commoncontrol.hxx +++ b/extensions/source/propctrlr/commoncontrol.hxx @@ -89,9 +89,8 @@ namespace pcr virtual vcl::Window* getVclWindow() = 0; /// may be used by derived classes, they forward the event to the PropCtrListener - DECL_LINK( ModifiedHdl, void* ); + DECL_LINK_TYPED( ModifiedHdl, ListBox&, void ); DECL_LINK_TYPED( EditModifiedHdl, Edit&, void ); - DECL_LINK_TYPED( SelectHdl, ListBox&, void ); DECL_LINK_TYPED( GetFocusHdl, Control&, void ); DECL_LINK_TYPED( LoseFocusHdl, Control&, void ); }; diff --git a/extensions/source/propctrlr/standardcontrol.hxx b/extensions/source/propctrlr/standardcontrol.hxx index c46659754099..f5422f0f8eed 100644 --- a/extensions/source/propctrlr/standardcontrol.hxx +++ b/extensions/source/propctrlr/standardcontrol.hxx @@ -61,10 +61,10 @@ namespace pcr TListboxWindow::SetSelectHdl( LINK(this, ListLikeControlWithModifyHandler, OnSelect) ); } - void SetModifyHdl( const Link<>& _rLink ) { aModifyHdl = _rLink;; } + void SetModifyHdl( const Link& _rLink ) { aModifyHdl = _rLink;; } private: DECL_LINK_TYPED(OnSelect, ListBox&, void); - Link<> aModifyHdl; + Link aModifyHdl; }; template< class LISTBOX_WINDOW > @@ -74,7 +74,7 @@ namespace pcr template< class LISTBOX_WINDOW > void ListLikeControlWithModifyHandler< LISTBOX_WINDOW >::OnSelect(ListBox& rListBox) { - aModifyHdl.Call(&rListBox); + aModifyHdl.Call(rListBox); } //= OTimeControl diff --git a/extensions/source/propctrlr/usercontrol.cxx b/extensions/source/propctrlr/usercontrol.cxx index a11962a2a53a..ed0dd6d049ce 100644 --- a/extensions/source/propctrlr/usercontrol.cxx +++ b/extensions/source/propctrlr/usercontrol.cxx @@ -56,7 +56,7 @@ namespace pcr { SetText( "" ); if ( m_pHelper ) - m_pHelper->ModifiedHdl( this ); + m_pHelper->setModified(); return true; } } -- cgit