summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--compilerplugins/clang/store/constantfunction.cxx2
-rw-r--r--cui/source/inc/dlgname.hxx2
-rw-r--r--cui/source/options/optgdlg.hxx3
-rw-r--r--embeddedobj/test/MainThreadExecutor/xexecutor.cxx4
-rw-r--r--embeddedobj/test/mtexecutor/mainthreadexecutor.cxx3
-rw-r--r--embeddedobj/test/mtexecutor/mainthreadexecutor.hxx2
-rw-r--r--extensions/source/plugin/aqua/sysplug.mm4
-rw-r--r--extensions/source/plugin/inc/plugin/aqua/sysplug.hxx2
-rw-r--r--fpicker/test/svdem.cxx4
-rw-r--r--include/sfx2/linksrc.hxx1
-rw-r--r--include/sfx2/lnkbase.hxx1
-rw-r--r--include/svtools/treelist.hxx2
-rw-r--r--include/svtools/wizdlg.hxx6
-rw-r--r--include/svx/hdft.hxx4
-rw-r--r--include/tools/link.hxx45
-rw-r--r--include/vcl/dialog.hxx1
-rw-r--r--sc/workben/result.cxx3
-rw-r--r--sc/workben/test.cxx43
-rw-r--r--slideshow/test/demoshow.cxx5
-rw-r--r--svx/source/dialog/hdft.cxx9
-rw-r--r--sw/qa/tiledrendering/tiledrendering.cxx11
-rw-r--r--toolkit/source/awt/scrollabledialog.cxx4
-rw-r--r--tubes/source/contacts.cxx25
-rw-r--r--vcl/workben/vcldemo.cxx5
-rw-r--r--xmlsecurity/source/dialogs/certificatechooser.cxx1
-rw-r--r--xmlsecurity/workben/signaturetest.cxx21
26 files changed, 58 insertions, 155 deletions
diff --git a/compilerplugins/clang/store/constantfunction.cxx b/compilerplugins/clang/store/constantfunction.cxx
index 064d97850483..5dcbcc274024 100644
--- a/compilerplugins/clang/store/constantfunction.cxx
+++ b/compilerplugins/clang/store/constantfunction.cxx
@@ -425,7 +425,7 @@ bool ConstantFunction::VisitFunctionDecl(const FunctionDecl * pFunctionDecl) {
pFunctionDecl->getLocStart(), compiler.getSourceManager(), compiler.getLangOpts()) };
aImmediateMacro = name;
if (name == "TYPEINIT_FACTORY" || name == "TYPEINFO" || name == "TYPEINFO_OVERRIDE"
- || name.startswith("IMPL_LINK") || name == "DECL_LINK")
+ || name.startswith("IMPL_LINK_") )
{
return true;
}
diff --git a/cui/source/inc/dlgname.hxx b/cui/source/inc/dlgname.hxx
index ec765293c2ef..736154c9c776 100644
--- a/cui/source/inc/dlgname.hxx
+++ b/cui/source/inc/dlgname.hxx
@@ -49,7 +49,7 @@ public:
field is changed. The Link result determines whether the OK
Button is enabled (> 0) or disabled (== 0).
- @param rLink a Callback declared with DECL_LINK and implemented with
+ @param rLink a Callback declared with DECL_LINK_TYPED and implemented with
IMPL_LINK, that is executed on modification.
@param bCheckImmediately If true, the Link is called directly after
diff --git a/cui/source/options/optgdlg.hxx b/cui/source/options/optgdlg.hxx
index 695d03c0d100..658b89c91434 100644
--- a/cui/source/options/optgdlg.hxx
+++ b/cui/source/options/optgdlg.hxx
@@ -61,9 +61,6 @@ private:
DECL_LINK_TYPED( TwoFigureHdl, Edit&, void );
DECL_LINK_TYPED( TwoFigureConfigHdl, SpinField&, void );
DECL_LINK_TYPED( TwoFigureConfigFocusHdl, Control&, void );
-#ifdef WNT
- DECL_LINK( OnFileDlgToggled, void* );
-#endif
protected:
virtual sfxpg DeactivatePage( SfxItemSet* pSet = NULL ) override;
diff --git a/embeddedobj/test/MainThreadExecutor/xexecutor.cxx b/embeddedobj/test/MainThreadExecutor/xexecutor.cxx
index 24fd827bf1c7..2164f76516b5 100644
--- a/embeddedobj/test/MainThreadExecutor/xexecutor.cxx
+++ b/embeddedobj/test/MainThreadExecutor/xexecutor.cxx
@@ -29,7 +29,7 @@ void MainThreadExecutor_Impl::execute()
Application::PostUserEvent( LINK( this, MainThreadExecutor_Impl, executor ), NULL );
}
-IMPL_LINK_NOARG( MainThreadExecutor_Impl, executor )
+IMPL_LINK_NOARG_TYPED( MainThreadExecutor_Impl, executor, void*, void )
{
if ( m_xJob.is() )
{
@@ -40,8 +40,6 @@ IMPL_LINK_NOARG( MainThreadExecutor_Impl, executor )
m_bExecuted = sal_True;
delete this;
-
- return 0;
}
MainThreadExecutor_Impl::MainThreadExecutor_Impl( const uno::Reference< task::XJob >& xJob,
diff --git a/embeddedobj/test/mtexecutor/mainthreadexecutor.cxx b/embeddedobj/test/mtexecutor/mainthreadexecutor.cxx
index 09760748a039..45f650d0dc42 100644
--- a/embeddedobj/test/mtexecutor/mainthreadexecutor.cxx
+++ b/embeddedobj/test/mtexecutor/mainthreadexecutor.cxx
@@ -77,12 +77,11 @@ uno::Any SAL_CALL MainThreadExecutor::execute( const uno::Sequence< beans::Named
}
-IMPL_STATIC_LINK( MainThreadExecutor, worker, MainThreadExecutorRequest*, pThreadExecutorRequest )
+IMPL_STATIC_LINK_TYPED( MainThreadExecutor, worker, MainThreadExecutorRequest*, pThreadExecutorRequest, void )
{
pThreadExecutorRequest->doIt();
delete pThreadExecutorRequest;
- return 0;
}
diff --git a/embeddedobj/test/mtexecutor/mainthreadexecutor.hxx b/embeddedobj/test/mtexecutor/mainthreadexecutor.hxx
index 4eecd48cb058..095f983e2aaa 100644
--- a/embeddedobj/test/mtexecutor/mainthreadexecutor.hxx
+++ b/embeddedobj/test/mtexecutor/mainthreadexecutor.hxx
@@ -59,7 +59,7 @@ public:
static css::uno::Reference< css::uno::XInterface > SAL_CALL impl_staticCreateSelfInstance(
const css::uno::Reference< css::lang::XMultiServiceFactory >& xServiceManager );
- DECL_STATIC_LINK( MainThreadExecutor, worker, MainThreadExecutorRequest* );
+ DECL_STATIC_LINK_TYPED( MainThreadExecutor, worker, MainThreadExecutorRequest*, void );
// XJob
virtual css::uno::Any SAL_CALL execute( const css::uno::Sequence< css::beans::NamedValue >& Arguments ) throw (css::lang::IllegalArgumentException, css::uno::Exception, css::uno::RuntimeException);
diff --git a/extensions/source/plugin/aqua/sysplug.mm b/extensions/source/plugin/aqua/sysplug.mm
index 56ce65067537..a9b54a8ec2e1 100644
--- a/extensions/source/plugin/aqua/sysplug.mm
+++ b/extensions/source/plugin/aqua/sysplug.mm
@@ -384,7 +384,7 @@ sal_Bool MacPluginComm::retrieveFunction( const char* i_pName, void** o_ppFunc )
return (*o_ppFunc != NULL);
}
-IMPL_LINK_NOARG(MacPluginComm, NullTimerHdl)
+IMPL_LINK_NOARG_TYPED(MacPluginComm, NullTimerHdl, Timer*, void)
{
// note: this is a Timer handler, we are already protected by the SolarMutex
@@ -399,8 +399,6 @@ IMPL_LINK_NOARG(MacPluginComm, NullTimerHdl)
if( rPlugData.m_pPlugView ) // for safety do not dispatch null events before first NPP_SetWindow
(*m_aNPPfuncs.event)( &(*it)->getNPPInstance(), &aRec );
}
-
- return 0;
}
diff --git a/extensions/source/plugin/inc/plugin/aqua/sysplug.hxx b/extensions/source/plugin/inc/plugin/aqua/sysplug.hxx
index a9b752244c7a..3a1638a9381e 100644
--- a/extensions/source/plugin/inc/plugin/aqua/sysplug.hxx
+++ b/extensions/source/plugin/inc/plugin/aqua/sysplug.hxx
@@ -139,7 +139,7 @@ public:
void drawView( XPlugin_Impl* );
private:
sal_Bool retrieveFunction( const char* i_pName, void** i_ppFunc ) const;
- DECL_LINK( NullTimerHdl, void* );
+ DECL_LINK_TYPED( NullTimerHdl, Timer*, void );
private:
CFBundleRef m_xBundle;
diff --git a/fpicker/test/svdem.cxx b/fpicker/test/svdem.cxx
index 05f3e745135c..b35c194d035a 100644
--- a/fpicker/test/svdem.cxx
+++ b/fpicker/test/svdem.cxx
@@ -173,7 +173,7 @@ void MyWin::Resize()
-IMPL_LINK( MyWin, Test, PushButton*, pBtn )
+IMPL_LINK_TYPED( MyWin, Test, PushButton*, pBtn, void )
{
printf("Test\n");
if ( pBtn == &aOKBtn )
@@ -182,8 +182,6 @@ printf("Test\n");
pDlg->Execute();
printf("ok\n");
}
-
- return 0;
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/sfx2/linksrc.hxx b/include/sfx2/linksrc.hxx
index c288e98b4783..3b26d3a5e2c4 100644
--- a/include/sfx2/linksrc.hxx
+++ b/include/sfx2/linksrc.hxx
@@ -84,7 +84,6 @@ public:
// sal_True => data complete loaded
virtual bool IsDataComplete() const;
- // Link impl: DECL_LINK( MyEndEditHdl, sfx2::FileDialogHelper* ); <= param is the dialog
virtual void Edit( vcl::Window *, SvBaseLink *, const Link<const OUString&, void>& rEndEditHdl );
diff --git a/include/sfx2/lnkbase.hxx b/include/sfx2/lnkbase.hxx
index cb7e4a6d66df..a4255cfb8d0c 100644
--- a/include/sfx2/lnkbase.hxx
+++ b/include/sfx2/lnkbase.hxx
@@ -145,7 +145,6 @@ public:
bool Update();
void Disconnect();
- // Link impl: DECL_LINK( MyEndDialogHdl, SvBaseLink* ); <= param is this
virtual void Edit( vcl::Window*, const Link<SvBaseLink&,void>& rEndEditHdl );
// should the link appear in the dialog? (to the left in the link in the...)
diff --git a/include/svtools/treelist.hxx b/include/svtools/treelist.hxx
index 873b9bb822bb..fdd7879e075d 100644
--- a/include/svtools/treelist.hxx
+++ b/include/svtools/treelist.hxx
@@ -210,8 +210,6 @@ public:
// The Model calls the Clone Link to clone Entries.
// Thus we do not need to derive from the Model if we derive from SvTreeListEntry.
- // Declaration of the Clone Handler:
- // DECL_LINK(CloneHdl,SvTreeListEntry*);
// The Handler needs to return a SvTreeListEntry*
SvTreeListEntry* Clone( SvTreeListEntry* pEntry, sal_uLong& nCloneCount ) const;
void SetCloneLink( const Link<SvTreeListEntry*,SvTreeListEntry*>& rLink )
diff --git a/include/svtools/wizdlg.hxx b/include/svtools/wizdlg.hxx
index 44f1c6973e21..be3de098c17d 100644
--- a/include/svtools/wizdlg.hxx
+++ b/include/svtools/wizdlg.hxx
@@ -166,20 +166,18 @@ void MyWizardDlg::ActivatePage()
MyWizardDlg-Prev/Next-Handler
-----------------------------
-IMPL_LINK( MyWizardDlg, ImplPrevHdl, PushButton*, pBtn )
+IMPL_LINK_TYPED( MyWizardDlg, ImplPrevHdl, PushButton*, pBtn, void )
{
ShowPrevPage();
if ( !GetCurLevel() )
pBtn->Disable();
- return 0;
}
-IMPL_LINK( MyWizardDlg, ImplNextHdl, PushButton*, pBtn )
+IMPL_LINK_TYPED( MyWizardDlg, ImplNextHdl, PushButton*, pBtn, void )
{
ShowNextPage();
if ( GetCurLevel() < 3 )
pBtn->Disable();
- return 0;
}
*************************************************************************/
diff --git a/include/svx/hdft.hxx b/include/svx/hdft.hxx
index 06b2eec8166d..a95c5b745788 100644
--- a/include/svx/hdft.hxx
+++ b/include/svx/hdft.hxx
@@ -99,11 +99,9 @@ protected:
DECL_LINK_TYPED(HeightModify, Edit&, void);
DECL_LINK_TYPED(BorderModify, Edit&, void);
DECL_LINK_TYPED(BackgroundHdl, Button*, void);
-
- void UpdateExample();
- DECL_LINK(RangeHdl, void *);
DECL_LINK_TYPED(RangeFocusHdl, Control&, void);
void RangeHdl();
+ void UpdateExample();
private:
SVX_DLLPRIVATE void ResetBackground_Impl( const SfxItemSet& rSet );
diff --git a/include/tools/link.hxx b/include/tools/link.hxx
index 548dbfb611f5..cbac102810d1 100644
--- a/include/tools/link.hxx
+++ b/include/tools/link.hxx
@@ -24,49 +24,6 @@
#include <sal/types.h>
-#define DECL_LINK(Member, ArgType) \
- static sal_IntPtr LinkStub##Member(void *, void *); \
- sal_IntPtr Member(ArgType)
-
-#define DECL_STATIC_LINK(Class, Member, ArgType) \
- static sal_IntPtr LinkStub##Member(void *, void *); \
- static sal_IntPtr Member(Class *, ArgType)
-
-#define DECL_DLLPRIVATE_LINK(Member, ArgType) \
- SAL_DLLPRIVATE static sal_IntPtr LinkStub##Member(void *, void *); \
- SAL_DLLPRIVATE sal_IntPtr Member(ArgType)
-
-#define DECL_DLLPRIVATE_STATIC_LINK(Class, Member, ArgType) \
- SAL_DLLPRIVATE static sal_IntPtr LinkStub##Member(void *, void *); \
- SAL_DLLPRIVATE static sal_IntPtr Member(Class *, ArgType)
-
-#define IMPL_LINK(Class, Member, ArgType, ArgName) \
- sal_IntPtr Class::LinkStub##Member(void * instance, void * data) { \
- return static_cast<Class *>(instance)->Member( \
- static_cast<ArgType>(data)); \
- } \
- sal_IntPtr Class::Member(ArgType ArgName)
-
-#define IMPL_LINK_NOARG(Class, Member) \
- sal_IntPtr Class::LinkStub##Member(void * instance, void * data) { \
- return static_cast<Class *>(instance)->Member(data); \
- } \
- sal_IntPtr Class::Member(SAL_UNUSED_PARAMETER void *)
-
-#define IMPL_STATIC_LINK(Class, Member, ArgType, ArgName) \
- sal_IntPtr Class::LinkStub##Member(void * instance, void * data) { \
- return Member( \
- static_cast<Class *>(instance), static_cast<ArgType>(data)); \
- } \
- sal_IntPtr Class::Member(SAL_UNUSED_PARAMETER Class *, ArgType ArgName)
-
-#define IMPL_STATIC_LINK_NOARG(Class, Member) \
- sal_IntPtr Class::LinkStub##Member(void * instance, void * data) { \
- return Member(static_cast<Class *>(instance), data); \
- } \
- sal_IntPtr Class::Member( \
- SAL_UNUSED_PARAMETER Class *, SAL_UNUSED_PARAMETER void *)
-
#define DECL_LINK_TYPED(Member, ArgType, RetType) \
static RetType LinkStub##Member(void *, ArgType); \
RetType Member(ArgType)
@@ -113,7 +70,7 @@
#define LINK(Instance, Class, Member) ::tools::detail::makeLink( \
static_cast<Class *>(Instance), &Class::LinkStub##Member)
-template<typename Arg = void *, typename Ret = sal_IntPtr>
+template<typename Arg, typename Ret>
class SAL_WARN_UNUSED Link {
public:
typedef Ret Stub(void *, Arg);
diff --git a/include/vcl/dialog.hxx b/include/vcl/dialog.hxx
index 668ab71eb407..e25e514f5c66 100644
--- a/include/vcl/dialog.hxx
+++ b/include/vcl/dialog.hxx
@@ -101,7 +101,6 @@ public:
// Dialog::Execute replacement API
public:
- // Link impl: DECL_LINK( MyEndDialogHdl, Dialog* ); <= param is dialog just ended
virtual void StartExecuteModal( const Link<Dialog&,void>& rEndDialogHdl );
long GetResult() const;
private:
diff --git a/sc/workben/result.cxx b/sc/workben/result.cxx
index 7d43f8d9322b..e497aa4ae5d0 100644
--- a/sc/workben/result.cxx
+++ b/sc/workben/result.cxx
@@ -50,11 +50,10 @@ void ScAddInResult::NewValue()
(*aListeners[n])->modified( aEvent );
}
-IMPL_LINK( ScAddInResult, TimeoutHdl, Timer*, pT )
+IMPL_LINK_TYPED( ScAddInResult, TimeoutHdl, Timer*, pT, void )
{
NewValue();
pT->Start();
- return 0;
}
ScAddInResult::~ScAddInResult()
diff --git a/sc/workben/test.cxx b/sc/workben/test.cxx
index 6da55dfc4d7c..26f114d97896 100644
--- a/sc/workben/test.cxx
+++ b/sc/workben/test.cxx
@@ -76,11 +76,11 @@ private:
public:
MyWindow( vcl::Window *pParent );
- DECL_LINK(CountHdl, PushButton*);
- DECL_LINK(TextHdl, PushButton*);
- DECL_LINK(BlaHdl, PushButton*);
- DECL_LINK(TabHdl, PushButton*);
- DECL_LINK(ViewHdl, PushButton*);
+ DECL_LINK_TYPED(CountHdl, PushButton*, void);
+ DECL_LINK_TYPED(TextHdl, PushButton*, void);
+ DECL_LINK_TYPED(BlaHdl, PushButton*, void);
+ DECL_LINK_TYPED(TabHdl, PushButton*, void);
+ DECL_LINK_TYPED(ViewHdl, PushButton*, void);
};
class ScTestListener : public XSelectionChangeListener, public UsrObject
@@ -1501,7 +1501,7 @@ void lcl_Pivot( FixedText& aTimeText ) // 30
}
}
-IMPL_LINK_NOARG(MyWindow, CountHdl)
+IMPL_LINK_NOARG_TYPED(MyWindow, CountHdl, PushButton*, void)
{
long nCount = aCountField.GetValue();
@@ -1606,11 +1606,9 @@ IMPL_LINK_NOARG(MyWindow, CountHdl)
lcl_Pivot(aTimeText);
break;
}
-
- return 0;
}
-IMPL_LINK_NOARG(MyWindow, TextHdl)
+IMPL_LINK_NOARG_TYPED(MyWindow, TextHdl, PushButton*, void)
{
sal_uInt16 nCol = (sal_uInt16)aColField.GetValue();
sal_uInt16 nRow = (sal_uInt16)aRowField.GetValue();
@@ -1653,11 +1651,9 @@ IMPL_LINK_NOARG(MyWindow, TextHdl)
}
}
}
-
- return 0;
}
-IMPL_LINK_NOARG(MyWindow, BlaHdl)
+IMPL_LINK_NOARG_TYPED(MyWindow, BlaHdl, PushButton*, void)
{
aTimeText.SetText("...");
@@ -1725,10 +1721,9 @@ IMPL_LINK_NOARG(MyWindow, BlaHdl)
xGlobalCell = xCell;
}
- return 0;
}
-IMPL_LINK_NOARG(MyWindow, TabHdl)
+IMPL_LINK_NOARG_TYPED(MyWindow, TabHdl, PushButton*, void)
{
String aResult;
@@ -1795,8 +1790,6 @@ IMPL_LINK_NOARG(MyWindow, TabHdl)
}
aTimeText.SetText(aResult);
-
- return 0;
}
void lcl_FillCells(XCellCollectionRef xColl)
@@ -1819,16 +1812,16 @@ void lcl_FillCells(XCellCollectionRef xColl)
}
}
-IMPL_LINK_NOARG(MyWindow, ViewHdl)
+IMPL_LINK_NOARG_TYPED(MyWindow, ViewHdl, PushButton*, void)
{
XSpreadsheetDocumentRef xDoc = lcl_GetDocument(); // calc model
XInterfaceRef xInt = lcl_GetView();
- if (!xInt) return 0;
+ if (!xInt) return;
XDocumentViewRef xView = (XDocumentView*)xInt->queryInterface(XDocumentView::getSmartUik());
- if (!xView) return 0;
+ if (!xView) return;
XInterfaceRef xSelInt = xView->getSelection();
- if (!xSelInt) return 0;
+ if (!xSelInt) return;
XAutoFormattableRef xAuto = (XAutoFormattable*)xSelInt->
queryInterface(XAutoFormattable::getSmartUik());
@@ -1870,12 +1863,12 @@ IMPL_LINK_NOARG(MyWindow, ViewHdl)
XCellRangeSourceRef xSrc = (XCellRangeSource*)
xInt->queryInterface(XCellRangeSource::getSmartUik());
- if (!xSrc) return 0;
+ if (!xSrc) return;
XCellRangeRef xRange = xSrc->getReferredCells();
- if (!xRange) return 0;
+ if (!xRange) return;
XCellCollectionRef xColl = (XCellCollection*)
xRange->queryInterface(XCellCollection::getSmartUik());
- if (!xColl) return 0;
+ if (!xColl) return;
XActionLockableRef xLock = (XActionLockable*)
xDoc->queryInterface(XActionLockable::getSmartUik());
@@ -1888,9 +1881,7 @@ IMPL_LINK_NOARG(MyWindow, ViewHdl)
xLock->removeActionLock(); // don't paint in between
XStarCalcViewRef xCalc = (XStarCalcView*)xInt->queryInterface(XStarCalcView::getSmartUik());
- if (!xCalc) return 0;
-
- return 0;
+ if (!xCalc) return;
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/slideshow/test/demoshow.cxx b/slideshow/test/demoshow.cxx
index 507ecc6ccb26..b18efdd8c05a 100644
--- a/slideshow/test/demoshow.cxx
+++ b/slideshow/test/demoshow.cxx
@@ -390,7 +390,7 @@ public:
private:
void init();
- DECL_LINK( updateHdl, Timer* );
+ DECL_LINK_TYPED( updateHdl, Timer*, void );
ChildWindow maLeftChild;
ChildWindow maRightTopChild;
@@ -463,13 +463,12 @@ void DemoWindow::init()
}
}
-IMPL_LINK_NOARG(DemoWindow, updateHdl)
+IMPL_LINK_NOARG_TYPED(DemoWindow, updateHdl, Timer*, void)
{
init();
if( mxShow.is() )
mxShow->update(0);
- return 0;
}
void DemoWindow::Paint( const Rectangle& /*rRect*/ )
diff --git a/svx/source/dialog/hdft.cxx b/svx/source/dialog/hdft.cxx
index 925d43d475bd..b1e9c1b3a251 100644
--- a/svx/source/dialog/hdft.cxx
+++ b/svx/source/dialog/hdft.cxx
@@ -466,7 +466,7 @@ void SvxHFPage::Reset( const SfxItemSet* rSet )
m_pLMEdit->SaveValue();
m_pRMEdit->SaveValue();
m_pCntSharedBox->SaveValue();
- RangeHdl( 0 );
+ RangeHdl();
const SfxPoolItem* pItem = 0;
SfxObjectShell* pShell;
@@ -1046,7 +1046,7 @@ void SvxHFPage::ActivatePage( const SfxItemSet& rSet )
m_pBspWin->SetVert( static_cast<const SfxBoolItem*>(pItem)->GetValue() );
}
ResetBackground_Impl( rSet );
- RangeHdl( 0 );
+ RangeHdl();
}
SfxTabPage::sfxpg SvxHFPage::DeactivatePage( SfxItemSet* _pSet )
@@ -1056,11 +1056,6 @@ SfxTabPage::sfxpg SvxHFPage::DeactivatePage( SfxItemSet* _pSet )
return LEAVE_PAGE;
}
-IMPL_LINK_NOARG(SvxHFPage, RangeHdl)
-{
- RangeHdl();
- return 0;
-}
IMPL_LINK_NOARG_TYPED(SvxHFPage, RangeFocusHdl, Control&, void)
{
RangeHdl();
diff --git a/sw/qa/tiledrendering/tiledrendering.cxx b/sw/qa/tiledrendering/tiledrendering.cxx
index 62c9baf77fcb..6db48a1e3880 100644
--- a/sw/qa/tiledrendering/tiledrendering.cxx
+++ b/sw/qa/tiledrendering/tiledrendering.cxx
@@ -107,11 +107,11 @@ public:
ModalDialog::dispose();
}
- DECL_LINK ( RenderHdl, Button * );
- DECL_LINK ( ChooseDocumentHdl, Button * );
+ DECL_LINK_TYPED( RenderHdl, Button *, void );
+ DECL_LINK_TYPED( ChooseDocumentHdl, Button *, void );
};
-IMPL_LINK ( TiledRenderingDialog, RenderHdl, Button *, )
+IMPL_LINK_NOARG_TYPED( TiledRenderingDialog, RenderHdl, Button *, void)
{
int contextWidth = mpContextWidth->GetValue();
int contextHeight = mpContextHeight->GetValue();
@@ -143,11 +143,9 @@ IMPL_LINK ( TiledRenderingDialog, RenderHdl, Button *, )
// update the dialog size
setOptimalLayoutSize();
}
-
- return 1;
}
-IMPL_LINK ( TiledRenderingDialog, ChooseDocumentHdl, Button *, )
+IMPL_LINK_NOARG_TYPED( TiledRenderingDialog, ChooseDocumentHdl, Button *, void )
{
FileDialogHelper aDlgHelper( TemplateDescription::FILEOPEN_SIMPLE, 0 );
uno::Reference < XFilePicker > xFP = aDlgHelper.GetFilePicker();
@@ -156,7 +154,6 @@ IMPL_LINK ( TiledRenderingDialog, ChooseDocumentHdl, Button *, )
OUString aFileUrl =xFP->getFiles().getConstArray()[0];
mpApp->Open(aFileUrl);
}
- return 1;
}
void TiledRenderingApp::Open(OUString & aFileUrl)
diff --git a/toolkit/source/awt/scrollabledialog.cxx b/toolkit/source/awt/scrollabledialog.cxx
index 4d6fc4df55c6..cd408d31724b 100644
--- a/toolkit/source/awt/scrollabledialog.cxx
+++ b/toolkit/source/awt/scrollabledialog.cxx
@@ -115,8 +115,8 @@ void ScrollableWrapper<T>::lcl_Scroll( long nX, long nY )
}
}
-//Can't use IMPL_LINK with the template
-//IMPL_LINK( ScrollableWrapper, ScrollBarHdl, ScrollBar*, pSB )
+//Can't use IMPL_LINK_TYPED with the template
+//IMPL_LINK_TYPED( ScrollableWrapper, ScrollBarHdl, ScrollBar*, pSB, void )
template< class T>
void ScrollableWrapper<T>::LinkStubScrollBarHdl( void* pThis, ScrollBar* pCaller)
diff --git a/tubes/source/contacts.cxx b/tubes/source/contacts.cxx
index 08388805352a..6f8ae2c0ec58 100644
--- a/tubes/source/contacts.cxx
+++ b/tubes/source/contacts.cxx
@@ -31,11 +31,11 @@ class TubeContacts : public ModelessDialog
ListBox* mpList;
Collaboration* mpCollaboration;
- DECL_LINK( BtnDemoHdl, void * );
- DECL_LINK( BtnConnectHdl, void * );
- DECL_LINK( BtnGroupHdl, void * );
- DECL_LINK( BtnInviteHdl, void * );
- DECL_LINK( BtnListenHdl, void * );
+ DECL_LINK_TYPED( BtnDemoHdl, Button*, void );
+ DECL_LINK_TYPED( BtnConnectHdl, Button*, void );
+ DECL_LINK_TYPED( BtnGroupHdl, Button*, void );
+ DECL_LINK_TYPED( BtnInviteHdl, Button*, void );
+ DECL_LINK_TYPED( BtnListenHdl, Button*, void );
AccountContactPairV maACs;
@@ -175,34 +175,29 @@ public:
}
};
-IMPL_LINK_NOARG( TubeContacts, BtnDemoHdl )
+IMPL_LINK_NOARG_TYPED( TubeContacts, BtnDemoHdl, Button*, void )
{
StartDemoSession();
- return 0;
}
-IMPL_LINK_NOARG( TubeContacts, BtnConnectHdl )
+IMPL_LINK_NOARG_TYPED( TubeContacts, BtnConnectHdl, Button*, void )
{
StartBuddySession();
- return 0;
}
-IMPL_LINK_NOARG( TubeContacts, BtnGroupHdl )
+IMPL_LINK_NOARG_TYPED( TubeContacts, BtnGroupHdl, Button*, void )
{
StartGroupSession();
- return 0;
}
-IMPL_LINK_NOARG( TubeContacts, BtnInviteHdl )
+IMPL_LINK_NOARG_TYPED( TubeContacts, BtnInviteHdl, Button*, void )
{
Invite();
- return 0;
}
-IMPL_LINK_NOARG( TubeContacts, BtnListenHdl )
+IMPL_LINK_NOARG_TYPED( TubeContacts, BtnListenHdl, Button*, void )
{
Listen();
- return 0;
}
} // anonymous namespace
diff --git a/vcl/workben/vcldemo.cxx b/vcl/workben/vcldemo.cxx
index 9ae1cd1409a3..03493cdbea05 100644
--- a/vcl/workben/vcldemo.cxx
+++ b/vcl/workben/vcldemo.cxx
@@ -169,7 +169,7 @@ public:
FloatingWindow *mpButtonWin;
AutoTimer maBounce;
int mnBounceX, mnBounceY;
- DECL_LINK(BounceTimerCb, void *);
+ DECL_LINK_TYPED(BounceTimerCb, Timer*, void);
#endif
bool MouseButtonDown(const MouseEvent& rMEvt);
@@ -1164,7 +1164,7 @@ public:
};
#if FIXME_BOUNCE_BUTTON
-IMPL_LINK_NOARG(DemoRenderer,BounceTimerCb)
+IMPL_LINK_NOARG_TYPED(DemoRenderer,BounceTimerCb,Timer*,void)
{
mpButton->Check(mnBounceX>0);
mpButton->SetPressed(mnBounceY>0);
@@ -1182,7 +1182,6 @@ IMPL_LINK_NOARG(DemoRenderer,BounceTimerCb)
// All smoke and mirrors to test sub-region invalidation underneath
Rectangle aRect(aCur, mpButtonWin->GetSizePixel());
Invalidate(aRect);
- return 0;
}
#endif
diff --git a/xmlsecurity/source/dialogs/certificatechooser.cxx b/xmlsecurity/source/dialogs/certificatechooser.cxx
index 8a9138ef94ac..24b13fc35903 100644
--- a/xmlsecurity/source/dialogs/certificatechooser.cxx
+++ b/xmlsecurity/source/dialogs/certificatechooser.cxx
@@ -119,7 +119,6 @@ short CertificateChooser::Execute()
return ModalDialog::Execute();
}
-// IMPL_LINK_NOARG(CertificateChooser, Initialize)
void CertificateChooser::ImplInitialize()
{
if ( !mbInitialized )
diff --git a/xmlsecurity/workben/signaturetest.cxx b/xmlsecurity/workben/signaturetest.cxx
index e97e6f33c633..d16e9468f489 100644
--- a/xmlsecurity/workben/signaturetest.cxx
+++ b/xmlsecurity/workben/signaturetest.cxx
@@ -123,13 +123,9 @@ private:
FixedLine maHintLine;
FixedText maHintText;
- DECL_LINK( CryptoCheckBoxHdl, CheckBox* );
- DECL_LINK( SignButtonHdl, Button* );
- DECL_LINK( VerifyButtonHdl, Button* );
- DECL_LINK( DigitalSignaturesWithServiceHdl, Button* );
- DECL_LINK( VerifyDigitalSignaturesHdl, Button* );
- DECL_LINK( DigitalSignaturesWithTokenHdl, Button* );
- DECL_LINK( StartVerifySignatureHdl, void* );
+ DECL_LINK_TYPED( CryptoCheckBoxHdl, CheckBox*, void );
+ DECL_LINK_TYPED( DigitalSignaturesWithServiceHdl, Button*, void );
+ DECL_LINK_TYPED( VerifyDigitalSignaturesHdl, Button*, void );
public:
MyWin( vcl::Window* pParent, WinBits nWinStyle );
@@ -255,7 +251,7 @@ MyWin::MyWin( vcl::Window* pParent, WinBits nWinStyle ) :
}
-IMPL_LINK_NOARG(MyWin, CryptoCheckBoxHdl)
+IMPL_LINK_NOARG_TYPED(MyWin, CryptoCheckBoxHdl, CheckBox*, void)
{
if ( maCryptoCheckBox.IsChecked() )
{
@@ -267,10 +263,9 @@ IMPL_LINK_NOARG(MyWin, CryptoCheckBoxHdl)
maEditTokenName.Enable();
maFixedTextTokenName.Enable();
}
- return 1;
}
-IMPL_LINK_NOARG(MyWin, DigitalSignaturesWithServiceHdl)
+IMPL_LINK_NOARG_TYPED(MyWin, DigitalSignaturesWithServiceHdl, Button*, void)
{
OUString aDocFileName = maEditDOCFileName.GetText();
uno::Reference < embed::XStorage > xStore = ::comphelper::OStorageHelper::GetStorageFromURL(
@@ -279,11 +274,9 @@ IMPL_LINK_NOARG(MyWin, DigitalSignaturesWithServiceHdl)
uno::Reference< security::XDocumentDigitalSignatures > xD(
security::DocumentDigitalSignatures::createDefault(comphelper::getProcessComponentContext()) );
xD->signDocumentContent( xStore, NULL );
-
- return 0;
}
-IMPL_LINK_NOARG(MyWin, VerifyDigitalSignaturesHdl)
+IMPL_LINK_NOARG_TYPED(MyWin, VerifyDigitalSignaturesHdl, Button*, void)
{
OUString aDocFileName = maEditDOCFileName.GetText();
uno::Reference < embed::XStorage > xStore = ::comphelper::OStorageHelper::GetStorageFromURL(
@@ -303,8 +296,6 @@ IMPL_LINK_NOARG(MyWin, VerifyDigitalSignaturesHdl)
aText.append( "valid" );
ScopedVclPtr<InfoBox>::Create( this, aText )->Execute();
}
-
- return 0;
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */