From 0535f42e5f09f56c9c101550f7cfedb40c761879 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Thu, 17 Sep 2015 09:06:13 +0200 Subject: convert Link<> to typed Change-Id: Ic3ce7783614d90a34f9c4414bbc7df9774091805 --- forms/source/component/ImageControl.cxx | 3 +-- forms/source/component/ImageControl.hxx | 2 +- forms/source/component/clickableimage.cxx | 3 +-- forms/source/component/clickableimage.hxx | 2 +- forms/source/component/imgprod.hxx | 10 +++++----- 5 files changed, 9 insertions(+), 11 deletions(-) (limited to 'forms') diff --git a/forms/source/component/ImageControl.cxx b/forms/source/component/ImageControl.cxx index cb24bb3e30e4..1ea2a33e7dcb 100644 --- a/forms/source/component/ImageControl.cxx +++ b/forms/source/component/ImageControl.cxx @@ -665,7 +665,7 @@ void SAL_CALL OImageControlModel::startProduction( ) throw (RuntimeException, s } -IMPL_LINK( OImageControlModel, OnImageImportDone, ::Graphic*, i_pGraphic ) +IMPL_LINK_TYPED( OImageControlModel, OnImageImportDone, ::Graphic*, i_pGraphic, void ) { const Reference< XGraphic > xGraphic( i_pGraphic != NULL ? Image( i_pGraphic->GetBitmapEx() ).GetXGraphic() : NULL ); m_bExternalGraphic = false; @@ -678,7 +678,6 @@ IMPL_LINK( OImageControlModel, OnImageImportDone, ::Graphic*, i_pGraphic ) DBG_UNHANDLED_EXCEPTION(); } m_bExternalGraphic = true; - return 1L; } diff --git a/forms/source/component/ImageControl.hxx b/forms/source/component/ImageControl.hxx index cb0b05ec2b2f..bfe2ddd3eff8 100644 --- a/forms/source/component/ImageControl.hxx +++ b/forms/source/component/ImageControl.hxx @@ -142,7 +142,7 @@ protected: */ bool impl_updateStreamForURL_lck( const OUString& _rURL, ValueChangeInstigator _eInstigator ); - DECL_LINK( OnImageImportDone, ::Graphic* ); + DECL_LINK_TYPED( OnImageImportDone, ::Graphic*, void ); }; typedef ::cppu::ImplHelper2 < ::com::sun::star::awt::XMouseListener diff --git a/forms/source/component/clickableimage.cxx b/forms/source/component/clickableimage.cxx index e0f8050371e7..5e05c52e1cb4 100644 --- a/forms/source/component/clickableimage.cxx +++ b/forms/source/component/clickableimage.cxx @@ -856,7 +856,7 @@ namespace frm } } - IMPL_LINK( OClickableImageBaseModel, OnImageImportDone, Graphic*, i_pGraphic ) + IMPL_LINK_TYPED( OClickableImageBaseModel, OnImageImportDone, Graphic*, i_pGraphic, void ) { const Reference< XGraphic > xGraphic( i_pGraphic != NULL ? Graphic(i_pGraphic->GetBitmapEx()).GetXGraphic() : NULL ); if ( !xGraphic.is() ) @@ -868,7 +868,6 @@ namespace frm m_xGraphicObject = css::graphic::GraphicObject::create( m_xContext ); m_xGraphicObject->setGraphic( xGraphic ); } - return 1L; } diff --git a/forms/source/component/clickableimage.hxx b/forms/source/component/clickableimage.hxx index 30df1ce2a9c5..4732cda47197 100644 --- a/forms/source/component/clickableimage.hxx +++ b/forms/source/component/clickableimage.hxx @@ -153,7 +153,7 @@ namespace frm // to be called from within the cloning-ctor of your derived class void implInitializeImageURL( ); - DECL_LINK( OnImageImportDone, ::Graphic* ); + DECL_LINK_TYPED( OnImageImportDone, ::Graphic*, void ); }; class ImageModelMethodGuard : public ::osl::MutexGuard diff --git a/forms/source/component/imgprod.hxx b/forms/source/component/imgprod.hxx index ce8ce14a0fa6..5dcafedf46c4 100644 --- a/forms/source/component/imgprod.hxx +++ b/forms/source/component/imgprod.hxx @@ -52,15 +52,15 @@ private: typedef boost::ptr_vector< ::com::sun::star::uno::Reference< ::com::sun::star::awt::XImageConsumer > > ConsumerList_t; - OUString maURL; + OUString maURL; ConsumerList_t maConsList; Graphic* mpGraphic; SvStream* mpStm; sal_uInt32 mnTransIndex; - bool mbConsInit; - Link<> maDoneHdl; + bool mbConsInit; + Link maDoneHdl; - bool ImplImportGraphic( Graphic& rGraphic ); + bool ImplImportGraphic( Graphic& rGraphic ); void ImplUpdateData( const Graphic& rGraphic ); void ImplInitConsumer( const Graphic& rGraphic ); void ImplUpdateConsumer( const Graphic& rGraphic ); @@ -75,7 +75,7 @@ public: void NewDataAvailable(); - void SetDoneHdl( const Link<>& i_rHdl ) { maDoneHdl = i_rHdl; } + void SetDoneHdl( const Link& i_rHdl ) { maDoneHdl = i_rHdl; } // ::com::sun::star::uno::XInterface ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; -- cgit