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 /framework | |
parent | Revert "Simplify MultiAtomProvider::getString" (diff) | |
download | core-bd8b93fdff93ff7b2b7e493a7bcef6a59f299dae.tar.gz core-bd8b93fdff93ff7b2b7e493a7bcef6a59f299dae.zip |
make PostUserEvent Link<> typed
Change-Id: I13f10bda985d55d419a5bff481130a456ae2db8a
Diffstat (limited to 'framework')
14 files changed, 25 insertions, 28 deletions
diff --git a/framework/inc/services/layoutmanager.hxx b/framework/inc/services/layoutmanager.hxx index d1e042d956bb..c8b4e7c37a91 100644 --- a/framework/inc/services/layoutmanager.hxx +++ b/framework/inc/services/layoutmanager.hxx @@ -168,7 +168,7 @@ namespace framework virtual void SAL_CALL addLayoutManagerEventListener( const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XLayoutManagerListener >& aLayoutManagerListener ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual void SAL_CALL removeLayoutManagerEventListener( const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XLayoutManagerListener >& aLayoutManagerListener ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; - DECL_LINK(MenuBarClose, void *); + DECL_LINK_TYPED( MenuBarClose, void *, void); DECL_LINK( WindowEventListener, VclSimpleEvent* ); // ILayoutNotifications diff --git a/framework/inc/uielement/complextoolbarcontroller.hxx b/framework/inc/uielement/complextoolbarcontroller.hxx index b24186f644bf..bf9b7cf81611 100644 --- a/framework/inc/uielement/complextoolbarcontroller.hxx +++ b/framework/inc/uielement/complextoolbarcontroller.hxx @@ -71,8 +71,8 @@ class ComplexToolbarController : public svt::ToolboxController // XStatusListener virtual void SAL_CALL statusChanged( const ::com::sun::star::frame::FeatureStateEvent& Event ) throw ( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE; - DECL_STATIC_LINK( ComplexToolbarController, ExecuteHdl_Impl, ExecuteInfo* ); - DECL_STATIC_LINK( ComplexToolbarController, Notify_Impl, NotifyInfo* ); + DECL_STATIC_LINK_TYPED( ComplexToolbarController, ExecuteHdl_Impl, void*, void ); + DECL_STATIC_LINK_TYPED( ComplexToolbarController, Notify_Impl, void*, void); protected: static sal_Int32 getFontSizePixel( const vcl::Window* pWindow ); diff --git a/framework/inc/uielement/generictoolbarcontroller.hxx b/framework/inc/uielement/generictoolbarcontroller.hxx index 26ebeb61ab46..cfef97d562fe 100644 --- a/framework/inc/uielement/generictoolbarcontroller.hxx +++ b/framework/inc/uielement/generictoolbarcontroller.hxx @@ -51,7 +51,7 @@ class GenericToolbarController : public svt::ToolboxController // XStatusListener virtual void SAL_CALL statusChanged( const ::com::sun::star::frame::FeatureStateEvent& Event ) throw ( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE; - DECL_STATIC_LINK( GenericToolbarController, ExecuteHdl_Impl, ExecuteInfo* ); + DECL_STATIC_LINK_TYPED( GenericToolbarController, ExecuteHdl_Impl, void*, void ); protected: VclPtr<ToolBox> m_pToolbar; diff --git a/framework/inc/uielement/newmenucontroller.hxx b/framework/inc/uielement/newmenucontroller.hxx index a86d5ad97e9f..3243278d0dda 100644 --- a/framework/inc/uielement/newmenucontroller.hxx +++ b/framework/inc/uielement/newmenucontroller.hxx @@ -77,7 +77,7 @@ namespace framework // XEventListener virtual void SAL_CALL disposing( const com::sun::star::lang::EventObject& Source ) throw ( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE; - DECL_STATIC_LINK( NewMenuController, ExecuteHdl_Impl, NewDocument* ); + DECL_STATIC_LINK_TYPED( NewMenuController, ExecuteHdl_Impl, void*, void ); private: virtual void impl_setPopupMenu() SAL_OVERRIDE; diff --git a/framework/inc/uielement/toolbarmanager.hxx b/framework/inc/uielement/toolbarmanager.hxx index 9a43da9b143c..5cf00f7290fe 100644 --- a/framework/inc/uielement/toolbarmanager.hxx +++ b/framework/inc/uielement/toolbarmanager.hxx @@ -140,7 +140,7 @@ class ToolBarManager : public ToolbarManager_Base DECL_LINK( MenuSelect, Menu * ); DECL_LINK_TYPED( MenuDeactivate, Menu *, bool ); DECL_LINK_TYPED(AsyncUpdateControllersHdl, Timer *, void); - DECL_STATIC_LINK( ToolBarManager, ExecuteHdl_Impl, ExecuteInfo* ); + DECL_STATIC_LINK_TYPED( ToolBarManager, ExecuteHdl_Impl, void*, void ); virtual bool MenuItemAllowed( sal_uInt16 ) const; diff --git a/framework/inc/uielement/toolbarsmenucontroller.hxx b/framework/inc/uielement/toolbarsmenucontroller.hxx index 41eb059f376c..3cc2c26ca660 100644 --- a/framework/inc/uielement/toolbarsmenucontroller.hxx +++ b/framework/inc/uielement/toolbarsmenucontroller.hxx @@ -80,7 +80,7 @@ namespace framework ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue > aArgs; }; - DECL_STATIC_LINK( ToolbarsMenuController, ExecuteHdl_Impl, ExecuteInfo* ); + DECL_STATIC_LINK_TYPED( ToolbarsMenuController, ExecuteHdl_Impl, void*, void ); private: void fillPopupMenu( com::sun::star::uno::Reference< com::sun::star::awt::XPopupMenu >& rPopupMenu ); diff --git a/framework/source/fwe/classes/addonsoptions.cxx b/framework/source/fwe/classes/addonsoptions.cxx index 743e45bdd65e..1f3b074e0b07 100644 --- a/framework/source/fwe/classes/addonsoptions.cxx +++ b/framework/source/fwe/classes/addonsoptions.cxx @@ -1651,11 +1651,10 @@ Mutex& AddonsOptions::GetOwnStaticMutex() return *pMutex; } -IMPL_STATIC_LINK_NOARG( AddonsOptions, Notify ) +IMPL_STATIC_LINK_NOARG_TYPED( AddonsOptions, Notify, void*, void ) { MutexGuard aGuard( GetOwnStaticMutex() ); m_pDataContainer->ReadConfigurationData(); - return 0; } } diff --git a/framework/source/layoutmanager/layoutmanager.cxx b/framework/source/layoutmanager/layoutmanager.cxx index 2cf7fb05f1e0..f27f528dd454 100644 --- a/framework/source/layoutmanager/layoutmanager.cxx +++ b/framework/source/layoutmanager/layoutmanager.cxx @@ -2595,7 +2595,7 @@ bool LayoutManager::implts_resetMenuBar() return false; } -IMPL_LINK_NOARG(LayoutManager, MenuBarClose) +IMPL_LINK_NOARG_TYPED(LayoutManager, MenuBarClose, void*, void) { SolarMutexClearableGuard aReadLock; uno::Reference< frame::XDispatchProvider > xProvider(m_xFrame, uno::UNO_QUERY); @@ -2603,7 +2603,7 @@ IMPL_LINK_NOARG(LayoutManager, MenuBarClose) aReadLock.clear(); if ( !xProvider.is()) - return 0; + return; uno::Reference< frame::XDispatchHelper > xDispatcher = frame::DispatchHelper::create( xContext ); @@ -2613,8 +2613,6 @@ IMPL_LINK_NOARG(LayoutManager, MenuBarClose) OUString("_self"), 0, uno::Sequence< beans::PropertyValue >()); - - return 0; } // XLayoutManagerEventBroadcaster diff --git a/framework/source/uielement/complextoolbarcontroller.cxx b/framework/source/uielement/complextoolbarcontroller.cxx index 8542eb626bfb..5ac9a3a1a59f 100644 --- a/framework/source/uielement/complextoolbarcontroller.cxx +++ b/framework/source/uielement/complextoolbarcontroller.cxx @@ -196,8 +196,9 @@ throw ( RuntimeException, std::exception ) } } -IMPL_STATIC_LINK( ComplexToolbarController, ExecuteHdl_Impl, ExecuteInfo*, pExecuteInfo ) +IMPL_STATIC_LINK_TYPED( ComplexToolbarController, ExecuteHdl_Impl, void*, p, void ) { + ExecuteInfo* pExecuteInfo = static_cast<ExecuteInfo*>(p); SolarMutexReleaser aReleaser; try { @@ -211,11 +212,11 @@ IMPL_STATIC_LINK( ComplexToolbarController, ExecuteHdl_Impl, ExecuteInfo*, pExec } delete pExecuteInfo; - return 0; } -IMPL_STATIC_LINK( ComplexToolbarController, Notify_Impl, NotifyInfo*, pNotifyInfo ) +IMPL_STATIC_LINK_TYPED( ComplexToolbarController, Notify_Impl, void*, p, void ) { + NotifyInfo* pNotifyInfo = static_cast<NotifyInfo*>(p); SolarMutexReleaser aReleaser; try { @@ -233,7 +234,6 @@ IMPL_STATIC_LINK( ComplexToolbarController, Notify_Impl, NotifyInfo*, pNotifyInf } delete pNotifyInfo; - return 0; } void ComplexToolbarController::addNotifyInfo( diff --git a/framework/source/uielement/generictoolbarcontroller.cxx b/framework/source/uielement/generictoolbarcontroller.cxx index 8c578e257cfc..bb599ab771b9 100644 --- a/framework/source/uielement/generictoolbarcontroller.cxx +++ b/framework/source/uielement/generictoolbarcontroller.cxx @@ -269,8 +269,9 @@ throw ( RuntimeException, std::exception ) } } -IMPL_STATIC_LINK( GenericToolbarController, ExecuteHdl_Impl, ExecuteInfo*, pExecuteInfo ) +IMPL_STATIC_LINK_TYPED( GenericToolbarController, ExecuteHdl_Impl, void*, p, void ) { + ExecuteInfo* pExecuteInfo = static_cast<ExecuteInfo*>(p); SolarMutexReleaser aReleaser; try { @@ -284,7 +285,6 @@ IMPL_STATIC_LINK( GenericToolbarController, ExecuteHdl_Impl, ExecuteInfo*, pExec } delete pExecuteInfo; - return 0; } MenuToolbarController::MenuToolbarController( const Reference< XComponentContext >& rxContext, diff --git a/framework/source/uielement/newmenucontroller.cxx b/framework/source/uielement/newmenucontroller.cxx index 5cc190e9a0c8..384c3e1e0a5f 100644 --- a/framework/source/uielement/newmenucontroller.cxx +++ b/framework/source/uielement/newmenucontroller.cxx @@ -522,8 +522,9 @@ void SAL_CALL NewMenuController::initialize( const Sequence< Any >& aArguments ) } } -IMPL_STATIC_LINK( NewMenuController, ExecuteHdl_Impl, NewDocument*, pNewDocument ) +IMPL_STATIC_LINK_TYPED( NewMenuController, ExecuteHdl_Impl, void*, p, void ) { + NewDocument* pNewDocument = static_cast<NewDocument*>(p); /* i62706: Don't catch all exceptions. We hide all problems here and are not able to handle them on higher levels. try @@ -534,7 +535,6 @@ IMPL_STATIC_LINK( NewMenuController, ExecuteHdl_Impl, NewDocument*, pNewDocument // elements if a component gets detached from its frame! pNewDocument->xDispatch->dispatch( pNewDocument->aTargetURL, pNewDocument->aArgSeq ); delete pNewDocument; - return 0; } } diff --git a/framework/source/uielement/recentfilesmenucontroller.cxx b/framework/source/uielement/recentfilesmenucontroller.cxx index 1863251e5261..c21cb351e2cb 100644 --- a/framework/source/uielement/recentfilesmenucontroller.cxx +++ b/framework/source/uielement/recentfilesmenucontroller.cxx @@ -100,7 +100,7 @@ public: // XEventListener virtual void SAL_CALL disposing( const com::sun::star::lang::EventObject& Source ) throw ( uno::RuntimeException, std::exception ) SAL_OVERRIDE; - DECL_STATIC_LINK( RecentFilesMenuController, ExecuteHdl_Impl, LoadRecentFile* ); + DECL_STATIC_LINK_TYPED( RecentFilesMenuController, ExecuteHdl_Impl, void*, void ); private: virtual void impl_setPopupMenu() SAL_OVERRIDE; @@ -439,8 +439,9 @@ throw( RuntimeException, std::exception ) } } -IMPL_STATIC_LINK( RecentFilesMenuController, ExecuteHdl_Impl, LoadRecentFile*, pLoadRecentFile ) +IMPL_STATIC_LINK_TYPED( RecentFilesMenuController, ExecuteHdl_Impl, void*, p, void ) { + LoadRecentFile* pLoadRecentFile = static_cast<LoadRecentFile*>(p); try { // Asynchronous execution as this can lead to our own destruction! @@ -453,7 +454,6 @@ IMPL_STATIC_LINK( RecentFilesMenuController, ExecuteHdl_Impl, LoadRecentFile*, p } delete pLoadRecentFile; - return 0; } } diff --git a/framework/source/uielement/toolbarmanager.cxx b/framework/source/uielement/toolbarmanager.cxx index 2c946aacbd8a..2224e5cbcf3c 100644 --- a/framework/source/uielement/toolbarmanager.cxx +++ b/framework/source/uielement/toolbarmanager.cxx @@ -2121,8 +2121,9 @@ IMPL_LINK_NOARG_TYPED(ToolBarManager, AsyncUpdateControllersHdl, Timer *, void) UpdateControllers(); } -IMPL_STATIC_LINK( ToolBarManager, ExecuteHdl_Impl, ExecuteInfo*, pExecuteInfo ) +IMPL_STATIC_LINK_TYPED( ToolBarManager, ExecuteHdl_Impl, void*, p, void ) { + ExecuteInfo* pExecuteInfo = static_cast<ExecuteInfo*>(p); try { // Asynchronous execution as this can lead to our own destruction! @@ -2158,7 +2159,6 @@ IMPL_STATIC_LINK( ToolBarManager, ExecuteHdl_Impl, ExecuteInfo*, pExecuteInfo ) } delete pExecuteInfo; - return 0; } Image ToolBarManager::QueryAddonsImage( const OUString& aCommandURL, bool bBigImages ) diff --git a/framework/source/uielement/toolbarsmenucontroller.cxx b/framework/source/uielement/toolbarsmenucontroller.cxx index 277469bc2646..6305cea7f3d7 100644 --- a/framework/source/uielement/toolbarsmenucontroller.cxx +++ b/framework/source/uielement/toolbarsmenucontroller.cxx @@ -851,8 +851,9 @@ void SAL_CALL ToolbarsMenuController::initialize( const Sequence< Any >& aArgume } } -IMPL_STATIC_LINK( ToolbarsMenuController, ExecuteHdl_Impl, ExecuteInfo*, pExecuteInfo ) +IMPL_STATIC_LINK_TYPED( ToolbarsMenuController, ExecuteHdl_Impl, void*, p, void ) { + ExecuteInfo* pExecuteInfo = static_cast<ExecuteInfo*>(p); try { // Asynchronous execution as this can lead to our own destruction! @@ -868,7 +869,6 @@ IMPL_STATIC_LINK( ToolbarsMenuController, ExecuteHdl_Impl, ExecuteInfo*, pExecut } delete pExecuteInfo; - return 0; } } |