From 8578168b6aa6ccd3d0fad494300766fce4b26dbc Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Thu, 17 Sep 2015 16:47:56 +0200 Subject: convert Link<> to typed Change-Id: I2e49e9b18db6ee6ce0dcaea0a83e862384d5beaa --- sw/inc/crsrsh.hxx | 6 +++--- sw/inc/view.hxx | 3 ++- sw/source/uibase/dochdl/swdtflvr.cxx | 4 ++-- sw/source/uibase/uiview/view.cxx | 4 +--- 4 files changed, 8 insertions(+), 9 deletions(-) diff --git a/sw/inc/crsrsh.hxx b/sw/inc/crsrsh.hxx index 2d68c835760c..cf6d81805011 100644 --- a/sw/inc/crsrsh.hxx +++ b/sw/inc/crsrsh.hxx @@ -168,7 +168,7 @@ private: Link m_aFlyMacroLnk; /**< Link will be called, if the Crsr is set into a fly. A macro can then be called */ - Link<> m_aChgLnk; /**< link will be called by every attribute/ + Link m_aChgLnk; /**< link will be called by every attribute/ format changes at cursor position.*/ Link<> m_aGrfArrivedLnk; ///< Link calls to UI if a graphic is arrived @@ -485,8 +485,8 @@ public: const Link& GetFlyMacroLnk() const { return m_aFlyMacroLnk; } // Methods returning/altering link for changes of attributes/formates. - void SetChgLnk( const Link<> &rLnk ) { m_aChgLnk = rLnk; } - const Link<>& GetChgLnk() const { return m_aChgLnk; } + void SetChgLnk( const Link &rLnk ) { m_aChgLnk = rLnk; } + const Link& GetChgLnk() const { return m_aChgLnk; } // Methods returning/altering ling for "graphic completely loaded". void SetGrfArrivedLnk( const Link<> &rLnk ) { m_aGrfArrivedLnk = rLnk; } diff --git a/sw/inc/view.hxx b/sw/inc/view.hxx index 5fb0f345a1bc..a7185916cf55 100644 --- a/sw/inc/view.hxx +++ b/sw/inc/view.hxx @@ -78,6 +78,7 @@ class Graphic; class GraphicFilter; class SwPostItMgr; enum class SotExchangeDest; +class SwCrsrShell; namespace com{ namespace sun { namespace star { namespace view{ class XSelectionSupplier; } @@ -541,7 +542,7 @@ public: void StateTabWin(SfxItemSet&); // attributes have changed - DECL_LINK( AttrChangedNotify, void* ); + DECL_LINK_TYPED( AttrChangedNotify, SwCrsrShell*, void ); // form control has been activated DECL_LINK_TYPED( FormControlActivated, LinkParamNone*, void ); diff --git a/sw/source/uibase/dochdl/swdtflvr.cxx b/sw/source/uibase/dochdl/swdtflvr.cxx index 21e2c6a6d59d..21aa11fdbb70 100644 --- a/sw/source/uibase/dochdl/swdtflvr.cxx +++ b/sw/source/uibase/dochdl/swdtflvr.cxx @@ -1693,8 +1693,8 @@ bool SwTransferable::_PasteFileContent( TransferableDataHelper& rData, if( pStream && pRead ) { - Link<> aOldLink( rSh.GetChgLnk() ); - rSh.SetChgLnk( Link<>() ); + Link aOldLink( rSh.GetChgLnk() ); + rSh.SetChgLnk( Link() ); const SwPosition& rInsPos = *rSh.GetCrsr()->Start(); SwReader aReader( *pStream, aEmptyOUStr, OUString(), *rSh.GetCrsr() ); diff --git a/sw/source/uibase/uiview/view.cxx b/sw/source/uibase/uiview/view.cxx index 812f188000f5..717212f525bf 100644 --- a/sw/source/uibase/uiview/view.cxx +++ b/sw/source/uibase/uiview/view.cxx @@ -464,7 +464,7 @@ extern "C" } } -IMPL_LINK_NOARG(SwView, AttrChangedNotify) +IMPL_LINK_NOARG_TYPED(SwView, AttrChangedNotify, SwCrsrShell*, void) { if ( GetEditWin().IsChainMode() ) GetEditWin().SetChainMode( false ); @@ -508,8 +508,6 @@ IMPL_LINK_NOARG(SwView, AttrChangedNotify) // actual cursor position is a post-it field m_pPostItMgr->SetShadowState( m_pWrtShell->GetPostItFieldAtCursor() ); } - - return 0; } IMPL_LINK_NOARG_TYPED(SwView, TimeoutHdl, Timer *, void) -- cgit