diff options
author | Noel <noel.grandin@collabora.co.uk> | 2021-03-08 21:37:43 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-03-11 14:10:30 +0100 |
commit | 1692998399eecb79e7b59456cff805bcb77aece4 (patch) | |
tree | 8cc22c633e88f19c39f5736e87a0934f041729de /framework/source/uielement/generictoolbarcontroller.cxx | |
parent | 665a2b477dd4f412b42ffb58a183f7a702cd7645 (diff) |
use strong_int for item ids in vcl::ToolBox
(*) fix bug in SfxToolBoxControl::StateChanged where it was using the slot id
instead of the toolbox item id
(*) I left the logic in SbaTableQueryBrowser alone, but it looks suspicious,
casting slot ids to toolbox ids
Change-Id: Ied229164c27fb4456b0515c6fdcbd1682766a1a9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112186
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'framework/source/uielement/generictoolbarcontroller.cxx')
-rw-r--r-- | framework/source/uielement/generictoolbarcontroller.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/framework/source/uielement/generictoolbarcontroller.cxx b/framework/source/uielement/generictoolbarcontroller.cxx index 31c22d03bbb1..004fcf80ce78 100644 --- a/framework/source/uielement/generictoolbarcontroller.cxx +++ b/framework/source/uielement/generictoolbarcontroller.cxx @@ -82,7 +82,7 @@ static OUString getMasterCommand( const OUString& rCommand ) GenericToolbarController::GenericToolbarController( const Reference< XComponentContext >& rxContext, const Reference< XFrame >& rFrame, ToolBox* pToolbar, - sal_uInt16 nID, + ToolBoxItemId nID, const OUString& aCommand ) : svt::ToolboxController( rxContext, rFrame, aCommand ) , m_xToolbar( pToolbar ) @@ -104,7 +104,7 @@ GenericToolbarController::GenericToolbarController( const Reference< XComponentC const Reference< XFrame >& rFrame, weld::Toolbar& rToolbar, const OUString& aCommand ) : - GenericToolbarController( rxContext, rFrame, nullptr, 0, aCommand ) + GenericToolbarController( rxContext, rFrame, nullptr, ToolBoxItemId(0), aCommand ) { m_pToolbar = &rToolbar; } @@ -121,7 +121,7 @@ void SAL_CALL GenericToolbarController::dispose() m_pToolbar = nullptr; m_xToolbar.clear(); - m_nID = 0; + m_nID = ToolBoxItemId(0); } void SAL_CALL GenericToolbarController::execute( sal_Int16 KeyModifier ) |