summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNoel Grandin <noelgrandin@gmail.com>2015-09-02 17:53:43 +0200
committerNoel Grandin <noelgrandin@gmail.com>2015-09-04 06:31:16 +0000
commit5338d2abe4078626d2cfa38cde99dfa1d4eb2f6b (patch)
treeed8354745a9761a75f10c310c569d828bacbab6b
parentbb1dcd35f350e2375f6a8a9d27b02fb5784a476f (diff)
convert Link<> to typed
Change-Id: I4d6c37e82a5b96c09b989df248f94f0afe228b46 Reviewed-on: https://gerrit.libreoffice.org/18305 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
-rw-r--r--avmedia/inc/mediacontrol.hxx6
-rw-r--r--avmedia/source/framework/mediacontrol.cxx12
-rw-r--r--include/svx/sidebar/AreaPropertyPanelBase.hxx2
-rw-r--r--include/vcl/slider.hxx8
-rw-r--r--svx/source/sidebar/area/AreaPropertyPanelBase.cxx4
-rw-r--r--svx/source/sidebar/shadow/ShadowPropertyPanel.cxx3
-rw-r--r--svx/source/sidebar/shadow/ShadowPropertyPanel.hxx2
7 files changed, 14 insertions, 23 deletions
diff --git a/avmedia/inc/mediacontrol.hxx b/avmedia/inc/mediacontrol.hxx
index 9e91b1b0816b..521cd9869942 100644
--- a/avmedia/inc/mediacontrol.hxx
+++ b/avmedia/inc/mediacontrol.hxx
@@ -79,9 +79,9 @@ private:
void implUpdateTimeField( double fCurTime );
Image implGetImage( sal_Int32 nImageId ) const;
- DECL_LINK( implTimeHdl, Slider* );
- DECL_LINK( implTimeEndHdl, Slider* );
- DECL_LINK( implVolumeHdl, Slider* );
+ DECL_LINK_TYPED( implTimeHdl, Slider*, void );
+ DECL_LINK_TYPED( implTimeEndHdl, Slider*, void );
+ DECL_LINK_TYPED( implVolumeHdl, Slider*, void );
DECL_LINK_TYPED( implSelectHdl, ToolBox*, void );
DECL_LINK( implZoomSelectHdl, ListBox* );
DECL_LINK_TYPED(implTimeoutHdl, Idle *, void);
diff --git a/avmedia/source/framework/mediacontrol.cxx b/avmedia/source/framework/mediacontrol.cxx
index 137a79524df7..e5b58a8c00b4 100644
--- a/avmedia/source/framework/mediacontrol.cxx
+++ b/avmedia/source/framework/mediacontrol.cxx
@@ -439,18 +439,16 @@ Image MediaControl::implGetImage( sal_Int32 nImageId ) const
-IMPL_LINK( MediaControl, implTimeHdl, Slider*, p )
+IMPL_LINK_TYPED( MediaControl, implTimeHdl, Slider*, p, void )
{
mbLocked = true;
maIdle.Stop();
implUpdateTimeField( p->GetThumbPos() * maItem.getDuration() / AVMEDIA_TIME_RANGE );
-
- return 0;
}
-IMPL_LINK( MediaControl, implTimeEndHdl, Slider*, p )
+IMPL_LINK_TYPED( MediaControl, implTimeEndHdl, Slider*, p, void )
{
MediaItem aExecItem;
@@ -459,21 +457,17 @@ IMPL_LINK( MediaControl, implTimeEndHdl, Slider*, p )
update();
maIdle.Start();
mbLocked = false;
-
- return 0;
}
-IMPL_LINK( MediaControl, implVolumeHdl, Slider*, p )
+IMPL_LINK_TYPED( MediaControl, implVolumeHdl, Slider*, p, void )
{
MediaItem aExecItem;
aExecItem.setVolumeDB( static_cast< sal_Int16 >( p->GetThumbPos() ) );
execute( aExecItem );
update();
-
- return 0;
}
diff --git a/include/svx/sidebar/AreaPropertyPanelBase.hxx b/include/svx/sidebar/AreaPropertyPanelBase.hxx
index c12842f7708b..47fd4b4b9efd 100644
--- a/include/svx/sidebar/AreaPropertyPanelBase.hxx
+++ b/include/svx/sidebar/AreaPropertyPanelBase.hxx
@@ -164,7 +164,7 @@ protected:
DECL_LINK(SelectFillAttrHdl, ListBox* );
DECL_LINK(ChangeTrgrTypeHdl_Impl, void*);
DECL_LINK(ModifyTransparentHdl_Impl, void*);
- DECL_LINK(ModifyTransSliderHdl, void*);
+ DECL_LINK_TYPED(ModifyTransSliderHdl, Slider*, void);
// for transparency gradient
VclPtr<PopupControl> CreateTransparencyGradientControl (PopupContainer* pParent);
diff --git a/include/vcl/slider.hxx b/include/vcl/slider.hxx
index 10c7e9b7a390..064d475ae22b 100644
--- a/include/vcl/slider.hxx
+++ b/include/vcl/slider.hxx
@@ -55,8 +55,8 @@ private:
VclPtr<NumericField> mpLinkedField;
- Link<> maSlideHdl;
- Link<> maEndSlideHdl;
+ Link<Slider*,void> maSlideHdl;
+ Link<Slider*,void> maEndSlideHdl;
DECL_LINK(LinkedFieldModifyHdl, NumericField*);
@@ -112,8 +112,8 @@ public:
void SetLinkedField(VclPtr<NumericField> pField);
- void SetSlideHdl( const Link<>& rLink ) { maSlideHdl = rLink; }
- void SetEndSlideHdl( const Link<>& rLink ) { maEndSlideHdl = rLink; }
+ void SetSlideHdl( const Link<Slider*,void>& rLink ) { maSlideHdl = rLink; }
+ void SetEndSlideHdl( const Link<Slider*,void>& rLink ) { maEndSlideHdl = rLink; }
};
#endif // INCLUDED_VCL_SLIDER_HXX
diff --git a/svx/source/sidebar/area/AreaPropertyPanelBase.cxx b/svx/source/sidebar/area/AreaPropertyPanelBase.cxx
index 46a057d3fc62..d5ef4c045f42 100644
--- a/svx/source/sidebar/area/AreaPropertyPanelBase.cxx
+++ b/svx/source/sidebar/area/AreaPropertyPanelBase.cxx
@@ -1148,14 +1148,12 @@ void AreaPropertyPanelBase::Update()
}
}
-IMPL_LINK_NOARG(AreaPropertyPanelBase, ModifyTransSliderHdl)
+IMPL_LINK_NOARG_TYPED(AreaPropertyPanelBase, ModifyTransSliderHdl, Slider*, void)
{
const sal_uInt16 nVal = mpSldTransparent->GetThumbPos();
SetTransparency(nVal);
const XFillTransparenceItem aLinearItem(nVal);
setFillTransparence(aLinearItem);
-
- return 0L;
}
IMPL_LINK_TYPED( AreaPropertyPanelBase, ClickTrGrHdl_Impl, ToolBox*, pToolBox, void )
diff --git a/svx/source/sidebar/shadow/ShadowPropertyPanel.cxx b/svx/source/sidebar/shadow/ShadowPropertyPanel.cxx
index 31e5b33050be..86701705b0fe 100644
--- a/svx/source/sidebar/shadow/ShadowPropertyPanel.cxx
+++ b/svx/source/sidebar/shadow/ShadowPropertyPanel.cxx
@@ -166,13 +166,12 @@ IMPL_LINK_NOARG(ShadowPropertyPanel, ModifyShadowTransMetricHdl)
return 0;
}
-IMPL_LINK_NOARG(ShadowPropertyPanel, ModifyShadowTransSliderHdl)
+IMPL_LINK_NOARG_TYPED(ShadowPropertyPanel, ModifyShadowTransSliderHdl, Slider*, void)
{
sal_uInt16 nVal = mpShadowTransSlider->GetThumbPos();
SetTransparencyValue(nVal);
SdrPercentItem aItem( makeSdrShadowTransparenceItem(nVal) );
GetBindings()->GetDispatcher()->Execute(SID_ATTR_SHADOW_TRANSPARENCE, SfxCallMode::RECORD, &aItem, 0L);
- return 0;
}
IMPL_LINK_NOARG(ShadowPropertyPanel, ModifyShadowDistanceHdl)
diff --git a/svx/source/sidebar/shadow/ShadowPropertyPanel.hxx b/svx/source/sidebar/shadow/ShadowPropertyPanel.hxx
index 2ae22e1d39ad..da120999a180 100644
--- a/svx/source/sidebar/shadow/ShadowPropertyPanel.hxx
+++ b/svx/source/sidebar/shadow/ShadowPropertyPanel.hxx
@@ -85,7 +85,7 @@ private:
DECL_LINK(ModifyShadowColorHdl, void*);
DECL_LINK(ModifyShadowTransMetricHdl, void*);
DECL_LINK(ModifyShadowDistanceHdl, void*);
- DECL_LINK(ModifyShadowTransSliderHdl, void*);
+ DECL_LINK_TYPED(ModifyShadowTransSliderHdl, Slider*, void);
};
}
}