summaryrefslogtreecommitdiff
path: root/framework/source
diff options
context:
space:
mode:
Diffstat (limited to 'framework/source')
-rw-r--r--framework/source/layoutmanager/layoutmanager.cxx9
-rw-r--r--framework/source/layoutmanager/toolbarlayoutmanager.cxx14
-rw-r--r--framework/source/layoutmanager/toolbarlayoutmanager.hxx2
3 files changed, 24 insertions, 1 deletions
diff --git a/framework/source/layoutmanager/layoutmanager.cxx b/framework/source/layoutmanager/layoutmanager.cxx
index ec6ed5572d94..652521fdf6aa 100644
--- a/framework/source/layoutmanager/layoutmanager.cxx
+++ b/framework/source/layoutmanager/layoutmanager.cxx
@@ -130,6 +130,7 @@ LayoutManager::LayoutManager( const Reference< XComponentContext >& xContext ) :
registerProperty( LAYOUTMANAGER_PROPNAME_MENUBARCLOSER, LAYOUTMANAGER_PROPHANDLE_MENUBARCLOSER, beans::PropertyAttribute::TRANSIENT, &m_bMenuBarCloseButton, cppu::UnoType<decltype(m_bMenuBarCloseButton)>::get() );
registerPropertyNoMember( LAYOUTMANAGER_PROPNAME_ASCII_REFRESHVISIBILITY, LAYOUTMANAGER_PROPHANDLE_REFRESHVISIBILITY, beans::PropertyAttribute::TRANSIENT, cppu::UnoType<bool>::get(), css::uno::Any(false) );
registerProperty( LAYOUTMANAGER_PROPNAME_ASCII_PRESERVE_CONTENT_SIZE, LAYOUTMANAGER_PROPHANDLE_PRESERVE_CONTENT_SIZE, beans::PropertyAttribute::TRANSIENT, &m_bPreserveContentSize, cppu::UnoType<decltype(m_bPreserveContentSize)>::get() );
+ registerPropertyNoMember( LAYOUTMANAGER_PROPNAME_ASCII_REFRESHTOOLTIP, LAYOUTMANAGER_PROPHANDLE_REFRESHTOOLTIP, beans::PropertyAttribute::TRANSIENT, cppu::UnoType<bool>::get(), css::uno::Any(false) );
}
LayoutManager::~LayoutManager()
@@ -3001,7 +3002,7 @@ void SAL_CALL LayoutManager::elementReplaced( const ui::ConfigurationEvent& Even
void SAL_CALL LayoutManager::setFastPropertyValue_NoBroadcast( sal_Int32 nHandle,
const uno::Any& aValue )
{
- if ( nHandle != LAYOUTMANAGER_PROPHANDLE_REFRESHVISIBILITY )
+ if ( (nHandle != LAYOUTMANAGER_PROPHANDLE_REFRESHVISIBILITY) && (nHandle != LAYOUTMANAGER_PROPHANDLE_REFRESHTOOLTIP) )
LayoutManager_PBase::setFastPropertyValue_NoBroadcast( nHandle, aValue );
switch( nHandle )
@@ -3029,6 +3030,12 @@ void SAL_CALL LayoutManager::setFastPropertyValue_NoBroadcast( sal_Int32 n
case LAYOUTMANAGER_PROPHANDLE_HIDECURRENTUI:
implts_setCurrentUIVisibility( !m_bHideCurrentUI );
break;
+
+ case LAYOUTMANAGER_PROPHANDLE_REFRESHTOOLTIP:
+ if (m_xToolbarManager.is())
+ m_xToolbarManager->updateToolbarsTips();
+ break;
+
default: break;
}
}
diff --git a/framework/source/layoutmanager/toolbarlayoutmanager.cxx b/framework/source/layoutmanager/toolbarlayoutmanager.cxx
index cf444b5ab31d..7b1f78f64c1e 100644
--- a/framework/source/layoutmanager/toolbarlayoutmanager.cxx
+++ b/framework/source/layoutmanager/toolbarlayoutmanager.cxx
@@ -3904,6 +3904,20 @@ void SAL_CALL ToolbarLayoutManager::elementReplaced( const ui::ConfigurationEven
pParentLayouter->requestLayout();
}
+void ToolbarLayoutManager::updateToolbarsTips()
+{
+ SolarMutexGuard g;
+
+ for (auto& elem : m_aUIElements)
+ {
+ uno::Reference< ui::XUIElementSettings > xElementSettings(elem.m_xUIElement, uno::UNO_QUERY);
+ if (!xElementSettings.is())
+ continue;
+ xElementSettings->updateSettings();
+ }
+}
+
+
uno::Reference< ui::XUIElement > ToolbarLayoutManager::getToolbar( std::u16string_view aName )
{
return implts_findToolbar( aName ).m_xUIElement;
diff --git a/framework/source/layoutmanager/toolbarlayoutmanager.hxx b/framework/source/layoutmanager/toolbarlayoutmanager.hxx
index 3e7b631c653d..2a490f618a0b 100644
--- a/framework/source/layoutmanager/toolbarlayoutmanager.hxx
+++ b/framework/source/layoutmanager/toolbarlayoutmanager.hxx
@@ -115,6 +115,8 @@ class ToolbarLayoutManager : public ::cppu::WeakImplHelper< css::awt::XDockableW
css::uno::Reference< css::ui::XUIElement > getToolbar( std::u16string_view aName );
css::uno::Sequence< css::uno::Reference< css::ui::XUIElement > > getToolbars();
+ void updateToolbarsTips();
+
// child window notifications
void childWindowEvent( VclSimpleEvent const * pEvent );