diff options
author | Noel Grandin <noel@peralex.com> | 2015-08-13 09:33:14 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2015-08-13 10:49:57 +0200 |
commit | 200e336d1d5c036b5ecd308d93e4131274b1efb8 (patch) | |
tree | cd81d3e0a7e0d68a9ebcd90c346594aab8a89fc8 /include | |
parent | 63e1890675ecaaf50d855a1daf85fc41798bb898 (diff) |
make Link<> instances typed
Change-Id: I7d20875cc498d54140cfe75b21373fdab9c369ce
Diffstat (limited to 'include')
-rw-r--r-- | include/sfx2/app.hxx | 10 | ||||
-rw-r--r-- | include/sfx2/templateabstractview.hxx | 6 | ||||
-rw-r--r-- | include/sfx2/templatedlg.hxx | 2 |
3 files changed, 10 insertions, 8 deletions
diff --git a/include/sfx2/app.hxx b/include/sfx2/app.hxx index 77e626734149..01238307b5e4 100644 --- a/include/sfx2/app.hxx +++ b/include/sfx2/app.hxx @@ -93,15 +93,17 @@ namespace sfx2 class SfxLinkItem : public SfxPoolItem { - Link<> aLink; + Link<SfxPoolItem*, void> aLink; public: + SfxLinkItem( sal_uInt16 nWhichId, const Link<SfxPoolItem*, void>& rValue ) : SfxPoolItem( nWhichId ) + { aLink = rValue; } + virtual SfxPoolItem* Clone( SfxItemPool* = 0 ) const SAL_OVERRIDE { return new SfxLinkItem( *this ); } virtual bool operator==( const SfxPoolItem& rL) const SAL_OVERRIDE { return static_cast<const SfxLinkItem&>(rL).aLink == aLink; } - SfxLinkItem( sal_uInt16 nWhichId, const Link<>& rValue ) : SfxPoolItem( nWhichId ) - { aLink = rValue; } - const Link<>& GetValue() const { return aLink; } + const Link<SfxPoolItem*, void>& + GetValue() const { return aLink; } }; #ifndef SFX_DECL_OBJECTSHELL_DEFINED diff --git a/include/sfx2/templateabstractview.hxx b/include/sfx2/templateabstractview.hxx index c6aa1e129998..026868b6faf9 100644 --- a/include/sfx2/templateabstractview.hxx +++ b/include/sfx2/templateabstractview.hxx @@ -117,7 +117,7 @@ public: void setOpenRegionHdl(const Link<void*,void> &rLink); - void setOpenTemplateHdl (const Link<> &rLink); + void setOpenTemplateHdl(const Link<ThumbnailViewItem*,void> &rLink); static BitmapEx scaleImg (const BitmapEx &rImg, long width, long height); @@ -141,8 +141,8 @@ protected: VclPtr<PushButton> maAllButton; VclPtr<FixedText> maFTName; - Link<void*,void> maOpenRegionHdl; - Link<> maOpenTemplateHdl; + Link<void*,void> maOpenRegionHdl; + Link<ThumbnailViewItem*,void> maOpenTemplateHdl; }; #endif // INCLUDED_SFX2_TEMPLATEABSTRACTVIEW_HXX diff --git a/include/sfx2/templatedlg.hxx b/include/sfx2/templatedlg.hxx index 64323fb9c551..2b0426e47e34 100644 --- a/include/sfx2/templatedlg.hxx +++ b/include/sfx2/templatedlg.hxx @@ -78,7 +78,7 @@ private: DECL_LINK(DefaultTemplateMenuSelectHdl, Menu*); DECL_LINK_TYPED(OpenRegionHdl, void*, void); - DECL_LINK(OpenTemplateHdl, ThumbnailViewItem*); + DECL_LINK_TYPED(OpenTemplateHdl, ThumbnailViewItem*, void); DECL_LINK(SearchUpdateHdl, void*); |