[Libreoffice-commits] core.git: 2 commits - cui/source framework/inc framework/source include/sfx2 include/vcl sfx2/source sw/source
Stephan Bergmann
sbergman at redhat.com
Thu May 7 22:50:37 PDT 2015
cui/source/inc/numpages.hxx | 2 +-
cui/source/tabpages/numpages.cxx | 4 ++--
framework/inc/classes/menumanager.hxx | 6 +++---
framework/inc/uielement/menubarmanager.hxx | 6 +++---
framework/inc/uielement/toolbarmanager.hxx | 2 +-
framework/source/classes/menumanager.cxx | 16 ++++++++--------
framework/source/uielement/menubarmanager.cxx | 14 +++++++-------
framework/source/uielement/toolbarmanager.cxx | 10 +++++-----
include/sfx2/mnuitem.hxx | 2 +-
include/vcl/menu.hxx | 15 ++++++---------
sfx2/source/inc/virtmenu.hxx | 6 +++---
sfx2/source/menu/mnuitem.cxx | 6 +++---
sfx2/source/menu/virtmenu.cxx | 16 ++++++++--------
sw/source/ui/index/cnttab.cxx | 4 ++--
sw/source/ui/misc/glossary.cxx | 4 ++--
sw/source/uibase/docvw/PageBreakWin.cxx | 4 ++--
sw/source/uibase/inc/PageBreakWin.hxx | 2 +-
sw/source/uibase/inc/glossary.hxx | 2 +-
sw/source/uibase/inc/swuicnttab.hxx | 2 +-
19 files changed, 60 insertions(+), 63 deletions(-)
New commits:
commit fc4726a1f41ded40ce7d7100350c322863646b37
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Fri May 8 07:49:35 2015 +0200
Use typed Menu::Set[De]actuivateHdl Links
Change-Id: I6736383ad0ec5c9f2ea2281bfdcfa280cd712032
diff --git a/framework/inc/classes/menumanager.hxx b/framework/inc/classes/menumanager.hxx
index 92dc2d6..4c471a2 100644
--- a/framework/inc/classes/menumanager.hxx
+++ b/framework/inc/classes/menumanager.hxx
@@ -76,8 +76,8 @@ class MenuManager : public ::cppu::WeakImplHelper1< css::frame::XStatusListener
protected:
DECL_LINK_TYPED(Highlight, Menu *, bool);
- DECL_LINK( Activate, Menu * );
- DECL_LINK( Deactivate, Menu * );
+ DECL_LINK_TYPED( Activate, Menu *, bool );
+ DECL_LINK_TYPED( Deactivate, Menu *, bool );
private:
void UpdateSpecialFileMenu( Menu* pMenu );
diff --git a/framework/inc/uielement/menubarmanager.hxx b/framework/inc/uielement/menubarmanager.hxx
index 23cd41d..b72d515 100644
--- a/framework/inc/uielement/menubarmanager.hxx
+++ b/framework/inc/uielement/menubarmanager.hxx
@@ -152,8 +152,8 @@ class MenuBarManager : public com::sun::star::frame::XStatusListener
protected:
DECL_LINK_TYPED(Highlight, Menu *, bool);
- DECL_LINK( Activate, Menu * );
- DECL_LINK( Deactivate, Menu * );
+ DECL_LINK_TYPED( Activate, Menu *, bool );
+ DECL_LINK_TYPED( Deactivate, Menu *, bool );
DECL_LINK_TYPED( AsyncSettingsHdl, Timer *, void );
void RemoveListener();
diff --git a/framework/inc/uielement/toolbarmanager.hxx b/framework/inc/uielement/toolbarmanager.hxx
index 3acc8c6..78fb5a0 100644
--- a/framework/inc/uielement/toolbarmanager.hxx
+++ b/framework/inc/uielement/toolbarmanager.hxx
@@ -140,7 +140,7 @@ class ToolBarManager : public ToolbarManager_Base
DECL_LINK_TYPED( MenuButton, ToolBox *, void );
DECL_LINK( MenuSelect, Menu * );
- DECL_LINK( MenuDeactivate, Menu * );
+ DECL_LINK_TYPED( MenuDeactivate, Menu *, bool );
DECL_LINK_TYPED(AsyncUpdateControllersHdl, Timer *, void);
DECL_STATIC_LINK( ToolBarManager, ExecuteHdl_Impl, ExecuteInfo* );
diff --git a/framework/source/classes/menumanager.cxx b/framework/source/classes/menumanager.cxx
index 761d903..e2e1827 100644
--- a/framework/source/classes/menumanager.cxx
+++ b/framework/source/classes/menumanager.cxx
@@ -709,7 +709,7 @@ void MenuManager::CreatePicklistArguments( Sequence< PropertyValue >& aArgsList,
// vcl handler
-IMPL_LINK( MenuManager, Activate, Menu *, pMenu )
+IMPL_LINK_TYPED( MenuManager, Activate, Menu *, pMenu, bool )
{
if ( pMenu == m_pVCLMenu )
{
@@ -726,7 +726,7 @@ IMPL_LINK( MenuManager, Activate, Menu *, pMenu )
pMenu->SetMenuFlags( nFlag );
if ( m_bActive )
- return 0;
+ return false;
m_bActive = true;
@@ -751,7 +751,7 @@ IMPL_LINK( MenuManager, Activate, Menu *, pMenu )
}
if ( m_bInitialized )
- return 0;
+ return false;
else
{
URL aTargetURL;
@@ -806,15 +806,15 @@ IMPL_LINK( MenuManager, Activate, Menu *, pMenu )
}
}
- return 1;
+ return true;
}
-IMPL_LINK( MenuManager, Deactivate, Menu *, pMenu )
+IMPL_LINK_TYPED( MenuManager, Deactivate, Menu *, pMenu, bool )
{
if ( pMenu == m_pVCLMenu )
m_bActive = false;
- return 1;
+ return true;
}
IMPL_LINK( MenuManager, Select, Menu *, pMenu )
diff --git a/framework/source/uielement/menubarmanager.cxx b/framework/source/uielement/menubarmanager.cxx
index 785080c..7cb3b90 100644
--- a/framework/source/uielement/menubarmanager.cxx
+++ b/framework/source/uielement/menubarmanager.cxx
@@ -723,7 +723,7 @@ private:
}
-IMPL_LINK( MenuBarManager, Activate, Menu *, pMenu )
+IMPL_LINK_TYPED( MenuBarManager, Activate, Menu *, pMenu, bool )
{
if ( pMenu == m_pVCLMenu )
{
@@ -747,7 +747,7 @@ IMPL_LINK( MenuBarManager, Activate, Menu *, pMenu )
pMenu->SetMenuFlags( nFlag );
if ( m_bActive )
- return 0;
+ return false;
m_bActive = true;
@@ -917,10 +917,10 @@ IMPL_LINK( MenuBarManager, Activate, Menu *, pMenu )
}
}
- return 1;
+ return true;
}
-IMPL_LINK( MenuBarManager, Deactivate, Menu *, pMenu )
+IMPL_LINK_TYPED( MenuBarManager, Deactivate, Menu *, pMenu, bool )
{
if ( pMenu == m_pVCLMenu )
{
@@ -936,7 +936,7 @@ IMPL_LINK( MenuBarManager, Deactivate, Menu *, pMenu )
}
}
- return 1;
+ return true;
}
IMPL_LINK_NOARG_TYPED( MenuBarManager, AsyncSettingsHdl, Timer*, void)
diff --git a/framework/source/uielement/toolbarmanager.cxx b/framework/source/uielement/toolbarmanager.cxx
index d175b6e..0c0eb43 100644
--- a/framework/source/uielement/toolbarmanager.cxx
+++ b/framework/source/uielement/toolbarmanager.cxx
@@ -1606,19 +1606,19 @@ void ToolBarManager::ImplClearPopupMenu( ToolBox *pToolBar )
}
}
-IMPL_LINK( ToolBarManager, MenuDeactivate, Menu*, pMenu )
+IMPL_LINK_TYPED( ToolBarManager, MenuDeactivate, Menu*, pMenu, bool )
{
SolarMutexGuard g;
if ( m_bDisposed )
- return 1;
+ return true;
if( pMenu != m_pToolBar->GetMenu() )
- return 1;
+ return true;
ImplClearPopupMenu( m_pToolBar );
- return 0;
+ return false;
}
Reference< XModel > ToolBarManager::GetModelFromFrame() const
@@ -1806,7 +1806,7 @@ IMPL_LINK_TYPED( ToolBarManager, Command, CommandEvent const *, pCmdEvt, void )
{
// Unlink our listeners again -- see above for why.
pManagerMenu->SetSelectHdl( Link<>() );
- pManagerMenu->SetDeactivateHdl( Link<>() );
+ pManagerMenu->SetDeactivateHdl( Link<Menu *, bool>() );
}
}
}
diff --git a/include/sfx2/mnuitem.hxx b/include/sfx2/mnuitem.hxx
index 98f0cc1..0d40854 100644
--- a/include/sfx2/mnuitem.hxx
+++ b/include/sfx2/mnuitem.hxx
@@ -127,7 +127,7 @@ class SfxAppMenuControl_Impl : public SfxMenuControl
bool m_bShowMenuImages;
protected:
- DECL_LINK( Activate, Menu * ); // Needed to support high contrast images
+ DECL_LINK_TYPED( Activate, Menu *, bool ); // Needed to support high contrast images
public:
SfxAppMenuControl_Impl( sal_uInt16 nPos, Menu& rMenu, SfxBindings& rBindings );
diff --git a/include/vcl/menu.hxx b/include/vcl/menu.hxx
index 352efaf..7c570f0 100644
--- a/include/vcl/menu.hxx
+++ b/include/vcl/menu.hxx
@@ -126,8 +126,8 @@ private:
Menu* pStartedFrom;
VclPtr<vcl::Window> pWindow;
- Link<> aActivateHdl; // Active-Handler
- Link<> aDeactivateHdl; // Deactivate-Handler
+ Link<Menu *, bool> aActivateHdl; // Active-Handler
+ Link<Menu *, bool> aDeactivateHdl; // Deactivate-Handler
Link<Menu *, bool> aHighlightHdl; // Highlight-Handler
Link<> aSelectHdl; // Highlight-Handler
@@ -320,11 +320,9 @@ public:
void SetHelpId( sal_uInt16 nItemId, const OString& rHelpId );
OString GetHelpId( sal_uInt16 nItemId ) const;
- void SetActivateHdl( const Link<>& rLink ) { aActivateHdl = rLink; }
- const Link<>& GetActivateHdl() const { return aActivateHdl; }
+ void SetActivateHdl( const Link<Menu *, bool>& rLink ) { aActivateHdl = rLink; }
- void SetDeactivateHdl( const Link<>& rLink ) { aDeactivateHdl = rLink; }
- const Link<>& GetDeactivateHdl() const { return aDeactivateHdl; }
+ void SetDeactivateHdl( const Link<Menu *, bool>& rLink ) { aDeactivateHdl = rLink; }
void SetHighlightHdl( const Link<Menu *, bool>& rLink ) { aHighlightHdl = rLink; }
diff --git a/sfx2/source/inc/virtmenu.hxx b/sfx2/source/inc/virtmenu.hxx
index 0bf8dc7..48b5064 100644
--- a/sfx2/source/inc/virtmenu.hxx
+++ b/sfx2/source/inc/virtmenu.hxx
@@ -70,8 +70,8 @@ protected:
void CreateFromSVMenu();
DECL_LINK_TYPED( Highlight, Menu *, bool );
- DECL_LINK( Activate, Menu * );
- DECL_LINK( Deactivate, Menu * );
+ DECL_LINK_TYPED( Activate, Menu *, bool );
+ DECL_LINK_TYPED( Deactivate, Menu *, bool );
DECL_LINK( SettingsChanged, void* );
// Used for runtime popup menus
diff --git a/sfx2/source/menu/mnuitem.cxx b/sfx2/source/menu/mnuitem.cxx
index 61cf004..0866ef8 100644
--- a/sfx2/source/menu/mnuitem.cxx
+++ b/sfx2/source/menu/mnuitem.cxx
@@ -326,7 +326,7 @@ SfxAppMenuControl_Impl::~SfxAppMenuControl_Impl()
delete pMenu;
}
-IMPL_LINK( SfxAppMenuControl_Impl, Activate, Menu *, pActMenu )
+IMPL_LINK_TYPED( SfxAppMenuControl_Impl, Activate, Menu *, pActMenu, bool )
{
if ( pActMenu )
{
@@ -382,10 +382,10 @@ IMPL_LINK( SfxAppMenuControl_Impl, Activate, Menu *, pActMenu )
}
}
- return sal_True;
+ return true;
}
- return sal_False;
+ return false;
}
SfxUnoMenuControl* SfxMenuControl::CreateControl( const OUString& rCmd,
diff --git a/sfx2/source/menu/virtmenu.cxx b/sfx2/source/menu/virtmenu.cxx
index dd0682a..36ff55a 100644
--- a/sfx2/source/menu/virtmenu.cxx
+++ b/sfx2/source/menu/virtmenu.cxx
@@ -775,7 +775,7 @@ void SfxVirtualMenu::InsertAddOnsMenuItem( Menu* pMenu )
// called on activation of the SV-Menu
-IMPL_LINK( SfxVirtualMenu, Activate, Menu *, pMenu )
+IMPL_LINK_TYPED( SfxVirtualMenu, Activate, Menu *, pMenu, bool )
{
SAL_INFO(
"sfx",
@@ -801,7 +801,7 @@ IMPL_LINK( SfxVirtualMenu, Activate, Menu *, pMenu )
{
// Prevent Double Activate
if ( bIsActive )
- return sal_True;
+ return true;
// ggf. Pick-Menu erzeugen
if ( pParent && pSVMenu == pParent->pPickMenu )
@@ -894,7 +894,7 @@ IMPL_LINK( SfxVirtualMenu, Activate, Menu *, pMenu )
// Suppress the Status updates until Deactivate
pBindings->ENTERREGISTRATIONS(); ++nLocks; bIsActive = true;
- return sal_True;
+ return true;
}
else
{
@@ -905,13 +905,13 @@ IMPL_LINK( SfxVirtualMenu, Activate, Menu *, pMenu )
if ( !bRet)
DBG_WARNING( "W1: Virtual menu could not be created!" );
#endif
- return long(bRet);
+ return bRet;
}
}
-IMPL_LINK( SfxVirtualMenu, Deactivate, Menu *, pMenu )
+IMPL_LINK_TYPED( SfxVirtualMenu, Deactivate, Menu *, pMenu, bool )
{
SAL_INFO(
"sfx",
@@ -925,7 +925,7 @@ IMPL_LINK( SfxVirtualMenu, Deactivate, Menu *, pMenu )
UnbindControllers();
pBindings->LEAVEREGISTRATIONS(); --nLocks; bIsActive = false;
}
- return sal_True;
+ return true;
}
diff --git a/sw/source/ui/index/cnttab.cxx b/sw/source/ui/index/cnttab.cxx
index fefe6b9..9bdf2e1 100644
--- a/sw/source/ui/index/cnttab.cxx
+++ b/sw/source/ui/index/cnttab.cxx
@@ -1487,10 +1487,10 @@ IMPL_LINK(SwTOXSelectTabPage, AddStylesHdl, PushButton*, pButton)
return 0;
}
-IMPL_LINK(SwTOXSelectTabPage, MenuEnableHdl, Menu*, pMenu)
+IMPL_LINK_TYPED(SwTOXSelectTabPage, MenuEnableHdl, Menu*, pMenu, bool)
{
pMenu->EnableItem("edit", !sAutoMarkURL.isEmpty());
- return 0;
+ return false;
}
IMPL_LINK(SwTOXSelectTabPage, MenuExecuteHdl, Menu*, pMenu)
diff --git a/sw/source/ui/misc/glossary.cxx b/sw/source/ui/misc/glossary.cxx
index c8d4f07..1f7a6ff 100644
--- a/sw/source/ui/misc/glossary.cxx
+++ b/sw/source/ui/misc/glossary.cxx
@@ -418,7 +418,7 @@ IMPL_LINK( SwGlossaryDlg, NameDoubleClick, SvTreeListBox*, pBox )
return 0;
}
-IMPL_LINK( SwGlossaryDlg, EnableHdl, Menu *, pMn )
+IMPL_LINK_TYPED( SwGlossaryDlg, EnableHdl, Menu *, pMn, bool )
{
SvTreeListEntry* pEntry = m_pCategoryBox->FirstSelected();
@@ -437,7 +437,7 @@ IMPL_LINK( SwGlossaryDlg, EnableHdl, Menu *, pMn )
pMn->EnableItem("macro", bExists && !bIsGroup && !bIsOld &&
!pGlossaryHdl->IsReadOnly() );
pMn->EnableItem("import", bIsGroup && !bIsOld && !pGlossaryHdl->IsReadOnly() );
- return 1;
+ return true;
}
IMPL_LINK( SwGlossaryDlg, MenuHdl, Menu *, pMn )
diff --git a/sw/source/uibase/docvw/PageBreakWin.cxx b/sw/source/uibase/docvw/PageBreakWin.cxx
index 0840c82..226d46d 100644
--- a/sw/source/uibase/docvw/PageBreakWin.cxx
+++ b/sw/source/uibase/docvw/PageBreakWin.cxx
@@ -434,11 +434,11 @@ void SwPageBreakWin::Fade( bool bFadeIn )
m_aFadeTimer.Start( );
}
-IMPL_LINK_NOARG(SwPageBreakWin, HideHandler)
+IMPL_LINK_NOARG_TYPED(SwPageBreakWin, HideHandler, Menu *, bool)
{
Fade( false );
- return 0;
+ return false;
}
IMPL_LINK_NOARG_TYPED(SwPageBreakWin, FadeHandler, Timer *, void)
diff --git a/sw/source/uibase/inc/PageBreakWin.hxx b/sw/source/uibase/inc/PageBreakWin.hxx
index d2c165e..6efb632 100644
--- a/sw/source/uibase/inc/PageBreakWin.hxx
+++ b/sw/source/uibase/inc/PageBreakWin.hxx
@@ -55,7 +55,7 @@ public:
private:
/// Hide the button (used when the popup menu is closed by clicking outside)
- DECL_LINK( HideHandler, void * );
+ DECL_LINK_TYPED( HideHandler, Menu *, bool );
DECL_LINK_TYPED( FadeHandler, Timer *, void );
};
diff --git a/sw/source/uibase/inc/glossary.hxx b/sw/source/uibase/inc/glossary.hxx
index ca04532..56fd844 100644
--- a/sw/source/uibase/inc/glossary.hxx
+++ b/sw/source/uibase/inc/glossary.hxx
@@ -127,7 +127,7 @@ class SwGlossaryDlg : public SvxStandardDialog
DECL_LINK( NameDoubleClick, SvTreeListBox * );
DECL_LINK( GrpSelect, SvTreeListBox * );
DECL_LINK( MenuHdl, Menu * );
- DECL_LINK( EnableHdl, Menu * );
+ DECL_LINK_TYPED( EnableHdl, Menu *, bool );
DECL_LINK(BibHdl, void *);
DECL_LINK_TYPED(EditHdl, MenuButton *, void);
DECL_LINK(InsertHdl, void *);
diff --git a/sw/source/uibase/inc/swuicnttab.hxx b/sw/source/uibase/inc/swuicnttab.hxx
index 2f4da99..7a35d474 100644
--- a/sw/source/uibase/inc/swuicnttab.hxx
+++ b/sw/source/uibase/inc/swuicnttab.hxx
@@ -205,7 +205,7 @@ class SwTOXSelectTabPage : public SfxTabPage
DECL_LINK(TOXTypeHdl, ListBox* );
DECL_LINK(AddStylesHdl, PushButton* );
- DECL_LINK(MenuEnableHdl, Menu*);
+ DECL_LINK_TYPED(MenuEnableHdl, Menu*, bool);
DECL_LINK(MenuExecuteHdl, Menu*);
DECL_LINK(LanguageHdl, ListBox*);
commit 0c415f61e4d2fb4efc50fe0401376657af47d203
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Thu May 7 23:03:22 2015 +0200
Use typed Menu::SetHighlightHdl Link
Change-Id: I47a35813fddcb90497b621a96bafe74969dc90d0
diff --git a/cui/source/inc/numpages.hxx b/cui/source/inc/numpages.hxx
index e5fc99d..fdb7219 100644
--- a/cui/source/inc/numpages.hxx
+++ b/cui/source/inc/numpages.hxx
@@ -329,7 +329,7 @@ class SvxNumOptionsTabPage : public SfxTabPage
DECL_LINK( NumberTypeSelectHdl_Impl, ListBox * );
DECL_LINK( LevelHdl_Impl, ListBox * );
- DECL_LINK(PopupActivateHdl_Impl, void *);
+ DECL_LINK_TYPED(PopupActivateHdl_Impl, Menu *, bool);
DECL_LINK_TYPED( GraphicHdl_Impl, MenuButton *, void );
DECL_LINK(BulletHdl_Impl, void *);
DECL_LINK( SizeHdl_Impl, MetricField * );
diff --git a/cui/source/tabpages/numpages.cxx b/cui/source/tabpages/numpages.cxx
index 3ea60fc..fcb392b 100644
--- a/cui/source/tabpages/numpages.cxx
+++ b/cui/source/tabpages/numpages.cxx
@@ -2036,7 +2036,7 @@ IMPL_LINK_TYPED( SvxNumOptionsTabPage, GraphicHdl_Impl, MenuButton *, pButton, v
}
}
-IMPL_LINK_NOARG(SvxNumOptionsTabPage, PopupActivateHdl_Impl)
+IMPL_LINK_NOARG_TYPED(SvxNumOptionsTabPage, PopupActivateHdl_Impl, Menu *, bool)
{
if(!bMenuButtonInitialized)
{
@@ -2088,7 +2088,7 @@ IMPL_LINK_NOARG(SvxNumOptionsTabPage, PopupActivateHdl_Impl)
}
LeaveWait();
}
- return 0;
+ return false;
}
IMPL_LINK_NOARG(SvxNumOptionsTabPage, BulletHdl_Impl)
diff --git a/framework/inc/classes/menumanager.hxx b/framework/inc/classes/menumanager.hxx
index 5f23d3d..92dc2d6 100644
--- a/framework/inc/classes/menumanager.hxx
+++ b/framework/inc/classes/menumanager.hxx
@@ -75,7 +75,7 @@ class MenuManager : public ::cppu::WeakImplHelper1< css::frame::XStatusListener
);
protected:
- DECL_LINK(Highlight, void *);
+ DECL_LINK_TYPED(Highlight, Menu *, bool);
DECL_LINK( Activate, Menu * );
DECL_LINK( Deactivate, Menu * );
diff --git a/framework/inc/uielement/menubarmanager.hxx b/framework/inc/uielement/menubarmanager.hxx
index 6286150..23cd41d 100644
--- a/framework/inc/uielement/menubarmanager.hxx
+++ b/framework/inc/uielement/menubarmanager.hxx
@@ -151,7 +151,7 @@ class MenuBarManager : public com::sun::star::frame::XStatusListener
void GetPopupController( PopupControllerCache& rPopupController );
protected:
- DECL_LINK(Highlight, void *);
+ DECL_LINK_TYPED(Highlight, Menu *, bool);
DECL_LINK( Activate, Menu * );
DECL_LINK( Deactivate, Menu * );
DECL_LINK_TYPED( AsyncSettingsHdl, Timer *, void );
diff --git a/framework/source/classes/menumanager.cxx b/framework/source/classes/menumanager.cxx
index fdfef14..761d903 100644
--- a/framework/source/classes/menumanager.cxx
+++ b/framework/source/classes/menumanager.cxx
@@ -890,9 +890,9 @@ IMPL_LINK( MenuManager, Select, Menu *, pMenu )
return 1;
}
-IMPL_LINK_NOARG(MenuManager, Highlight)
+IMPL_LINK_NOARG_TYPED(MenuManager, Highlight, Menu *, bool)
{
- return 0;
+ return false;
}
void MenuManager::AddMenu(PopupMenu* _pPopupMenu,const OUString& _sItemCommand,sal_uInt16 _nItemId,bool _bDelete,bool _bDeleteChildren)
diff --git a/framework/source/uielement/menubarmanager.cxx b/framework/source/uielement/menubarmanager.cxx
index b06fa6a..785080c 100644
--- a/framework/source/uielement/menubarmanager.cxx
+++ b/framework/source/uielement/menubarmanager.cxx
@@ -1023,9 +1023,9 @@ IMPL_LINK( MenuBarManager, Select, Menu *, pMenu )
return 1;
}
-IMPL_LINK_NOARG(MenuBarManager, Highlight)
+IMPL_LINK_NOARG_TYPED(MenuBarManager, Highlight, Menu *, bool)
{
- return 0;
+ return false;
}
bool MenuBarManager::MustBeHidden( PopupMenu* pPopupMenu, const Reference< XURLTransformer >& rTransformer )
diff --git a/include/vcl/menu.hxx b/include/vcl/menu.hxx
index 2af6a53..352efaf 100644
--- a/include/vcl/menu.hxx
+++ b/include/vcl/menu.hxx
@@ -128,7 +128,7 @@ private:
Link<> aActivateHdl; // Active-Handler
Link<> aDeactivateHdl; // Deactivate-Handler
- Link<> aHighlightHdl; // Highlight-Handler
+ Link<Menu *, bool> aHighlightHdl; // Highlight-Handler
Link<> aSelectHdl; // Highlight-Handler
VclEventListeners maEventListeners;
@@ -326,8 +326,7 @@ public:
void SetDeactivateHdl( const Link<>& rLink ) { aDeactivateHdl = rLink; }
const Link<>& GetDeactivateHdl() const { return aDeactivateHdl; }
- void SetHighlightHdl( const Link<>& rLink ) { aHighlightHdl = rLink; }
- const Link<>& GetHighlightHdl() const { return aHighlightHdl; }
+ void SetHighlightHdl( const Link<Menu *, bool>& rLink ) { aHighlightHdl = rLink; }
void SetSelectHdl( const Link<>& rLink ) { aSelectHdl = rLink; }
const Link<>& GetSelectHdl() const { return aSelectHdl; }
diff --git a/sfx2/source/inc/virtmenu.hxx b/sfx2/source/inc/virtmenu.hxx
index bd52861..0bf8dc7 100644
--- a/sfx2/source/inc/virtmenu.hxx
+++ b/sfx2/source/inc/virtmenu.hxx
@@ -69,7 +69,7 @@ protected:
SfxBindings &rBind, bool bOLEServer=false, bool bRes=false, bool bIsAddonMenu=false );
void CreateFromSVMenu();
- DECL_LINK( Highlight, void * );
+ DECL_LINK_TYPED( Highlight, Menu *, bool );
DECL_LINK( Activate, Menu * );
DECL_LINK( Deactivate, Menu * );
DECL_LINK( SettingsChanged, void* );
diff --git a/sfx2/source/menu/virtmenu.cxx b/sfx2/source/menu/virtmenu.cxx
index c085e84..dd0682a 100644
--- a/sfx2/source/menu/virtmenu.cxx
+++ b/sfx2/source/menu/virtmenu.cxx
@@ -483,10 +483,10 @@ void SfxVirtualMenu::CreateFromSVMenu()
// called on activation of the SV-Menu
-IMPL_LINK_NOARG( SfxVirtualMenu, Highlight )
+IMPL_LINK_NOARG_TYPED( SfxVirtualMenu, Highlight, Menu *, bool )
{
- return sal_True;
+ return true;
}
IMPL_LINK_NOARG(SfxVirtualMenu, SettingsChanged)
More information about the Libreoffice-commits
mailing list