diff options
author | Noel Grandin <noel@peralex.com> | 2015-08-27 13:08:02 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2015-08-28 09:49:56 +0200 |
commit | bd8b93fdff93ff7b2b7e493a7bcef6a59f299dae (patch) | |
tree | f05be9665737f0667faf95702d96fbf3f0a103c5 /extensions/source/plugin | |
parent | 1b9c3a17e8496aedfb80528c5275e6658154789d (diff) |
make PostUserEvent Link<> typed
Change-Id: I13f10bda985d55d419a5bff481130a456ae2db8a
Diffstat (limited to 'extensions/source/plugin')
-rw-r--r-- | extensions/source/plugin/base/nfuncs.cxx | 6 | ||||
-rw-r--r-- | extensions/source/plugin/base/xplugin.cxx | 5 | ||||
-rw-r--r-- | extensions/source/plugin/inc/plugin/impl.hxx | 2 | ||||
-rw-r--r-- | extensions/source/plugin/inc/plugin/unx/plugcon.hxx | 2 | ||||
-rw-r--r-- | extensions/source/plugin/unx/npnapi.cxx | 3 | ||||
-rw-r--r-- | extensions/source/plugin/unx/nppapi.cxx | 5 |
6 files changed, 10 insertions, 13 deletions
diff --git a/extensions/source/plugin/base/nfuncs.cxx b/extensions/source/plugin/base/nfuncs.cxx index f36e89b24079..f57540abd0ed 100644 --- a/extensions/source/plugin/base/nfuncs.cxx +++ b/extensions/source/plugin/base/nfuncs.cxx @@ -177,11 +177,12 @@ struct AsynchronousGetURL OUString aTarget; Reference< XEventListener > xListener; - DECL_LINK( getURL, XPlugin_Impl* ); + DECL_LINK_TYPED( getURL, void*, void ); }; -IMPL_LINK( AsynchronousGetURL, getURL, XPlugin_Impl*, pImpl ) +IMPL_LINK_TYPED( AsynchronousGetURL, getURL, void*, p, void ) { + XPlugin_Impl* pImpl = static_cast<XPlugin_Impl*>(p); try { pImpl->enterPluginCallback(); @@ -202,7 +203,6 @@ IMPL_LINK( AsynchronousGetURL, getURL, XPlugin_Impl*, pImpl ) } pImpl->leavePluginCallback(); delete this; - return 0; } diff --git a/extensions/source/plugin/base/xplugin.cxx b/extensions/source/plugin/base/xplugin.cxx index eab48cd11979..f8e69e757fc2 100644 --- a/extensions/source/plugin/base/xplugin.cxx +++ b/extensions/source/plugin/base/xplugin.cxx @@ -189,7 +189,7 @@ void XPlugin_Impl::checkListeners( const char* normalizedURL ) } } -IMPL_LINK( XPlugin_Impl, secondLevelDispose, XPlugin_Impl*, /*pThis*/ ) +IMPL_LINK_NOARG_TYPED( XPlugin_Impl, secondLevelDispose, void*, void ) { Guard< Mutex > aGuard( m_aMutex ); @@ -206,7 +206,7 @@ IMPL_LINK( XPlugin_Impl, secondLevelDispose, XPlugin_Impl*, /*pThis*/ ) break; } if( iter == rList.end() || ! isDisposable() ) - return 0; + return; } if (m_pDisposer) @@ -229,7 +229,6 @@ IMPL_LINK( XPlugin_Impl, secondLevelDispose, XPlugin_Impl*, /*pThis*/ ) #endif destroyInstance(); PluginControl_Impl::dispose(); - return 0; } void XPlugin_Impl::dispose() throw(std::exception) diff --git a/extensions/source/plugin/inc/plugin/impl.hxx b/extensions/source/plugin/inc/plugin/impl.hxx index efbe9e366fe7..e0e9487926a9 100644 --- a/extensions/source/plugin/inc/plugin/impl.hxx +++ b/extensions/source/plugin/inc/plugin/impl.hxx @@ -201,7 +201,7 @@ public: void enterPluginCallback() { m_nCalledFromPlugin++; } void leavePluginCallback() { m_nCalledFromPlugin--; } bool isDisposable() { return m_nCalledFromPlugin < 1; } - DECL_LINK( secondLevelDispose, XPlugin_Impl* ); + DECL_LINK_TYPED( secondLevelDispose, void*, void ); void addPluginEventListener( PluginEventListener* pListener ) { m_aPEventListeners.push_back( pListener ); } diff --git a/extensions/source/plugin/inc/plugin/unx/plugcon.hxx b/extensions/source/plugin/inc/plugin/unx/plugcon.hxx index 20db98077040..d0e3d33bc9af 100644 --- a/extensions/source/plugin/inc/plugin/unx/plugcon.hxx +++ b/extensions/source/plugin/inc/plugin/unx/plugcon.hxx @@ -133,7 +133,7 @@ protected: static std::vector<PluginConnector*> allConnectors; DECL_LINK( NewMessageHdl, Mediator* ); - DECL_LINK( WorkOnNewMessageHdl, Mediator* ); + DECL_LINK_TYPED( WorkOnNewMessageHdl, void*, void ); std::vector<NPStream*> m_aNPWrapStreams; std::vector<ConnectorInstance*> m_aInstances; diff --git a/extensions/source/plugin/unx/npnapi.cxx b/extensions/source/plugin/unx/npnapi.cxx index 1129fc8ea3b9..5330c823bb04 100644 --- a/extensions/source/plugin/unx/npnapi.cxx +++ b/extensions/source/plugin/unx/npnapi.cxx @@ -520,7 +520,7 @@ PluginConnector::~PluginConnector() { } -IMPL_LINK( PluginConnector, WorkOnNewMessageHdl, Mediator*, /*pMediator*/ ) +IMPL_LINK_NOARG_TYPED( PluginConnector, WorkOnNewMessageHdl, void*, void ) { MediatorMessage* pMessage; CommandAtoms nCommand; @@ -928,7 +928,6 @@ IMPL_LINK( PluginConnector, WorkOnNewMessageHdl, Mediator*, /*pMediator*/ ) } delete pMessage; } - return 0; } void LoadAdditionalLibs( const char* _pPluginLib ) diff --git a/extensions/source/plugin/unx/nppapi.cxx b/extensions/source/plugin/unx/nppapi.cxx index e55b14b3d35c..e89ded2a74ca 100644 --- a/extensions/source/plugin/unx/nppapi.cxx +++ b/extensions/source/plugin/unx/nppapi.cxx @@ -80,7 +80,7 @@ IMPL_LINK( PluginConnector, NewMessageHdl, Mediator*, /*pMediator*/ ) return 0; } -IMPL_LINK( PluginConnector, WorkOnNewMessageHdl, Mediator*, /*pMediator*/ ) +IMPL_LINK_NOARG_TYPED( PluginConnector, WorkOnNewMessageHdl, void*, void ) { bool bFound = false; for( std::vector< PluginConnector* >::iterator it = allConnectors.begin(); @@ -90,7 +90,7 @@ IMPL_LINK( PluginConnector, WorkOnNewMessageHdl, Mediator*, /*pMediator*/ ) bFound = true; } if( ! bFound ) - return 0; + return; MediatorMessage* pMessage; CommandAtoms nCommand; @@ -323,7 +323,6 @@ IMPL_LINK( PluginConnector, WorkOnNewMessageHdl, Mediator*, /*pMediator*/ ) delete pMessage; } - return 0; } #define GET_INSTANCE() \ |